Question

  Asked: Apr 22 2008   3:38 PM GMT
  Asked by: ERICPELL


Remove library from all library lists


AS/400, OS/400, JOBD

We've stopped using a vendor's product that has been here since we first became a 400 shop 12+ years ago. The vendor's libraries have found their way into hundreds of job descriptions across the system. Is there an easy way to remove the entries for these libraries from all the job descriptions? I've been checking to see if there are locks on the libraries to see what currently running jobs reference them but am afraid of a scheduled task for another call program referencing a job description with a missing library and failing to run.

Subscribe to Alerts! Get questions and answers delivered to your Inbox.


E-mail me updates on this question



   SUBSCRIBE

hidden modal window

Answer Wiki (Improve, edit or add to this answer)


 RATE THIS ANSWER
0
Click to Vote:
  •   0
  •  0



I don't know if you would consider this "easy", but you could use the List Objects API to get a list of all *JOBDs on your system. Given this list, you could then loop through each returned *JOBD and use the Retrieve Job Description Information API to access the initial library list found in each *JOBD. Search the *JOBD initial library for the library in question and, if found, construct a proper CHGJOBD command to set the new library list and use an API such as QCMDEXC or QCAPCMD to run the CHGJOBD. This approach would cover all *JOBDs and would not be overly difficult to automate (if you're familiar with system APIs).

Bruce Vining
http://www.brucevining.com/
Providing integrated solutions for the System i user community
  • AddThis Social Bookmark Button

Browse more Questions and Answers on AS/400.

Looking for relevant AS/400 Whitepapers? Visit the Search400.com Research Library.


Discuss This Answer


You must be logged-in to discuss a question. Log-in/Register

Gilly400  |   Apr 23 2008  8:43AM GMT

Hi,

It might also be worth looking to reduce the number of job descriptions that you’re using if you have hundreds of them. This would make similar tasks in the future quicker and easier.

Regards,

Martin Gilbert.