- Open the desired entity class for editing.
- Type the desired field declaration:

- Create getter and setter methods. To do that, press Alt+InsertCommand N; Command Enter,
and select from the suggestion list:

- Annotate the field. If the required import is missing, use the suggested quick fix:

- Open Persistence tool window.
- In the desired persistence unit, right-click persistence entity, and choose the desired persistence
field type:

The available options are:
- Basic

- Element Collection
(a collection of embeddable objects
) - Embedded

- Embedded Id

- Id

- Version

Tip
You can invoke the same command on the context menu of an entity in the ER diagram.
- Basic
- In the dialog box that opens, specify the field name and type, and click OK.
