final class TriggerTransition
    implements Node
    uses Snapshot
Public API: explicitly declared with @visibility public.

One REFERENCING item: a name for the old or new transition table.

Mirrors PostgreSQL's TriggerTransition. The optional AS is not kept. ROW transition variables are not supported by the server, which is reported. Transition tables are visible to the trigger function only. Source: https://www.postgresql.org/docs/17/sql-createtrigger.html.

Naming a transition tabledoctest
$statement = (new \SqlSemantics\Platform\PostgreSql\Semantics())->analyze('CREATE TRIGGER g AFTER INSERT ON t REFERENCING NEW TABLE AS fresh FOR EACH STATEMENT EXECUTE FUNCTION f()');
    $statement->statement->transitions[0]->name->value // => 'fresh'

Properties§

public bool $new
public bool $table
public Name $name

Methods§

public function __construct(public bool $new, public bool $table, public Name $name)

Parameters

$newboolWhether the item names the new rows; the old ones otherwise
$tableboolWhether TABLE is written; ROW otherwise
$nameNameThe name
public function render(Output $out): void

Writes the item.

Parameters

$outOutput
Calls 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
Constant reads 1