enum AliasMark
Public API: explicitly declared with @visibility public.

What is written between an operand and its alias: AS, nothing, or in MySQL 5.6 and 5.7 = before a table alias.

The three forms give the same alias. The form is kept because MySQL names an unaliased select list expression after its text, and an alias written inside that expression, in a subquery for example, is part of the text. Source: https://dev.mysql.com/doc/refman/8.4/en/select.html, sql/sql_yacc.yy of MySQL 5.7 (table_alias).

Reading how an alias is writtendoctest
$query = (new \SqlSemantics\Platform\MySql\Semantics())->analyze('SELECT a total FROM t');
    $query->statement->items[0]->mark // => \SqlSemantics\Platform\MySql\Statement\Name\AliasMark::Bare

Cases§

case As
case Bare
case Equals

Methods§

public function write(Output $out): void

Writes what precedes the alias.

Parameters

$outOutput
Writing the keyword of an aliasdoctest
$out = new \SqlSemantics\Platform\MySql\Model\Rendering\Output(new \SqlSemantics\Platform\MySql\Rendering\Codec(\SqlSemantics\Platform\MySql\Model\Contract\GrammarRelease::MySql847));
    \SqlSemantics\Platform\MySql\Statement\Name\AliasMark::As->write($out);
    $out->pieces()[0]->text // => 'AS'
Called from 8
Calls 5

Test cases 4§

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

Dedicated tests 1
Other tests reaching this symbol 3

Relations§

Method calls 8
Constant reads 25
Type declarations 11