final class CallMisuse
    implements Diagnostic
    uses Snapshot
Public API: explicitly declared with @visibility public.

A call of a built-in function with a clause its kind of function does not take.

A window-only function needs OVER, a scalar function takes neither OVER nor FILTER nor an argument ordering, a window takes no DISTINCT, and a DISTINCT aggregate takes exactly one argument.

Reading the problem of a scalar function used as a window functiondoctest
(new \SqlSemantics\Platform\Sqlite\Semantics())->analyze('SELECT abs(1) OVER ()') // throws \SqlSemantics\Platform\Sqlite\Model\Diagnostic\SemanticException: abs() may not be used as a window function

Properties§

public Name $function

Methods§

public function __construct(public CallMisuseRule $rule, public Name $function)

Parameters

$ruleCallMisuseRuleThe broken rule
$functionNameThe function name as written

Test cases 16§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 2
Other tests reaching this symbol 14

Relations§

Instantiated in 1