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


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).



Article ID: 152
Created: October 26, 2010
Last Updated: October 26, 2010
Author: Support KB Author

Online URL: https://support.veryant.com/phpkb/article.php?id=152