Rejected
Details
Assignee
UnassignedUnassignedReporter
andreas bleicherandreas bleicherComponents
Affects versions
Priority
Blocker
Details
Details
Assignee
Unassigned
UnassignedReporter
andreas bleicher
andreas bleicherComponents
Affects versions
Priority
Created December 7, 2011 at 4:02 PM
Updated March 22, 2017 at 5:02 PM
Resolved December 31, 2011 at 3:32 AM
we are using identity generation with default strategy (GenerationType.AUTO) to support different DBMS (mssql, oracle, mysql)
our Id annotations:
since upgrading to jboss7/hibernate4 we get the following error on mssql when persisting a new entity:
14:33:10,373 ERROR [org.hibernate.id.enhanced.TableStructure] (http--127.0.0.1-8080-3) could not read a hi value: java.sql.SQLException:
invalid object name 'hibernate_sequence'.
the reason is that instead of the IdentityGenerator the SequenceStyleGenerator is used although we are using the correct MSSQLServerDialect and it returns supportsIdentityColumns() = true. The SequenceStyleGenerator tries to find the 'hibernate_sequence' table which does not exist
workaround for mssql by changing code to: