Previous Topic

Next Topic

Book Contents

Book Index

Expression Delimiters

When creating rule definitions with the Online facility, quotes are automatically and appropriately placed within the definition. When creating rule definitions with an editor, BMC recommends the manual insertion of quotation marks.

Control-M/Analyzer recognizes two types of quotes:

Table 274 Control-M/Analyzer Expression Delimiters

Quote

Description

Apostrophe ( ’ )

Used to delimit data strings or Control-M/Analyzer Expressions.

Consecutive apostrophes ( ’ ’ )

Used to delimit data strings within Control-M/Analyzer Expressions.

Variables and expressions whose operands are numeric do not need to be delimited by apostrophes:

IF SUM > 250 is equivalent to IF 'SUM > 250'

IF DB_TOTAL=TOTAL is equivalent to IF 'DB_TOTAL=TOTAL'

IF TOTAL=1000 is equivalent to IF 'TOTAL=1000'

Data strings must always be delimited:

DO PRINT 'DATA ARE BALANCED'

DO REMARK 'DATA ARE BALANCED'

If a data string exists within an expression, both the expression and the data string must be delimited. The expression is delimited with apostrophes, and the data string is delimited with two consecutive apostrophes (quotation marks).

IF 'DB_EMPNAME = ''JONES'' '

DO SET GRADE EVAL ' '' A '' '

where A is a literal and not a variable name.

See Operands for examples of expressions that are and are not delimited by apostrophes.

BMC recommends that you do not specify Control-M/Analyzer reserved words within rule, mission, and variable definitions. However, reserved words may be specified if enclosed between apostrophes:

DO RULE 'DATA'

ON_FILE 'FORM' ON_PARM MODE PG LINECT 60

Note: DATA and FORM – in the examples above – are reserved words. For a complete list of reserved words, see Reserved Words.

AND is both an operator and a reserved word (as a parameter of statement WHEN). When specified as an operator, AND must be placed between apostrophes along with the rest of the expression.

Valid:

IF 'DB_TOTAL < 1000 AND DB_TOTAL > 500'

Invalid:

IF 'DB_TOTAL < 1000' AND 'DB_TOTAL > 500'

Parent Topic

Language Syntax