7 9 2 CHANGE Comments Warnings

LANSA Technical

7.9.2 CHANGE Comments/Warnings

  • When changing multiple variables simultaneously to an expression, the position of the field will affect the result as shown in examples A and B.

Define Field(#STD_NUMSV) Reffld(#STD_NUM)
 

     Example A: #std_num gets value 5 and #std_numsv gets value 6

     Change Field(#STD_NUM) To(4)
     Change Field(#STD_NUM #STD_NUMSV) To('#std_num + 1')
 

     Example B: #std_num gets value 5 and #std_numsv gets value 5

     Change Field(#STD_NUM) To(4)
     Change Field(#STD_NUMSV #STD_NUM) To('#std_num + 1')
 

Using quotes

  • In RDML functions, a literal whose first character looks like a number (begins with plus, minus, decimal point or a digit), must be triple quoted using three single quotes. For example:

     CHANGE FIELD(#ADDRESS1) TO('''1 Mount  ST''')
 

  • In RDMLX code:
  • The literal needs to be enclosed in double quote characters:

           CHANGE FIELD(#ADDRESS1) TO("1 Mount  ST")
 

  • When assigning the value, the literal can be in either single or double quotes:

          #ADDRESS1 := '1 Mount  ST'
or
          #ADDRESS1 := "1 Mount  ST"