Browse Source

Update Query.php

Change passing parameters to array with two elements – 'all' which means if we use UNION or UNION ALL construction and 'query' which is our sql query that will be at right of construction.
tags/2.0.0-beta
Ivan Pomortsev 11 years ago
parent
commit
5f3d601b36
  1. 3
      framework/db/Query.php

3
framework/db/Query.php

@ -640,8 +640,7 @@ class Query extends Component implements QueryInterface
*/
public function union($sql, $all = false)
{
$sql->addParams([ 'all' => $all ]);
$this->union[] = $sql;
$this->union[] = array( 'query' => $sql, 'all' => $all );
return $this;
}

Loading…
Cancel
Save