READS-PREVIOUS
|
Syntax: |
READS-PREVIOUS(<Key Number>) <Name
of Index File> ON ERROR … END
|
||||
|
|
|
||||
|
Meaning: |
Reads the previous data record (previous to
the current record) from an Index File in the sorting order of the secondary
key <Key Number>. In the case of an error the block ON ERROR ... END is
executed. This instruction is only allowed if a valid READS-,
STARTS-, READS-PREVIOUS- or READS-NEXT instruction has been executed before with the same key <Key
Number>, otherwise the error 1021 is reported. |
||||
|
Parameter: |
|
||||
|
Sample: |
CUSTOMER.NAME$ = CHR$(255) STARTS(1) CUSTOMER ON
ERROR END END% = 0 READS-PREVIOUS(1) CUSTOMER ON
ERROR END% = 1 END WHILE END% = 0 DO … READS-PREVIOUS(1) CUSTOMER ON ERROR
END% = 1 END ENDDO |
||||
|
See also: |
|