the Entity bean has some abstract functions in the EJBObject interface...
Example create, remove etc...
By simply providing the primary key as an argument i.e. create(primary_key) the container automaticaly inserts a record in a table.. similarly there is another function remove thru which one can simply call the function like this... remove(primary_key) and the container would remove the record in the table...
However if the developer wishes to perfrom these transactions by running sql scripts he uses bean managed transactions and codes it thus called Bean Managed Trasactions.
Joined: Apr 04, 2006
@ Ali Aman
I think the definition what u gave is for the difference between CMP(and BMP beans
CMP == Container Managed Persistence
BMP == Bean Managed Persistence
Transaction is something similar to the Database transaction,if u wanna write any transaction code in your bean using the services of JTS or JTA you go for Bean Managed Transaction
and when u allow the container to manage the same its called Container managed Transaction
The transaction attribute of the bean is defined in the transaction type tag in the ejb-jar.xml (Deployment descriptor)