protected void appendGroupByClause ( List groupByFields , StringBuffer buf ) { if ( groupByFields == null || groupByFields . size ( ) == 0 ) { return ; } buf . append ( " GROUP BY " ) ; for ( int i = 0 ; i < groupByFields . size ( ) ; i ++ ) { FieldHelper cf = ( FieldHelper ) groupByFields . get ( i ) ; if ( i > 0 ) { buf . append ( "," ) ; } appendColName ( cf . name , false , null , buf ) ; } }
Appends the GROUP BY clause for the Query