HP P9000 Continuous Access Synchronous for Mainframe Systems User Guide (AV400-96398, October 2011)
be met. You must end an If statement with an IF/EndIf statement. The execution statement cannot
be defined on the same line as the If statement. The If statement must contain one conditional
decision statement within parentheses. The string values must be compared as ASCII character
codes (see Table 56 (page 118)). The format for an IF/EndIf statement is:
If expression one compared with expression two (see Table 57 (page 118) for comparison
expressions)
Macro statement, either internal or functional.
IF/EndIf
For example, to start a pair only if the pair was created successfully (result value of CreateHrcPair
command is 0), use the IF/EndIf command as shown in the following example.
Example 14 If/Endif format
If (_Result==0)
StartHrcPair
EndIf
Table 56 ASCII character codes
CodeCharacter
0x300
0x311
0x399
0x41A
0x5aZ
0x61a
0x7az
Table 57 (page 118) shows the symbols for the allowed comparison expressions, and their meanings.
Table 57 If/EndIf comparison symbols
MeaningSymbol
Expression 1 is equal to Expression 2.= =
Expression 1 is less than Expression 2.<
Expression 1 is less than or equal to Exp 2.<=
Expression 1 is greater than Expression 2.>
Expression 1 is greater than or equal to Exp 2.>=
Expression 1 is not equal to Expression 2.!=
MakeString
The MakeString allows you to edit a string and/or convert numeric values to string characters.
When using the MakeString statement several conditions must be met. For each format control
string statement there must be an $Item statement. The format control string of expression 1 must
be enclosed in quotation marks (““). If you set a value exceeding the maximum length of a string,
the extraneous portion of the value will be not set.
Table 58 (page 119) defines the two expression statement in the MakeString command. The
following example shows the format for the MakeString command.
118 Continuous Access Synchronous Z scripting