classDomainDefaultChange
final class DomainDefaultChange
implements Statement
uses Snapshot
Public API: explicitly declared with
@visibility public.A request to set or remove the default of a domain: ALTER DOMAIN name { SET DEFAULT expression | DROP DEFAULT }.
Rule: PG-DOMAIN-003. Mirrors AlterDomainStmt subtype 'T'. The default expression is evaluated where no column is visible. Source: https://www.postgresql.org/docs/17/sql-alterdomain.html. Status: Implemented.
$operation = (new \SqlSemantics\Platform\PostgreSql\Semantics())->analyze('ALTER DOMAIN d DROP DEFAULT');
$operation->statement->default // => nullProperties§
public DottedName $namepublic Scalar|null $defaultMethods§
public function __construct(public DottedName $name, public Scalar|null $default)Parameters
$name | DottedName | The domain name |
$default | Scalar|null | The new default; null for DROP DEFAULT |
public function deriveStatement(Derivation $derivation): voidDerives the default expression.
Parameters
$derivation | Derivation |
Calls 2
- method-call Derivation::scalar() line 45
- new Environment line 45
public function render(Output $out): voidTest cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
DomainDefaultChangeTestcalls