[hibernate-issues] [Hibernate-JIRA] Created: (HHH-3323) Error in SchemaUpdate using HSQLDialect with non Integer or Long primary keys
Jan Justesen (JIRA)
noreply at atlassian.com
Mon Jun 2 05:57:33 EDT 2008
Error in SchemaUpdate using HSQLDialect with non Integer or Long primary keys
-----------------------------------------------------------------------------
Key: HHH-3323
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-3323
Project: Hibernate3
Issue Type: Bug
Affects Versions: 3.2.6
Environment: Hibernate 3.2.6 and Hibernate Annotations 3.3.1 on HSQL DB
Reporter: Jan Justesen
>From HSQL manual:
"Only one identity column is allowed in each table. Identity columns are autoincrement columns. They must be of INTEGER or BIGINT type"
When using HSQLDialect, the following code fails during schema creation:
@Entity
public class Test {
@Id @GeneratedValue(strategy = GenerationType.AUTO)
private Short id;
}
Log output:
ERROR org.hibernate.tool.hbm2ddl.SchemaUpdate - Unsuccessful: create table Test (id smallint generated by default as identity (start with 1), primary key (id))
ERROR org.hibernate.tool.hbm2ddl.SchemaUpdate - Wrong data type: ID in statement [create table Test (id smallint generated by default as identity (start with 1)]
--
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