AS/400 CLLE: Get second member from physical file

435 pts.
Tags:
AS 400
CLLE
Physical File
SQL Query
How to get second member from a physical file through SQL query or work query?

Answer Wiki

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

It would be no different that getting the 7th like asked in a previous post. 


use the command 
DSPFD FILE(MYLIB/MYFILE) TYPE(*MBRLIST) 
OUTPUT(*OUTFILE) OUTFILE(QTEMP/MEMBERS) 
to dump the members to a file then set the rrn to this file for the member name

Discuss This Question: 6  Replies

 
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.
  • GregManzo
    If you are trying to access a particular member from SQL, check out the CREATE ALIAS command.
    2,515 pointsBadges:
    report
  • vivekntt21
    Eg: We have a physical file called 'City' and in that we have 2 members 1) Chennai 2) pune and how to get pune member from that file using Create alias command?
    435 pointsBadges:
    report
  • ToddN2000
    create alias mylib/aliasname for srclib/srcfile(srcmbr)
    102,670 pointsBadges:
    report
  • ToddN2000
    Don't forget when done you need to run

    DROP ALIAS MYLIB/ALIASNAME
    102,670 pointsBadges:
    report
  • GregManzo
    or alternatively, create the alias in QTEMP.
    2,515 pointsBadges:
    report
  • TheRealRaven
    Use CREATE ALIAS to create a permanent object that may be accessed by multiple users in multiple jobs. Use OVRDBF for temporary accesses in a single job.
    24,415 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.

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

Following

Share this item with your network: