You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-dev@db.apache.org by br...@apache.org on 2004/06/05 14:18:15 UTC
cvs commit: db-ojb release-notes.txt
brj 2004/06/05 05:18:15
Modified: . release-notes.txt
Log:
description of ReportQuery problem
Revision Changes Path
1.43 +21 -1 db-ojb/release-notes.txt
Index: release-notes.txt
===================================================================
RCS file: /home/cvs/db-ojb/release-notes.txt,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -r1.42 -r1.43
--- release-notes.txt 6 May 2004 21:22:33 -0000 1.42
+++ release-notes.txt 5 Jun 2004 12:18:14 -0000 1.43
@@ -44,7 +44,27 @@
and obj_2{ref_2}. Lock objects and exchange the references in collection obj_1{ref_2}
and obj_2{ref_1} and commit.
+- ReportQueries should not be used with columns referencing Classes with extents:
+ReportQueryByCriteria q = QueryFactory.newReportQuery(ProductGroup.class, crit);
+q.setAttributes(new String[] { "groupName", "sum(allArticlesInGroup.stock)", "sum(allArticlesInGroup.price)" });
+q.addGroupBy("groupName");
+
+ProductGroup.allArticlesInGroup points to class Article having multiple extents.
+
+As a workaround the query can be 'reversed' :
+
+ReportQueryByCriteria q = QueryFactory.newReportQuery(Article.class, crit);
+q.setAttributes(new String[] { "productGroup.groupName", "sum(stock)", "sum(price)" });
+q.addGroupBy("productGroup.groupName");
+
+Due to the fact the Article has extents multiple selects will be executed,
+so the same ProductGroup may show up more than once.
+
+Please see the testcases QueryTest#testReportQueryGroupByExtents1 and
+QueryTest#testReportQueryGroupByExtents2.
+
+- A count on ReportQueries containing groupBy does not deliver a correct result.
---------------------------------------------------------------------
Release 1.0 rc6
---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org