AntGod,
I had this problem also with Oracle. Mine was caused by not creating my entity
beans with the primary keys prior to updating the rest of the fields in the
ejbCreate method. I create mine like this:
| /**
| * Create method
| * @ejb.create-method view-type = "local"
| */
| public infrastructure.interfaces.PersonPK ejbCreate(PersonData data)
| throws javax.ejb.CreateException {
|
| // Primary keys get set first!
| this.setEmail(data.getEmail());
|
| this.setFirstname(data.getFirstname());
| this.setLastname(data.getLastname());
| this.setPassword(data.getPassword());
| this.setUsername(data.getUsername());
|
| return null;
| }
|
Or for my composite keys:
| /**
| * Create method
| * @ejb.create-method view-type = "local"
| */
| public infrastructure.interfaces.RouterUpdatePK ejbCreate(
| RouterUpdateData data) throws javax.ejb.CreateException {
|
| // Primary keys get set first!
| this.setModified_date(new Date());
| this.setSortingOrder(data.getSortingOrder());
|
| this.setCu_code(data.getCu_code());
| this.setCu_modified_date(data.getCu_modified_date());
| this.setPerson_email(data.getPerson_email());
| this.setConfiguration_code(data.getConfiguration_code());
| this.setPushStatus(data.getPushStatus());
| this.setRouter_pri_address(data.getRouter_pri_address());
| this.setRouter_priority(data.getRouter_priority());
|
| return null;
| }
|
Maybe that helps?
Thanks!
Joshua Preston.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3930132#3930132
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3930132
-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user