|
You want to move the SetLL outside of the loop or your loop will never end. You'll be happier if you prime the pump with a read. $Load_Hdr_Rec Begsr *Start setll DAHDRT00 READ DAHDRT00 DOW NOT %EOF(DAHDRT00) (do your stuff here) READ DAHDRT00 enddo As a matter of interest, if reading the file sequentially is the whole idea, use the cycle. Define the file as IP or UP and none of this code is needed. It just happens. That is what the cycle does for you. --------------------------------------------------------- Booth Martin http://www.MartinVT.com Booth@MartinVT.com --------------------------------------------------------- -------Original Message------- From: RPG programming on the AS400 / iSeries Date: Thursday, January 16, 2003 02:08:51 AM To: 'RPG programming on the AS400 / iSeries' Subject: sequential read I ve to read sequentially Header(flat file) file which doesnt have key how can i read from first record onwards is this what i wrote right? $Load_Hdr_Rec Begsr DOW NOT %EOF(DAHDRT00) *Start setll DAHDRT00 READ DAHDRT00 enddo
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.