TDWMAddLimitForRuleState | Application Programming Reference | Vantage - 17.10 - TDWMAddLimitForRuleState - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - Application Programming Reference

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Programming Reference
Publication ID
B035-1090-171K
Language
English (United States)

Adds the default limit or query limit for a specific state. This step is repeated for each state, if necessary. At least one of these calls must specify the default limit.

This XPS is intended to support any TASM rule types (for example, throttle, arrival rate meter, workload, filter, and so on). However, only system throttle and arrival rate meter are supported in this release.

Syntax

REPLACE PROCEDURE TDWM.TDWMAddLimitForRuleState (
  IN RulesetName TD_ANYTYPE,
  IN RuleName TD_ANYTYPE,
  IN StateName TD_ANYTYPE,
  IN Description TD_ANYTYPE,
  IN StateLimit VARCHAR(50) CHARACTER SET LATIN,
  IN Action VARCHAR(6) CHARACTER SET LATIN,
  IN ReplaceOption CHAR(1) CHARACTER SET LATIN
)
  ...
;

Syntax Elements

RulesetName
Name of the ruleset that contains the RuleName. Use ‘ALLRULESETS’ to add limit for the specified rule state in all existing rulesets. Cannot be null and its length must be between 1 and 30.
RuleName
Name of the throttle to add the limit. The specified name must be unique among all existing TASM rules: throttles, arrival rate meters, workloads, filters, and so on. Cannot be null and the length must be between 1 and 30.
StateName
Name of the state of the RuleName to add the limit. ‘DEFAULT’ is reserved for the default limit that is used for any state that does not have a specific limit. A combination of RulesetName, RuleName, and StateName uniquely identifies a specific rule state. If RulesetName is ‘ALLRULESETS’, the limit is added for the same StateName of the same RuleName in all existing rulesets.
Description
Description of the state limit. Description can be null. The maximum length is 80.
StateLimit
Depending on the rule type, the limit of a state may be specified in one of the following forms:
  • 'NOLIMIT' = No limit for a state.
  • 'number' = A non-negative number specifying the limit of a state.
  • 'arrivalRateLimit' = An arrival rate meter limit. Use arrivalRateLimit only if the RuleName specifies an arrival rate meter. Use the format:
    number/timeout QT=seconds
    • number: A non-negative number specifying the limit of a state.
    • timeunit: H = hour, M = minute, S = seconds
    • seconds: A non-negative number specifying qualification time in seconds.
Action
Action to take when limit is exceeded. These choices are mutually exclusive.
  • 'D' = delay
  • 'R' = reject
ReplaceOption
  • 'Y' = Delete the all existing limits of the specified state and add a new state limit. If the specified state does not exist or does not have any sub-criteria, an error is returned.
  • 'N' = Add the specified state limit. If the specified state has a limit, an error is returned.