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

A column name the completely known table would have twice after a table change.

The server rejects the statement with ER_DUP_FIELDNAME. Column names are compared without regard to case. Source: https://dev.mysql.com/doc/refman/8.4/en/alter-table.html.

Describing the problemdoctest
(new \SqlSemantics\Platform\MySql\Statement\Alter\Problem\DuplicateColumn(new \SqlSemantics\Platform\MySql\Model\Statement\Identifier\Name('a')))->message() // => 'Column a would be defined more than once.'

Properties§

public Name $column

Methods§

public function __construct(public Name $column)

Parameters

$columnNameThe repeated name as the change writes it
public function message(): string

Describes the problem.

Returns

string
Test cases 1

Test cases 1§

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

Dedicated tests 1

Relations§

Instantiated in 1
Type declarations 1