<snip>
I had to look up the "CONTINUE" statement.  In 25 years I've never used
it,
and don't even remember seeing it used.  Now I know what it does I think
it
should be banned.
</snip>

I  use CONTINUE all the time when processing
records that must meet multiple conditions in a loop. This way my code doesnt
look like 'flying geese'. I will write:

LOOP WHILE READNEXT ID
   READ RECORD
FROM FILE, ID ELSE CONTINUE
   IF RECORD<FLD.1> NE COND1 THEN CONTINUE
   IF
RECORD<FLD.2> NE COND2 THEN CONTINUE
   IF RECORD<FLD.3> NE COND3 THEN
CONTINUE
   RECORD<FLD.4> = 'PROCESSED'
   WRITE RECORD TO FILE, ID
REPEAT
instead of:

LOOP WHILE READNEXT ID
   READ RECORD FROM FILE,ID THEN
      IF
RECORD<FLD.1> EQ COND1 THEN
         IF RECORD<FLD.2> EQ COND2 THEN
IF RECORD<FLD.3> EQ COND3 THEN
               RECORD<FLD.4> = 'PROCESSED'
WRITE RECORD TO FILE, ID
            END
         END
      END
   END
REPEAT
___________________________________________________________
Yahoo! Answers -
Got a question? Someone out there knows the answer. Try it
now.
http://uk.answers.yahoo.com/
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to