RRN Chain to subfile in RPG-Free

0 pts.
Tags:
RPG
How does one find whether a record is found or not while chaining with RRN to a subfile? Indicators are no good, %Found and %Eof are not valid for subfiles?
ASKED: November 5, 2004  11:07 AM
UPDATED: November 5, 2004  1:37 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

%Found will work with a subfile CHAIN. I ‘free-formed’ part of a program I have that does a chain to a subfile. When I entered the code ‘Chain (Rrn) Subfile;’, the compiler did not like it because the parentheses around the Rrn file is saying this is a key list which is not allowed for a subfile. Using ‘Chain Rrn Subfile;’ I was then able to chain to the subfile and use %Found immediately after the chain to execute the appropriate code.

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Jklipa
    Chapter 23 page 549 http://publib.boulder.ibm.com/iseries/v5r2/ic2924/books/c0925084.pdf /FREE CHAIN KEY FILEX; // If a record with a key value equal to the search argument is // not found, %FOUND returns ?0? and the EXSR operation is // processed. If a record is found with a key value equal // to the search argument, the program continues with // the calculations after the EXSR operation. IF NOT %FOUND; EXSR Not_Found; ENDIF; /END-FREE
    0 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following