> Another potential solution:
>
> If the underlying DBMS supports auto-generated sequence
> numbers, design the
> entity's underlying table to have a field that is
> auto-generated. Pick up
> the sequence number in ejbPostCreate() and populate the
> instance field at
> that time. This may require BMP ... I don't know what happens if the
> CMP-generated SQL tries to insert a null into that auto sequence field
> (behavior is probably DBMS-dependent).
>

I would (actually, I do) go with a stateless session bean if I can rely on
non-portable database extensions. While you can shoehorn the sequence
concept into an entity, it is a bit restrictive. And if you're using BMP,
you gain nothing by using an entity.


- Avi
--
This signature intentionally left blank.

===========================================================================
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".

Reply via email to