[ https://issues.apache.org/jira/browse/JDO-435?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12561139#action_12561139 ]
Craig Russell commented on JDO-435: ----------------------------------- I thought I'd see what happens if I add yet another navigational expression by starting with Company and navigating through departments and employees and projects. The result is an exception. I'm posting it here before looking into it in detail in case it yields either another Derby bug or a JPOX bug. There was 1 error:testMultipleProjection(org.apache.jdo.tck.query.result.VariableInResult)javax.jdo.JDOException: JDOException thrown while executing query: SELECT e, p FROM org.apache.jdo.tck.pc.company.Company WHERE departments.contains(d) && d.employees.contains(e) && e.projects.contains(p) VARIABLES Department d; Employee e; Project p NestedThrowablesStackTrace: [java] javax.jdo.JDODataStoreException: [JPOX-042007] Error executing JDOQL query " SELECT UNBOUND_E.DATASTORE_IDENTITY,UNBOUND_P.DATASTORE_IDENTITY FROM datastoreidentity0.COMPANIES THIS , datastoreidentity0.PERSONS UNBOUND_E , datastoreidentity0.PROJECTS UNBOUND_P WHERE EXISTS ( SELECT 1 FROM datastoreidentity0.DEPARTMENTS THIS_DEPARTMENTS_D WHERE EXISTS ( SELECT 1 FROM datastoreidentity0.PERSONS THIS_DEPARTMENTS_D_EMPLOYEES_E WHERE THIS_DEPARTMENTS_D_EMPLOYEES_E.DEPARTMENT = THIS_DEPARTMENTS_D.DATASTORE_IDENTITY AND THIS_DEPARTMENTS_D.COMPANYID = THIS.DATASTORE_IDENTITY)) AND EXISTS ( SELECT 1 FROM datastoreidentity0.PROJECT_MEMBER THIS_DEPARTMENTS_D_EMPLOYEES_E_PROJECTS_P WHERE THIS_DEPARTMENTS_D_EMPLOYEES_E_PROJECTS_P."MEMBER" = THIS_DEPARTMENTS_D_EMPLOYEES_E.DATASTORE_IDENTITY AND UNBOUND_P.DATASTORE_IDENTITY = THIS_DEPARTMENTS_D_EMPLOYEES_E_PROJECTS_P.PROJID) " : Column 'THIS_DEPARTMENTS_D_EMPLOYEES_E.DATASTORE_IDENTITY' is either not in any table in the FROM list or appears within a join specification and is outside the scope of the join specification or appears in a HAVING clause and is not in the GROUP BY list. If this is a CREATE or ALTER TABLE statement then 'THIS_DEPARTMENTS_D_EMPLOYEES_E.DATASTORE_IDENTITY' is not a column in the target table.. > Query with projected variables returns duplicates and extra results that do > not satisfy filter > ---------------------------------------------------------------------------------------------- > > Key: JDO-435 > URL: https://issues.apache.org/jira/browse/JDO-435 > Project: JDO > Issue Type: Bug > Components: tck2 > Affects Versions: JDO 2 final > Reporter: Craig Russell > Fix For: JDO 2 maintenance release 1 > > > org.apache.jdo.tck.query.result.VariableInResult fails with several queries > that return variables that are mapped to one-many and many-many > relationships. In some cases, the filter is not satisfied. In others, > duplicate results are returned. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.