Package javax.persistence
Annotation Type NamedNativeQuery
-
@Target(TYPE) @Retention(RUNTIME) @Repeatable(NamedNativeQueries.class) public @interface NamedNativeQuery
Specifies a named native SQL query. Query names are scoped to the persistence unit. TheNamedNativeQueryannotation can be applied to an entity or mapped superclass.- Since:
- Java Persistence 1.0
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description QueryHint[]hintsQuery properties and hints.ClassresultClassThe class of the result.StringresultSetMappingThe name of aSqlResultSetMapping, as defined in metadata.
-
-
-
-
resultClass
Class resultClass
The class of the result.- Returns:
- The result class
- Default:
- void.class
-
-
-
resultSetMapping
String resultSetMapping
The name of aSqlResultSetMapping, as defined in metadata.- Returns:
- ResultSet mapping
- Default:
- ""
-
-