public function aggregation($function) { $selection = $this->createSelectionInstance(); $selection->getSqlBuilder()->importConditions($this->getSqlBuilder()); $selection->select($function); foreach ($selection->fetch() as $val) { return $val; } }
/** * Executes aggregation function. * * @param $function string select call in "FUNCTION(column)" format * @return string */ public function aggregation($function) { return $this->selection->aggregation($function); }