[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-5429) [regression] unable to persist entity using derby 10.6.1.0 and hibernate 3.5+
Jeff Jensen (JIRA)
noreply at atlassian.com
Sat Apr 2 01:45:08 EDT 2011
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-5429?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=41947#action_41947 ]
Jeff Jensen commented on HHH-5429:
----------------------------------
I tried with Derby 10.5.3.0_1 on a whim but as expected the problem still exists - it's a Hibernate issue.
I found an interesting thread while searching earlier, particularly the following message and a number of its follow ups, as these guys basically debugged the Hibernate problem (read about 10-15 messages from this one; you may benefit from reading some of its preceding messages too):
http://www.mail-archive.com/dhis2-devs@lists.launchpad.net/msg00546.html
They made a new dialect to solve: org.hisp.dhis.dialect.IdentityDerbyDialect
Any committers interested in fixing this one soon? We have a couple of environments/databases and prefer not using the table generation type for all (one build for all deploys).
> [regression] unable to persist entity using derby 10.6.1.0 and hibernate 3.5+
> -----------------------------------------------------------------------------
>
> Key: HHH-5429
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5429
> Project: Hibernate Core
> Issue Type: Bug
> Components: core
> Affects Versions: 3.5.3, 3.5.4, 3.6.0.Beta1
> Environment: derby 10.6.1.0 and hibernate 3.5+
> Reporter: Max Giesbert
>
> when inserting any kind of entity
> @Entity
> public class TestObject
> {
> private Long id;
>
> private String test;
>
> public TestObject(){}
>
> @Id @GeneratedValue(strategy=GenerationType.AUTO)
> public Long getId()
> {
> return id;
> }
> [...]
> i get the following error message
> org.hibernate.exception.ConstraintViolationException: could not insert: [com.mypackage.TestObject]
> >>java.sql.SQLIntegrityConstraintViolationException: Column 'ID' cannot accept a NULL value.
> >>org.apache.derby.impl.jdbc.EmbedSQLException: Column 'ID' cannot accept a NULL value.
> >>ERROR 23502: Column 'ID' cannot accept a NULL value.
> >> at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
> >> at org.apache.derby.impl.sql.execute.NormalizeResultSet.normalizeColumn(Unknown Source)
> >> at org.apache.derby.impl.sql.execute.NormalizeResultSet.normalizeRow(Unknown Source)
> >> at org.apache.derby.impl.sql.execute.NormalizeResultSet.getNextRowCore(Unknown Source)
> >> at org.apache.derby.impl.sql.execute.DMLWriteResultSet.getNextRowCore(Unknown Source)
> >>...
> the same code is working fine with versions 3.3.2GA and annotations 3.4.0GA and earlier. i just switched back...
--
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