Your Internet Explorer version is not compatible with our shopping cart system. Please use version 9 or higher to avoid problems with your order(s). Close
Hii…
Iam Using the Hibernate for an application to create an entity in the database.before using hibernate i have created the database profile in result i got Hibernate.cfg.xml and Session Factory class.
Then i have chosen Open perspective—>myeclipse database explorer
right clicked on profile and selected open connection and selected the employee table and right clicked on the table and clicked on “create hibernate mapping” —>next–>selected javatypes—>finish .
when the above steps are carried out MySql created Hbm files and hibernate mapping classes. instead of getting one employee.java (i.e.,mapping class) class created it has created two classes by names
1)employee.java (this contains the setter and getter method for id)
2)employeeid.java(this contains the setter and getter methods for all the properties).
Now iam unable to get the values in the servlet wjhich i wrote.
please Can anyone help me out how to solve this issue?
You haven’t primary key for table.Hibernate request ID value and default is to table’s primary key.If primary key doesn’t exists MyEclipse create ID from all columns (it is your EmployeesId classes).
You have to have primary key (and foreign keys for more tables) for correct hibernate mappings
You haven’t primary key for table.Hibernate request ID value and default is to table’s primary key.If primary key doesn’t exists MyEclipse create ID from all columns (it is your EmployeesId classes).
You have to have primary key (and foreign keys for more tables) for correct hibernate mappings