Kunal,
That is what the spec says:
The container invokes the matching ejbPostCreate<METHOD>(...) method on
an instance after it invokes the ejbCreate<METHOD>(...) method with the same arguments.
The instance can discover the primary key by calling getPrimaryKey() on its
entity context object.
The entity object identity is available during the ejbPostCreate<METHOD>(...)
method. The instance may, for example, obtain the component interface of the associated entity
object and pass it to another enterprise bean as a method argument.
The entity Bean Provider may use the ejbPostCreate<METHOD>(...) to set the values
of cmr-fields to complete the initialization of the entity bean instance.
At the time of
ejbPostCreate(...) is called there is already an entity created and therefore, additional things that are not allowed in
ejbCreate (eg, get eb instance primary key) can be performed in order to
to complete the initialization of the entity bean instance Hope it helps
[ June 18, 2004: Message edited by: Alex Sharkoff ]
Alex (SCJP 1.4, SCBCD 1.3, SCWCD 1.4, SCJD 1.4)