How to use more than one key field in CHAIN opcode

220 pts.
Tags:
AS/400
Physical File
I have a physical file it contains three key fields how to use all three key fields in CHAIN opcode
ASKED: November 28, 2012  7:25 AM
UPDATED: November 28, 2012  12:40 PM

Answer Wiki

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

Use KLIST operation code and define all three key fields there.  Then use KLIST to CHAIN the record.

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
  • TomLiotta
    From the RPG Reference Manual under the 'CHAIN' topic:
    If the file is an externally-described file, search-arg can also be a composite key in the form of a KLIST name, a list of values, or %KDS.
    So, you can list the key fields in a KLIST, or you can list them in the CHAIN instruction itself, or  you can list them in a key data structure. The language reference manual is where you should find answers for questions like this one.   Tom
    125,585 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