final class AmbiguousColumn
    implements Resolution, Diagnostic
    uses Snapshot
Public API: explicitly declared with @visibility public.

A name several visible slots have at the same precedence; none is chosen.

Keeping every candidate of an ambiguous columndoctest
$semantics = new \SqlSemantics\Platform\Sqlite\Semantics();
    $declarations = $semantics->context([$semantics->analyze('CREATE TABLE t (a INTEGER)'), $semantics->analyze('CREATE TABLE u (a INTEGER)')]);
    $semantics->analyze('SELECT a FROM t, u', $declarations) // throws \SqlSemantics\Platform\Sqlite\Model\Diagnostic\SemanticException: Column a is ambiguous.

Properties§

public list<ResolvedColumn> $candidates
public Name $name

Methods§

public function __construct(public Name $name, list<ResolvedColumn> $candidates)

Parameters

$nameNameThe column name
$candidateslist<ResolvedColumn>The equally ranked candidates; at least two
Calls 2
public function message(): string

Describes the problem.

Returns

string

Test cases 7§

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

Dedicated tests 2
Other tests reaching this symbol 5

Relations§

Instantiated in 2