Object getSingleResult()
Retrieve a single result from the next result set. The provider will call
execute
on the query if needed. A REF_CURSOR
result set, if any, will be retrieved in the order the REF_CURSOR
parameter was registered with the query. - Return:
- the result or null if the next item is not a result set
- Throws:
- NoResultException - if there is no result in the next result set
- NonUniqueResultException - if more than one result
- QueryTimeoutException - if the query execution exceeds the query timeout value set and only the statement is rolled back
- PersistenceException - if the query execution exceeds the query timeout value set and the transaction is rolled back
- NonUniqueResultException - if more than one result
- Since:
- JPA 2.1