Firebird Documentation IndexFirebird 2.1 Language Ref. UpdateContext variables → UPDATING
Firebird Home Firebird Home Prev: SQLCODEFirebird Documentation IndexUp: Context variablesNext: Operators and predicates

UPDATING

Tip

Find a more recent version at Firebird 5.0 Language Reference: UPDATING

Available in: PSQL

Added in: 1.5

Description: Available in triggers only, UPDATING indicates if the trigger fired because of an UPDATE operation. Intended for use in multi-action triggers.

Type: boolean

Example: 

if (inserting or updating) then
begin
  if (new.serial_num is null) then
    new.serial_num = gen_id(gen_serials, 1);
end
Prev: SQLCODEFirebird Documentation IndexUp: Context variablesNext: Operators and predicates
Firebird Documentation IndexFirebird 2.1 Language Ref. UpdateContext variables → UPDATING