CATR examples

Last Updated : Sep 08, 2012 |

The following table provides examples for using the CATR operator. The CATR operator concatenates, or appends, the operand2 digit string to the right end of operand1.

Command

Result

set A = B CATR 0123

B = 56789

56789 CATR 0123 = 567890123

set A = A CATR A

A = #

# CATR # = none

set A = B CATR 0123

Variable definition:

  • A = collect type, length = 4, start = 3

  • B = 56789

56789 CATR 0123 = 567890123 = 7890

Four digits were selected starting at position 3 in the resulting digit string.

set digits = A CATR 0123

digits: length = 16, start = 1

A = 123456789012345

123456789012345 CATR 0123 = 01234567890123450123 = 1234567890123450

NOTE: 1234567890123450 is stored in the digits buffer.

set A = A CATR A

A = none (null string or empty)

none CATR none = none