addSelect() public method
Add more columns to the SELECT part of the query.
Note, that if select() has not been specified before, you should include *
explicitly if you want to select all remaining columns too:
$query->addSelect(["*", "CONCAT(first_name, ' ', last_name) AS full_name"])->one();
See also select().
public $this addSelect ( $columns ) | ||
---|---|---|
$columns | string|array|yii\db\Expression |
The columns to add to the select. See select() for more details about the format of this parameter. |
return | $this |
The query object itself |
Please login to continue.