IntelliJ IDEA 2018.3 Help

Persistence Tool Window

View | Tool Windows | Persistence


The Persistence tool window shows your JPA and Hibernate project items.

At the top hierarchical level are JPA- and Hibernate-enabled modules. One level below are configuration files, and <persistence-unit> and <session-factory> elements. Further down in the hierarchy are mapping files, persistent classes, etc.

persistence tool window

The tool window lets you create new items such as configuration files, <persistence-unit> and <session-factory> elements, persistent classes and fields, navigate to related source code in the editor, open consoles and entity-relationship diagrams, and more.

Title bar icons

Item

Description

database openapi icons consoleRun svg

Select a persistence unit or session factory (or any of the subordinate elements) and click this icon to open the JPA or Hibernate console. See also, Working with the JPA console and Working with the Hibernate console.

Expand All

Expand all the nodes.

Collapse All

Collapse all the nodes.

Context menu commands

Item

Description

ER Diagram

For a persistence unit or session factory: open an entity-relationship diagram for the selected persistence unit or session factory.

Console (Ctrl+Shift+F10)

For a persistence unit or session factory: open the JPA or Hibernate console for the selected persistence unit or session factory. See also, Working with the JPA console and Working with the Hibernate console.

Assign Data Sources

For a persistence unit or session factory: associate the selected persistence unit or session factory with a database or DDL data source. See Associating persistence units and session factories with data sources.

Assign Naming Strategies

For a session factory: associate the selected session factory with a Naming Strategy implementation.

New (Alt+Insert)

Create a new item such as a persistent class, or configuration or mapping file, etc. See Using the New command.

Jump to Source (F4)

Open the selected file in the editor and switch to the corresponding code fragment.

Generate Persistence Mapping

Generate persistent classes and object/relational mappings for them. See Generating managed entity classes and O/R mappings.

Last modified: 19 December 2018

See Also