This content has been marked as final.
Show 2 replies
-
1. Re: ejb auto-increment
rodelor May 15, 2003 6:39 PM (in response to sysuser1)It works fine when I do it. I a, using mysql, xdoclet 1.1.2, and jboss 3.2.0
You need to have the primary key set to an auto incrementing field:
CREATE TABLE FOO (
ID int NOT NULL auto_increment PRIMARY KEY,
...
* @ejb:bean
...
* type="CMP"
* schema="FOO"
* primkey-field="id" -
2. Re: ejb auto-increment
yongjunzheng Jul 13, 2003 7:44 AM (in response to sysuser1)to rodelor,
I also have the same problem as jchilders. I can not get my cmp2.0 EntityBean work correctly with a auto-increment field.
I am using mssql2000 server, the table definition as following:
create table Test(
id numeric(10,0) identity not null primary key,
name char(10) not null
)
Could you give me a whole sample to solve the problem? My Email is yongjunzheng@163.com
Thank you in advance.