Oracle® OLAP DML Reference 11g Release 1 (11.1) Part Number B28126-01 |
|
|
View PDF |
The TRIGGERMAXDEPTH option determines the maximum number of $NATRIGGER property expressions that Oracle OLAP can execute simultaneously.
Data Type
INTEGER
Syntax
TRIGGERMAXDEPTH = n
Arguments
An INTEGER
expression that specifies the maximum number of $NATRIGGER property expressions that can execute simultaneously. The default value is 50
.
Notes
About the $NATRIGGER Property
The TRIGGERMAXDEPTH option works in conjunction with the $NATRIGGER property of a variable.
Recursive Triggers
While a $NATRIGGER expression is executing, it cannot be invoked again by a formula, program, or other $NATRIGGER expression that it invokes unless the RECURSIVE option is set to YES. The TRIGGERMAXDEPTH option governs the depth of recursion of $NATRIGGER expressions and prevents infinite recursions or excessively deep recursions, which can cause Oracle OLAP to malfunction.
Examples
Example 6-109 Setting the Maximum Trigger Depth
This example sets the maximum trigger depth, exceeds it, then sets the depth to a higher value. Usually the TRIGGERMAXDEPTH value would be much higher than 2
, which is used in this example. The default value is 50
.
DEFINE d1 INTEGER DIMENSION MAINTAIN d1 ADD 2 DEFINE v1 DECIMAL <d1> PROPERTY '$NATRIGGER' 'v2 + 1' DEFINE v2 DECIMAL <d1> PROPERTY '$NATRIGGER' 'v3 + 1' DEFINE v3 DECIMAL <d1> PROPERTY '$NATRIGGER' 'v4 + 1' DEFINE v4 DECIMAL <d1> v4(d1 1) = 333.3 RECURSIVE = YES TRIGGERMAXDEPTH = 2 SHOW v1
The preceding statements produce the following output.
ERROR: Depth of NA trigger calls exceeds allowable (maximum depth 2)
The following statements set the maximum trigger depth to a higher value and show the value of the variable.
TRIGGERMAXDEPTH = 3 SHOW v1
The preceding statements produce the following output.
336.3