+^Acct("ID") -commands=Set -xecute="Set ^Acct(1)=$ZTVALUE+1" +^Acct(sub=:) -command=Set -xecute="Set ^X($ZTVALUE)=sub"
![]() | Caution |
---|---|
FIS recommends against using chained and nested triggers that potentially update the same piece of a global variable. You should always assess the significance of having chained triggers for a database update especially because of the arbitrary trigger execution order.The following table shows the stacking behavior of some Intrinsic Special Variables in chained and nested triggers. |
ISV |
Chained Triggers |
Nested Triggers |
---|---|---|
$REFERENCE |
Shared |
Stacked |
$TEST |
Stacked |
Stacked |
$ZTVALUE |
Shared (updatable) |
Stacked |
$ZTOLDVAL |
Shared |
Stacked |
$ZTDATA |
Shared |
Stacked |
$ZTSLATE |
Not Stacked |
Not Stacked |
$ZTRIGGEROP |
Shared |
Stacked |
$ZTWORMHOLE |
Not Stacked |
Not Stacked |
$ZTLEVEL |
Shared |
Stacked |
$ZTUPDATE |
depends on $ZTVALUE when trigger starts |
Stacked |
Stacked denotes an ISV whose value is restored at the completion of the trigger.
Not Stacked denotes an ISV whole value is retained after the completion of the trigger.
Shared denotes an ISV whose value is the same, possibly subject to updates, across chained updates