IntelliJ IDEA 2021.1 Help

Configure primary key

Primary keys are defined for CMP Entity beans and BMP Entity beans, versions 1.x and 2.x.

Same as the other bean properties, the primary keys can be defined by editing the source code, or using the tools provided by IntelliJ IDEA.

To configure a primary key

  1. Create a new entity bean.

    Alternatively, open the desired bean for editing, and click the Change EJB Classes button.

  2. In the Primary key class field specify the class that will be used to access the primary key of a datasource the bean is associated with.

  3. From the CMP version list select EJB specification version for the bean. This setting is disabled for BMP entity beans.

Last modified: 08 March 2021