For some cases a query like SELECT 1 FROM ... required.
If allow scalars int|float|bool for columns in Query::select() method, the result could be
$query->select(1) => SELECT 1 FROM ...
or with alias
$query->select(['a' => 1]) => SELECT 1 AS "a" FROM ...
Currently using Query instance it could be done like $query->select(new Expression('1')) or $query->select('(1)')
For some cases a query like
SELECT 1 FROM ...
required. If allow scalarsint|float|bool
for columns inQuery::select()
method, the result could be$query->select(1)
=>SELECT 1 FROM ...
or with alias$query->select(['a' => 1])
=>SELECT 1 AS "a" FROM ...
Currently using
Query
instance it could be done like$query->select(new Expression('1'))
or$query->select('(1)')