This week's book giveaway is in the OCAJP forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide 1Z0-808 and have Jeanne Boyarsky & Scott Selikoff on-line! See this thread for details.
Just recently started using a product that uses Hibernate. I am going against an MQ SQL Server database and have had success in fetching records and doing updates.
My problem is with insert. I am getting an error that Hibernate is attempting to specify the primary key identity field in the generated insert statement when it ought not be in the column list. I think I've got some sort of mapping configuration problem.
Please let me know if this mapping looks reasonable for an identity field.
since it worked for you, cna you please give an insight into my problem !!
I am getting an exception while inserting rows in a table of MSSQLServer with Hibernate. My configuration is as follows. It works OK, if I change generator class to increment. I know both native as well as identity should work for SQLServer dialect. Any Clues?
The Exception is : Caused by: java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Cannot insert the value NULL into column 'id', table 'dbo.DEMO'; column does not allow nulls. INSERT fails.