This is such a simple thing, but I am trying to use the Hibernate Reverse Engineering tools to generate a one-to-one mapping from a mysql table structure, but instead a one-to-many mapping is generated instead. My mysql ddl is the following:
CREATE TABLE Guest ( id INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, firstName VARCHAR(45) NULL, lastName VARCHAR(45) NULL, lastLogin DATETIME NULL, PRIMARY KEY(id) ) TYPE=InnoDB; CREATE TABLE Tracking ( Guest_id INTEGER UNSIGNED NOT NULL, login DATETIME NULL, PRIMARY KEY(Guest_id), UNIQUE INDEX Tracking_FKIndex1(Guest_id), FOREIGN KEY(Guest_id) REFERENCES Guest(id) ) TYPE=InnoDB;