Hi,
I am using Weblogic 6.1 (sp2), with an Oracle database and JBuilder 7 to
develop some CMP 2.0 Entity Beans. I would like the primary (single,
non-composite) keys (integer sequences) of ejbCreate calls to be
automatically generated.
As I understand it, I can add the following to the weblogic cmp XML file:
<automatic-key-generation>
<generator-type>ORACLE</generator-type>
<generator-name>WFS_SEQ_TYPE_OBS</generator-name>
<key-cache-size>1</key-cache-size>
</automatic-key-generation>
The trouble is that I get a 'ORA-01400' error ("can't insert a null in PK
column") , when I try to create a new record. Should I have done something
else as well as add the XML to the Weblogic descriptor (e.g. change the
ejbCreate methods)? Or maybe I shouldn't be using JBuilder to create the
stubs etc / deploy the bean (use Weblogic ejbc instead)?
Otherwise, I could just write JDBC within the same transaction to pass the
next available unique key to the entity bean. But is this a 'standard' way
to do things?
Thanks very much.
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".