Community
Participate
Working Groups
Build Identifier: 2.2.0 If an AggregateObjectMapping is part of the ReportQueryResult then ReportItem.resultIndex may be wrong. See Steps to Reproduce ... Fix: ExpressionQueryMechanism.java replace: line 593 ++itemOffset; //only a single attribute can be selected by: if (item.getMapping() instanceof AggregateObjectMapping) { itemOffset += item.getMapping().getFields().size(); // Aggregate object may consist out of 1..n fields } else { ++itemOffset; //only a single attribute can be selected } Reproducible: Always Steps to Reproduce: Example: 1. create @Embeddable class Money { String currency; BigDecimal value; } 2. create @Entity Item {Long id; Money money; String itemNumber; } 3. execute Query: select new QueryObject(i.id, i.money, i.itemNumber) from Items i Error: ReportItem.resultIndex = 2 for ResultItem i.itemNumber, should be 4 as Money has 2 fields
Created attachment 178138 [details] Patch
Investigating submitted patch.
Added fix with minor update. Added test to EntityManagerJunitTestSuite Tested with JPA LRG Reviewed by Tom Ware - reviewed user-submitted fix
moving ipLog flag to patch
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink