Пример #1
0
 /**
  * Appends the expression(s) that will condense into a single row all selected rows that share
  * the same values for the grouped expressions.
  *
  * Multiple arguments implementing ISqlValueExpression are accepted.
  *
  * Expression can be an input column name, or the name or ordinal number of an output column
  * (SELECT list item), or an arbitrary expression formed from input-column value.
  *
  * @param ISqlValueExpression ...
  * @return SelectQuery itself
  */
 function groupBy(ISqlValueExpression $expression)
 {
     $expressions = func_get_args();
     foreach ($expressions as $expression) {
         $this->groups->append($expression);
     }
     return $this;
 }
Пример #2
0
 /**
  * Appends the expression that will condense into a single row all selected rows that share
  * the same values for the grouped expressions.
  *
  * Expression can be an input column name, or the name or ordinal number of an output column
  * (SELECT list item), or an arbitrary expression formed from input-column value.
  *
  * @param ISqlValueExpression
  * @return SelectQuery itself
  */
 function addGroupBy(ISqlValueExpression $expression)
 {
     $this->groups->append($expression);
     return $this;
 }