Chapter 31. EJB Query Language
You learned in Chapter 30, “Entity Beans,” that there are two types of entity beans: bean-managed persistence (BMP) and container-managed persistence (CMP). The examples in that chapter show how entity beans with CMP can reduce the number of code lines you need. When you use entity beans with CMP, you don’t have to worry about how the entity bean’s data is persisted. The container takes care of this for you.
Although automatic persistence by the container is a good feature of the CMP entity beans, BMP entity beans are sometimes preferable because they are more flexible in defining complex finder methods. With BMP entity ...
Get Java for the Web with Servlets, JSP, and EJB: A Developer’s Guide to J2EE Solutions now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.