final class MatchName
    implements ReferenceArgument
    uses Snapshot
Public API: explicitly declared with @visibility public.

A MATCH clause of a foreign key.

Rule: SQLITE-FK-MATCH-001. "SQLite parses MATCH clauses (i.e. does not

  • report a syntax error if you specify one), but does not enforce them. All
  • foreign key constraints in SQLite are handled as if MATCH SIMPLE were
  • specified." Any name is accepted and kept.

Source: https://sqlite.org/foreignkeys.html#fk_unsupported. Status: Implemented.

Reading a MATCH namedoctest
$create = (new \SqlSemantics\Platform\Sqlite\Semantics())->analyze('CREATE TABLE c (p REFERENCES parent MATCH FULL)');
    $create->statement->columns[0]->constraints[0]->arguments[0]->name->value // => 'FULL'

Properties§

public Name $name

Methods§

public function __construct(public Name $name)

Parameters

$nameNameThe name written after MATCH
public function render(Output $out): void

Writes the clause.

Parameters

$outOutput
Test cases 1
Calls 2

Test cases 3§

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 2

Relations§

Instantiated in 1