svn commit: r585051 - /ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r585051 - /ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java

jacopoc
Author: jacopoc
Date: Mon Oct 15 23:04:29 2007
New Revision: 585051

URL: http://svn.apache.org/viewvc?rev=585051&view=rev
Log:
in view definitions, group-by fields that are not in the select clause are not added to the group by section.

Modified:
    ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java

Modified: ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java?rev=585051&r1=585050&r2=585051&view=diff
==============================================================================
--- ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java (original)
+++ ofbiz/trunk/framework/entity/src/org/ofbiz/entity/datasource/GenericDAO.java Mon Oct 15 23:04:29 2007
@@ -711,7 +711,7 @@
         // GROUP BY clause for view-entity
         if (modelEntity instanceof ModelViewEntity) {
             ModelViewEntity modelViewEntity = (ModelViewEntity) modelEntity;
-            String groupByString = modelViewEntity.colNameString(modelViewEntity.getGroupBysCopy(), ", ", "", false);
+            String groupByString = modelViewEntity.colNameString(modelViewEntity.getGroupBysCopy(selectFields), ", ", "", false);
 
             if (UtilValidate.isNotEmpty(groupByString)) {
                 sqlBuffer.append(" GROUP BY ");