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

Derives the row shape of a derived table or a common table from its query and its column list.

Rule: MYSQL-DERIVED-SHAPES-001. Without a column list the columns are the output slots of the query, with their names (MYSQL-SELECT-ITEM-NAME-001); a slot whose name depends on missing inputs keeps them as its unnamed inputs, so that a column lookup in the relation depends on them (CORE-COLUMN-LOOKUP-001). With a column list the list names the columns in order and the query gives their types, which depend on the missing inputs of the query while its columns are not all known; a list whose length differs from a complete query is reported, and a column without a slot is invalid. Duplicate column names are reported. Source: https://dev.mysql.com/doc/refman/8.4/en/derived-tables.html, https://dev.mysql.com/doc/refman/8.4/en/with.html. Status: Implemented.

Methods§

public function shape(QueryFact $fact, list<Name> $columns, Derivation $derivation): RowShape

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