final class ColumnAttributes
    implements AlterCommand
    uses Snapshot
Public API: explicitly declared with @visibility public.

ALTER [ COLUMN ] ... SET ( ... ) or RESET ( ... ): the per-column options.

Mirrors AT_SetOptions and AT_ResetOptions. Source: https://www.postgresql.org/docs/17/sql-altertable.html.

Setting column optionsdoctest
$statement = (new \SqlSemantics\Platform\PostgreSql\Semantics())->analyze('ALTER TABLE t ALTER a SET (n_distinct = 100)');
    $statement->toString() // => 'ALTER TABLE t ALTER a SET (n_distinct = 100)'

Properties§

public non-empty-list<Definition> $options
public Name $column
public bool $reset

Methods§

public function __construct(public Name $column, public bool $reset, list<Definition> $options)

Parameters

$columnNameThe column
$resetboolWhether the options are reset; set otherwise
$optionslist<Definition>The options
Calls 2
public function deriveClause(Derivation $derivation, Environment $environment): void

Checks that the column exists and derives the options.

Parameters

$derivationDerivation
$environmentEnvironment
Calls 2
public function render(Output $out): void

Writes the action.

Parameters

$outOutput
Calls 3

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 2
Type checks 1