svn commit: r981638 - /ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj

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

svn commit: r981638 - /ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj

doogie-3
Author: doogie
Date: Mon Aug  2 17:44:05 2010
New Revision: 981638

URL: http://svn.apache.org/viewvc?rev=981638&view=rev
Log:
FEATURE: Add count-all variant that doesn't require a table name.

Modified:
    ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj

Modified: ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj?rev=981638&r1=981637&r2=981638&view=diff
==============================================================================
--- ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj (original)
+++ ofbiz/trunk/framework/sql/src/org/ofbiz/sql/Parser.jj Mon Aug  2 17:44:05 2010
@@ -607,6 +607,7 @@ private StaticValue Count(): {
               )
             | <CLOSE_PAREN> { return new CountFunction(false, new FieldValue(null, n)); }
           )
+        | <STAR> <CLOSE_PAREN> { return new CountAllFunction(null); }
         | <DISTINCT> n=NamePart() (
               <PERIOD> fieldName=NamePart() <CLOSE_PAREN> { return new CountFunction(true, new FieldValue(n, fieldName)); }
             | <CLOSE_PAREN> { return new CountFunction(true, new FieldValue(null, n)); }