[
https://issues.apache.org/jira/browse/OPENJPA-2008?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
David Louie resolved OPENJPA-2008.
----------------------------------
Resolution: Fixed
Fix Version/s: 2.2.0
Issue has been resolved in revision 1135806.
Tested with the following query and the query worked, count works, and sorting
works:
SELECT DISTINCT u.uid, u.studentid, u.firstname, u.lastname, u.username,
u.lastlogintime, count(DISTINCT e.uid) FROM roles r
INNER JOIN userroles ur ON ur.roleID = r.uid
INNER JOIN users u ON ur.userID = u.uid
AND r.namefield IN (?1)
AND u.lastname LIKE ?2
AND u.firstname LIKE ?3
AND u.studentid LIKE ?4
AND u.isactive IS TRUE
LEFT JOIN courseenrollments e ON e.userID = u.uid
AND e.schoolyearID = ?5
AND e.enddate IS NULL
GROUP BY u.uid, u.studentid, u.firstname, u.lastname, u.username,
u.lastlogintime
ORDER BY u.uid
> OpenJPA does not work with native queries in a distributed (Slice) environment
> ------------------------------------------------------------------------------
>
> Key: OPENJPA-2008
> URL: https://issues.apache.org/jira/browse/OPENJPA-2008
> Project: OpenJPA
> Issue Type: Bug
> Components: slice
> Affects Versions: 2.1.0
> Environment: Slice, Tomcat 6, MySql 5.5, openJPA 2.1
> Reporter: David Louie
> Fix For: 2.2.0
>
>
> When trying to create a native query in a distributed (slice) environment, an
> exception is thrown because there is no ExpressionParser for language
> openJPA.SQL for a distributed query.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira