[hibernate-issues] [Hibernate-JIRA] Created: (ANN-822) org.hibernate.test.annotations.EntityTest fails because DB2 does not support unique constraints on nullable columns
Gail Badner (JIRA)
noreply at atlassian.com
Wed Apr 15 19:45:17 EDT 2009
org.hibernate.test.annotations.EntityTest fails because DB2 does not support unique constraints on nullable columns
-------------------------------------------------------------------------------------------------------------------
Key: ANN-822
URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-822
Project: Hibernate Annotations
Issue Type: Bug
Reporter: Gail Badner
The following org.hibernate.test.annotations.EntityTest tests fail on DB2:
testColumnUnique()
testUniqueConstraint()
DB2 does not support unique constraints on nullable columns. DB2 does support unique indexes on nullable columns, but only be 1 null value is allowed. (DB2 for z/OS does appear to allow multiple null values; is that a different dialect?)
When DB2Dialect is used, Hibernate does not create unique constraints or indexes on nullable columns. This is why the expected constraint violations do not occur in the tests. The tests give an erroneous message "org.hibernate.TransactionException: Transaction not successfully started" because an attempt is made to rollback the transaction after it was successfully committed.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list