Queries

Use the queries area of the JPA Details view to create named queries and named native queries. Refer to "Creating queries" for additional information.

Property Description Default Available for Entity Type

Queries

Displays the existing Named and Native queries.

Click Add to add a named or named native query by using the Add Query dialog.


Entity and Mapped superclass

Named Queries




Name

Name of the query.


Entity and Mapped superclass

Query

The query SQL.


Entity and Mapped superclass

Lock mode

Specify the JPA locking policy.

  • None

  • Optimistic

  • Optimistic Force Increment

  • Pessimistic Force Increment

  • Pessimistic Read

  • Pessimistic Write

  • Read

  • Write

None

Entity and Mapped superclass

Native Queries




Name

Name of the query.


Entity and Mapped superclass

Result class

The class of the result.

Note: This field appears for Native Named Queries only.


Entity and Mapped superclass

Query

The query SQL.


Entity and Mapped superclass

Query hints

Displays the existing query hints (Name and Value).

Click Add to add a new query hint.


Entity and Mapped superclass


Related tasks

Related reference

Related concepts