Is it valid Syntax with MUs?

Hi Folks,

Below code compiles & executes without any syntax error, is it correct? I would like to understand how the stuff works with second field in DISPLAY. It takes the same occurence for both the fields in DISPLAY, but how by coding (#I+1)? I know, #I+1 should not increase the counter but is it valid to refer a MU i.e. ADDRESS-LINE like this? :shock:

Code

#I(I2) := 1
READ(10) EMPLOYEES
    WHERE ADDRESS-LINE NE ' '
  DISPLAY ADDRESS-LINE(#I) ADDRESS-LINE(#I+1)
END

The slight code change encounters NAT0429, as expected!

DISPLAY ADDRESS-LINE(#I+1) /* ADDRESS-LINE(#I+1)

I am posting an article and a past issue of Inside Natural which have discussions of MU syntax.

steve
IN Vol 13 No 2.pdf (786 KB)
Understanding MU Notation.doc (66 KB)

Thanks Steve, it’s valuable info! I shall go through it.

The documents are really nice… Thanks Steve!!!:slight_smile: