[JBoss JIRA] Created: (JBAS-3806) EJB3- Dynamically created column(attribute) in the database does not honour "nullable=false" annotation property on Column Annotation...
by Balaji Narasimhan (JIRA)
EJB3- Dynamically created column(attribute) in the database does not honour "nullable=false" annotation property on Column Annotation...
-----------------------------------------------------------------------------------------------------------------------------------------
Key: JBAS-3806
URL: http://jira.jboss.com/jira/browse/JBAS-3806
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: EJB3
Affects Versions: JBossAS-4.0.5.GA, JBossAS-4.0.4.GA
Environment: windows xp, mysql 4.x
Reporter: Balaji Narasimhan
Assigned To: Bill Burke
I have an attribute on the class.....
Class name is classA and the attribute is sequenceNumber.
Here is the annotation for that attribute for that class..
@Column(name="sequenceNumber",nullable=false)
public int getSequenceNumber(){
return sequenceNumber;
}
When I generate ddl using hibernate tools, the generated schema has ' not null' for sequenceNumber field, which is PERFECT.
But when I let jboss/ejb3.0 create the tables and fields dynamically (when the app is deployed) , the sequenceNumber is set as ALLOW NULL , in the database which is NOT CORRECT.
I don't understand why would the behavior be different in different cases if jboss is using the same hibernate to create ddl at runtime.
Hope I'm clear.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
18 years, 11 months