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

Derives the columns of XMLTABLE and JSON_TABLE used as FROM items.

Rule: PG-XMLTABLE-001 / PG-JSON-TABLE-001. Every expression is derived where the FROM items before the table are visible. A FOR ORDINALITY column is an integer that is never NULL; every other column has its declared type and can be NULL, except an XMLTABLE column declared NOT NULL. The nested columns of JSON_TABLE follow in written order. XMLTABLE reports a second FOR ORDINALITY column, repeated PATH, DEFAULT or NULL options, and an option word other than path and default; JSON_TABLE reports a row path that is not a string constant and the behaviors a column does not accept. The column aliases rename the columns (PG-COLUMN-ALIAS-001). Source: https://www.postgresql.org/docs/17/functions-xml.html#FUNCTIONS-XML-PROCESSING-XMLTABLE, https://www.postgresql.org/docs/17/functions-json.html#FUNCTIONS-SQLJSON-TABLE. Status: Implemented.

Methods§

public function columns(
    list<JsonTableColumn> $columns,
    Derivation $derivation,
    Environment $environment,
): list<OutputSlot>

Derives JSON_TABLE column definitions, the nested ones included, and answers their slots in order.

Parameters

$columnslist<JsonTableColumn>
$derivationDerivation
$environmentEnvironment

Returns

Test cases 1
Called from 1
Calls 8

Test cases 2§

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

Dedicated tests 2

Relations§

Instantiated in 2
Method calls 2