interfaceSetFunction
interface SetFunction
extends Scalar
Public API: explicitly declared with
@visibility public.A call of a set function, an aggregate such as COUNT, SUM or GROUP_CONCAT, written with or without a window.
Without OVER it aggregates the rows of its query block, so the block returns one row per group, or one row without GROUP BY; with OVER it is a window function and aggregates nothing. Source: https://dev.mysql.com/doc/refman/8.4/en/aggregate-functions.html.
$count = new \SqlSemantics\Platform\MySql\Statement\Call\Aggregate\Aggregate(\SqlSemantics\Platform\MySql\Statement\Call\Aggregate\AggregateFunction::Count, []);
$windowed = new \SqlSemantics\Platform\MySql\Statement\Call\Aggregate\Aggregate(\SqlSemantics\Platform\MySql\Statement\Call\Aggregate\AggregateFunction::Count, [], over: new \SqlSemantics\Platform\MySql\Model\Statement\Identifier\Name('w'));
[$count->aggregates(), $windowed->aggregates()] // => [true, false]Methods§
public function aggregates(): boolTells whether the call aggregates the rows of its query block: it is written without OVER.
Returns
boolTest cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.