Fixed
Details
Assignee
Steve EbersoleSteve EbersoleReporter
CoolnodjeCoolnodjeTime tracking
2.28h loggedComponents
Fix versions
Priority
Critical
Details
Details
Assignee
Steve Ebersole
Steve EbersoleReporter
Coolnodje
CoolnodjeTime tracking
2.28h logged
Components
Fix versions
Priority
Created June 30, 2010 at 11:34 AM
Updated February 2, 2012 at 8:14 AM
Resolved August 19, 2011 at 6:56 PM
I'm getting a
java.lang.IllegalArgumentException: Cannot create TypedQuery for query with more than one return
with a query that returns a View object.
AbstractEntityManager:279, detects as many returns type as there is parameters in the View object, instead of one single result type, the View Object itself.
QueryString example that fails with public <T> TypedQuery<T> createQuery(String jpaqlString, Class<T> resultClass):
"select new WorkContractDto(wc.workContractStartDate, wc.workContractEndDate, wc.workContractEmployeeLastName, wc.workContractSendingStatus) from WorkContract wc where wc.workContractEmployeeLastName = ?1"