> >>     READNEXT ID FROM LIST ELSE ID = @AM 
> >But why do you use an odd convention like ID = @AM ?

because it would be impossible for ID to be an attribute mark via
readnext.
If you later test for ([EMAIL PROTECTED]) there's only one way that could have
happened.

I'll admit to occasionally doing similar things:

   READ REC ... ELSE REC = @IM  ;* something impossible.

or
   LAST.BREAKDAT = @AM ; * init to something impossible
   LOOP
     ...
     BREAKDAT = REC< 10 >
     IF BREAKDAT = LAST.BREAKAT THEN
        GOSUB INCREMENT.TOTALS
     END ELSE
        GOSUB BREAKPOINT
        LAST.BREAKDAT = BREAKDAT
     END
     ...
   REPEAT


But with readnext I do prefer to dispense with flags and extra coding
   LOOP WHILE READNEXT ID
      . . .
   REPEAT

I believe any statement that has THEN & ELSE clauses can be used this
way.
E.g.:
   LOOP WHILE READSEQ LINE FROM F
     . . .
   REPEAT

cds
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to