1,240 pts.
 retrieve library list
how to retrieve library list when i pressed f4 in a field and is field has *all the it fetch all library listed in subfile

Software/Hardware used:
ASKED: April 13, 2012  11:45 AM
UPDATED: April 17, 2012  11:11 PM
  Help
 Approved Answer - Chosen by 9783444184 (Question Asker)

...it display only list of user library list i want all system library...

The simplest way is to use the DSPOBJD command to create a list of all user libraries in a temporary database file. Then read the records from that file in your RPG program.

The command might look like this:

DSPOBJD OBJ(*ALLUSR) OBJTYPE(*LIB) OUTPUT(*OUTFILE) OUTFILE(QTEMP/USRLIB)

You could also call the List Objects (QUSLOBJ) API and request a very similar list into a user space instead of a database file. No CL is needed for that, but it can be more complex.

Tom

ANSWERED:  Apr 16, 2012  8:18 PM (GMT)  by 9783444184

 
Other Answers:

Not quite sure what you are asking.

You can see the library list for an interactive job via the DSPLIBL or EDTLIBL commands. You can see the library list for a batch job via the WRKJOB command, and then take option 13. Or, to see a list of libaries that exist on a system, you can use the DSPOBJD command, and look for *ALL objects in library QSYS with object type *LIB.

Last Wiki Answer Submitted:  April 13, 2012  1:21 pm  by  LJansen   85 pts.
Latest Answer Wiki Contributors:  LJansen   85 pts.
To see other answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

Are you wanting to select one of the libraries?

 32,835 pts.

 

A job’s library list can be retrieved by calling the Retrieve Job Information (QUSRJOBI) API for the job and requesting format JOBI0700.

Tom

 108,055 pts.

 

In addition to the Retrieve Job Information API previously referenced by Tom, the Retrive Current Attributes (QWCRTVCA) API can also return the library list.

Bruce Vining

 6,055 pts.

 

Hi Tom,

Retrieve Job Information QUSRJOBI help me but QUSRJOBI it display only list of user library list i want all system library what i modify in my program to get all system library

Thanks

 1,240 pts.

 

i have created a cl program using dspobjd and when i call cl program i have got a message id CPF9860 Error occurred during output file processing.
hoe to solve it

 1,240 pts.

 

i have got a message id CPF9860 Error occurred during output file processing.
hoe to solve it

We will need to see the source for the CL program in order to know how the problem might be fixed.

Tom

 108,055 pts.