final class RoutineChecks
Restricted visibility: declared "@visibility SqlSemantics\Platform\PostgreSql". Code outside that scope must not name this declaration.

Reports routine definitions, parameter lists and option lists the server rejects.

Rule: PG-ROUTINE-CHECK-001. Options: an attribute set twice is conflicting (configuration settings may repeat); a procedure accepts no null-input behavior, volatility, leakproofness, estimate, support function, parallel mode or WINDOW; PARALLEL takes safe, restricted or unsafe. Body: a routine needs exactly one of AS and an SQL-standard body; a routine without a body has to name its language; an SQL-standard body is for language sql only; only language c takes an object file and a link symbol. Parameters: VARIADIC is the last input parameter; only input parameters take default values and every input parameter after one with a default value takes one too; a procedure's OUT parameter may not follow a parameter with a default value; two input or two output parameters (TABLE columns are output parameters) cannot share a name; a TABLE function has no OUT or INOUT parameters; a function without RETURNS needs an output parameter. Terminates: quadratic in the parameter count. Source: https://www.postgresql.org/docs/17/sql-createfunction.html, compute_function_attributes and interpret_function_parameter_list in src/backend/commands/functioncmds.c of PostgreSQL 17. Status: Implemented.

Methods§

public function names(CreateFunction $function, Derivation $derivation): void

Reports two input or two output parameters with the same name.

Parameters

$functionCreateFunction
$derivationDerivation
Called from 1
Calls 4

Private surface 1§

Implementation details, listed for orientation only.

private const FUNCTION_ONLY = ['strict', 'volatility', 'leakproof', 'cost', 'rows', 'support', 'parallel', 'w…

Test cases 1§

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

Dedicated tests 1

Relations§

Instantiated in 2
Method calls 4