I’m getting used to the new GA version with XDOCLET support for building
beans (in this case EntityBeans). Anyway, I created a simple bean and used the XDOCLET standard EJB configuration to generate the associated classes and ejb-jar file.
The problem is when I deploy the bean in JBOSS, I get the following:
org.jboss.deployment.DeploymentException: Error while creating table; – nested throwable: (java.sql.SQLException: Wrong data type: CONSTRAINT in statement [CREATE TABLE TESTEJBBEAN (, CONSTRAINT PK_TESTEJBBEAN PRIMARY KEY ())])
I noticed in my ejb-jar file I’m missing the cmp-field and primkey-field
<!– Entity Beans –>
<entity >
<description><![CDATA[TestEJBBean EJB]]></description>
<display-name>TestEJBBean</display-name>
<ejb-name>TestEJBBean</ejb-name>
<home>testEJBPackage.TestEJBBeanHome</home>
<remote>testEJBPackage.TestEJBBeanRemote</remote>
<local-home>testEJBPackage.TestEJBBeanLocalHome</local-home>
<local>testEJBPackage.TestEJBBeanLocal</local>
<ejb-class>testEJBPackage.TestEJBBeanCMP</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>testEJBPackage.TestEJBBeanPK</prim-key-class>
<reentrant>False</reentrant>
<cmp-version>2.x</cmp-version>
<abstract-schema-name>TestEJBBean</abstract-schema-name>
<!– Write a file named ejb-finders-TestEJBBean.xml if you want to define extra finders. –>
</entity>
Any thoughts?
Thanks,
Tim