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

Lowers the query primaries and the WITH clause of the 8.0 and later grammars.

Rule: MYSQL-QUERY-PRIMARY-001. Scope: query_primary, query_specification (8.0 and later), table_value_constructor, values_row_list, row_value_explicit, explicit_table, with_clause, opt_with_clause, with_list, common_table_expr. A query specification is a query block whose INTO clause, when written, follows the select list. Constructs: the query block, ValuesQuery, ValueRow, ExplicitTable, With, CommonTableExpression. Terminates: lists are flattened iteratively. Source: https://dev.mysql.com/doc/refman/8.4/en/select.html, https://dev.mysql.com/doc/refman/8.4/en/values.html, https://dev.mysql.com/doc/refman/8.4/en/table.html, https://dev.mysql.com/doc/refman/8.4/en/with.html. Status: Implemented.

Methods§

public function __construct(private Lowering $lowering)

Parameters

$loweringLoweringThe lowering this rule belongs to
public function primary(Node $primary): Block|Query

Lowers a query primary: a query block, a VALUES statement or a TABLE statement.

Parameters

$primaryNode

Returns

Throws

ImplementationGap When a production has no rule
Called from 1
Calls 5
public function specification(Node $specification): Block
public function values(Node $constructor): ValuesQuery

Private surface 2§

Implementation details, listed for orientation only.

private const SPECIFICATIONS = ['query_specification: SELECT_SYM select_options select_item_list into_clause o…
private Lowering $lowering

Relations§

Instantiated in 3
Method calls 3