TDWMRuleControl Function | Application Programming Reference | Teradata Vantage - TDWMRuleControl - Advanced SQL Engine - Teradata Database

Application Programming Reference

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
cpn1571792172880.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1090
lifecycle
previous
Product Category
Teradata Vantageā„¢

Purpose

Updates the EnabledFlag of the rule and the EnabledFlag in the base state for the rule in the TDWM database.

Definition

REPLACE PROCEDURE TDWM.TDWMRuleControl
   (IN RuleSetId   INTEGER,
    IN RuleName    TD_ANYTYPE,
    IN Operation   VARCHAR(1) CHARACTER SET LATIN,
    IN TDWMLock    VARCHAR(1) CHARACTER SET LATIN
   )
              .
              .
              .
;

Input Parameters

Input Parameter Description
RuleSetId ID of the rule set in which the rule is found.
RuleName Name of the rule specified.
Operation Request to enable or disable the rule:
  • E = Enable the rule
  • D = Disable the rule
TDWMLock Type of request performed on the TDWMLock table:
  • W = Wait for the TDWMLock
  • A = Abort if the TDWMLock table is locked
  • S = Perform the update without locking the TDWMLock table
The TDWM places an exclusive lock on the TDWMLock table at startup.

Usage Notes

The TDWMRuleControl procedure must be used with rules defined only with the base state as this is the only state value that the procedure changes.

Example: Using TDWMRuleControl

CALL TDWM.TDWMRuleControl(1, 'throttle1', 'D', 'W');