What is the behavior of READ PREVIOUS after START or on AT END?

Question ID : 152
Created on 2010-10-26 at 3:29 PM
Author : Veryant Support [support@veryant.com]

Online URL : http://support.veryant.com/support/phpkb/question.php?ID=152



After a START statement READ PREVIOUS reads the current record (i.e. the record whose key value is equal to the file position indicator).

On an AT END condition READ PREVIOUS returns the last record in the file.

Note that starting in isCOBOL 2009 SP2 (build 546.13) the behavior of READ PREVIOUS when using JISAM was changed to match that of other leading COBOL and ISAM indexed file system implementations.

In isCOBOL 2009 SP1 and earlier versions the behavior of READ PREVIOUS when using JISAM matched that of Informix C-ISAM (i.e. calling isread with the ISPREV mode causes C-ISAM to read the record with the key preceding the one that isstart found).



Back to Original Question