Пример #1
0
 /**
  * Select result of a sub-query.
  *
  * @param Query  $sub The query of which to select result.
  * @param string $alias The alias to give to the sub-result.
  */
 public function selectSub(Query $sub, $alias)
 {
     $this->addValueToQuery($sub->getValues());
     $subSql = new Expression('(' . $sub->getSql() . ')');
     $this->_selectColumn($subSql, $alias);
 }