classXmlTableColumn
final class XmlTableColumn
implements Node
uses Snapshot
Public API: explicitly declared with
@visibility public.One column of XMLTABLE: a typed column with its options, or the FOR ORDINALITY column.
Mirrors PostgreSQL's RangeTableFuncCol. Source: https://www.postgresql.org/docs/17/functions-xml.html#FUNCTIONS-XML-PROCESSING-XMLTABLE.
(new \SqlSemantics\Platform\PostgreSql\Statement\Relation\Xml\XmlTableColumn(new \SqlSemantics\Platform\PostgreSql\Model\Statement\Identifier\Name('n')))->ordinality() // => trueProperties§
public list<XmlColumnOption> $optionspublic Name $namepublic TypeName|null $type = nullMethods§
public function __construct(
public Name $name,
public TypeName|null $type = null,
list<XmlColumnOption> $options = [],
)Parameters
$name | Name | The column name |
$type | TypeName|null | The column type; null for FOR ORDINALITY |
$options | list<XmlColumnOption> | The options in written order |
Calls 3
- static-call Check::listOf() line 41
- class-const XmlColumnOption::class() line 41
- static-call Check::input() line 42
public function ordinality(): boolTells whether the column numbers the rows.
Returns
boolTest cases 1
public function render(Output $out): voidWrites the name and FOR ORDINALITY, or the type and the options.
Parameters
$out | Output |
Calls 4
- method-call Output::name() line 58
- class-const NameUse::Column() line 58
- method-call Output::keyword() line 60
- method-call Output::node() line 64
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 3
- new SqlSemantics\Platform\PostgreSql\Lowering\Query\TableFunctionRule::xmlColumns() packages/sql-semantics-postgres/src/Lowering/Query/TableFunctionRule.php:121
- new SqlSemantics\Platform\PostgreSql\Lowering\Query\TableFunctionRule::xmlColumns() packages/sql-semantics-postgres/src/Lowering/Query/TableFunctionRule.php:122
- new SqlSemantics\Platform\PostgreSql\Lowering\Query\TableFunctionRule::xmlColumns() packages/sql-semantics-postgres/src/Lowering/Query/TableFunctionRule.php:123