library list command? - IBM AS400

This is a discussion on library list command? - IBM AS400 ; I would like to list all the source files with their descriptions for a library in one printout. Is there a way to do this without hitting printscreen dozens of times? IS400/V5R3 thanks...

+ Reply to Thread
Results 1 to 5 of 5

Thread: library list command?

  1. library list command?

    I would like to list all the source files with their descriptions for
    a library in one printout.
    Is there a way to do this without hitting printscreen dozens of times?

    IS400/V5R3

    thanks

  2. Re: library list command?

    Malak wrote:
    > I would like to list all the source files with their descriptions for
    > a library in one printout.
    > Is there a way to do this without hitting printscreen dozens of times?
    >
    > IS400/V5R3
    >
    > thanks


    Assuming you have PDM, STRPDM, get the list of source members displayed,
    press F21.

  3. Re: library list command?

    On Aug 6, 3:22*pm, Malak wrote:
    > I would like to list all the source files with their descriptions for
    > a library in one printout.
    > Is there a way to do this without hitting printscreen dozens of times?
    >
    > IS400/V5R3
    >
    > thanks


    Display file descriptions to a file, then query the file:

    DSPFD FILE(PBSSRC/*ALL) TYPE(*ATR) OUTPUT(*OUTFILE) FILEATR(*PF)
    OUTFILE(your-file-name)

    SELECT PHFILE, PHTXT FROM your-file-name WHERE PHDTAT ='S'

  4. Re: file list command?

    Brian wrote:
    > On Aug 6, 3:22 pm, Malak wrote:
    >> I would like to list all the source files with their descriptions
    >> for a library in one printout. Is there a way to do this without
    >> hitting printscreen dozens of times?
    >>
    >> IS400/V5R3

    >
    > Display file descriptions to a file, then query the file:
    >
    > DSPFD FILE(PBSSRC/*ALL) TYPE(*ATR) OUTPUT(*OUTFILE) FILEATR(*PF)
    > OUTFILE(your-file-name)
    >
    > SELECT PHFILE, PHTXT FROM your-file-name WHERE PHDTAT ='S'


    Of course if a query is to be used, then there is an active list
    available directly, versus generating a temporary file:

    SELECT DBXFIL, DBXTXT FROM QSYS.QADBXLFI
    WHERE DBXLIB='TheLibName'
    AND DBXATR='PF' AND DBXTYP='S'

    Note: QADBXLFI is used only because it is generally authorized; the
    physical data is in QADBXREF. Any authorized VIEW over that physical
    file can be used, instead of referring to a DDS LF in the SQL SELECT.
    Some existing VIEW may not have access to the DBXTYP, and creating a
    VIEW on QADBXREF requires *ALLOBJ special authority.

    The above could be done embedded in REXX or performed at a command
    line using the DB2 command [line interface] within QSHell, having the
    output directed to STDOUT. QSH CMD examples for similar should be
    available in the group archives and elsewhere.

    Also a possible option, issue the following command:

    WRKOBJPDM TheLibName *ALL *FILE OBJATR('PF-SRC') /* Use the
    function key that is defined to print the list when it is presented; F21
    was noted by gb in another post */

    Regards, Chuck

  5. Re: file list command?

    Well, look at that... a nice short printout with only the pertinent
    info
    via F21!

    thanks for answering a newbie question


+ Reply to Thread