classTableFunction
final class TableFunction
implements Node
uses Snapshot
Public API: explicitly declared with
@visibility public.One function call of a FROM item, with the column definitions written for it inside ROWS FROM.
Source: https://www.postgresql.org/docs/17/queries-table-expressions.html#QUERIES-TABLEFUNCTIONS.
$query = (new \SqlSemantics\Platform\PostgreSql\Semantics())->analyze('SELECT * FROM ROWS FROM (f() AS (a integer))');
$query->statement->from->functions[0]->definitions[0]->name->value // => 'a'Properties§
public list<TypedColumn> $definitionspublic Scalar $callMethods§
public function __construct(public Scalar $call, list<TypedColumn> $definitions = [])Parameters
$call | Scalar | The function call |
$definitions | list<TypedColumn> | The column definitions written after AS |
Calls 2
- static-call Check::listOf() line 39
- class-const TypedColumn::class() line 39
public function render(Output $out): voidWrites the call and the column definitions.
Parameters
$out | Output |
Calls 2
- method-call Output::node() line 47
- method-call Output::keyword() line 49
Test cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
TableFunctionTestcalls