× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



You don't get it on SETLL - you get it on the read. I didn't notice that the code I commented on was not in a loop.

Personally, I would modify the code to use a priming read after the SETLL and then use EOF to control the loop.

Sorry if I confused you.


Jon P.


On Mar 18, 2023, at 1:32 PM, myibmi via RPG400-L <rpg400-l@xxxxxxxxxxxxxxxxxx> wrote:

Jon,

now I'm confused.
How do I get an eof condition after a setll?
Please explain. Maybe I'm not up to date. Thx.

Btw. an equal check can be done without reading access for a native write op.

-----Ursprüngliche Nachricht-----
Von: RPG400-L [mailto:rpg400-l-bounces@xxxxxxxxxxxxxxxxxx] Im Auftrag von Jon Paris
Gesendet: Samstag, 18. März 2023 18:02
An: RPG programming on IBM i
Betreff: Re: SETLL *START and %EQUAL

And that is exactly how it should be handled.


Jon P.

On Mar 18, 2023, at 1:13 AM, Jason Maple <jmaple0824@xxxxxxxxx> wrote:

I haven’t seen anyone say this, but why would you not simply use %EOF?
Like….
SETLL *START MyFile;
IF Not %EOF(MyFile);
READ MyFile;
ELSE;
do something different;
ENDIF;

You can stick it in a do loop if you want to read more than just one record.

Get Outlook for iOS<https://aka.ms/o0ukef>
________________________________
From: RPG400-L <rpg400-l-bounces@xxxxxxxxxxxxxxxxxx> on behalf of Patrik Schindler <poc@xxxxxxxxxx>
Sent: Friday, March 17, 2023 6:36:16 PM
To: RPG programming on IBM i <rpg400-l@xxxxxxxxxxxxxxxxxx>
Subject: Re: SETLL *START and %EQUAL

Hello Alan,

Am 17.03.2023 um 21:06 schrieb Alan Cassidy <cfuture@xxxxxxxxxxx>:

Your answer was good, I was just adding to yours and Jon's. I don't know why you thought mine was a reply to yours.

Because you quoted my text. :-)

:wq! PoC



--
This is the RPG programming on IBM i (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related questions.

--
This is the RPG programming on IBM i (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related questions.


--
This is the RPG programming on IBM i (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related questions.


--
This is the RPG programming on IBM i (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/rpg400-l.

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related questions.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.