Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

When using CMP entity beans, can I tell the EJB container that the fields have not changed and do not need to be persisted?

0
Posted

When using CMP entity beans, can I tell the EJB container that the fields have not changed and do not need to be persisted?

0

Yes. This can be done by implementing the “public boolean isModified()” method in your bean class. If isModified returns false the EJB container will not persist the fields in the database. This is particularly useful when methods are being invoked on the EJB that do not modify the state of the entity.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123