Delete 100 jobs via script

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
mandyli
Premium Member
Premium Member
Posts: 898
Joined: Wed May 26, 2004 10:45 pm
Location: Chicago

Delete 100 jobs via script

Post by mandyli »

Hi

I would like delete unused jobs from DataStage repository. Is there any way I can run scripts to delete the these jobs?


Thanks
Man
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

You can use istool to delete DataStage assets as noted here. You'll need to know what type of job it is in order to leverage that.
-craig

"You can never have too many knives" -- Logan Nine Fingers
mandyli
Premium Member
Premium Member
Posts: 898
Joined: Wed May 26, 2004 10:45 pm
Location: Chicago

Post by mandyli »

Thanks Lot.

how to initiate the istool command

ex: cd $DSHOME
istool> delete -help

Thanks
Man
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

From the link:
The preferred way to run this command is in the istool command-line window. If you run this command in your operating system command-line window or in scripts, you must add istool to the command name.
Based on your initial requirements of doing this from a script, it sounds like you should go with the latter. And if for some reason you've not used it before, there are a plethora of posts here on 'istool' and its syntax.

Documented here. Andy post here.
-craig

"You can never have too many knives" -- Logan Nine Fingers
mandyli
Premium Member
Premium Member
Posts: 898
Joined: Wed May 26, 2004 10:45 pm
Location: Chicago

Post by mandyli »

Sorry I got it.

istool from client side not from server side.

is this safe way to delete the jobs using istool?


Thanks
Man
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Well... it's an official way and orders of magnitude safer than when I've seen people roll their own and run delete SQL against the repository. :shock:
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I'd still prefer to use Director client. Disable view of folders and you can see all jobs in the project (probably make the refresh interval quite long too). Then you can take your time over selecting the correct jobs before deleting.

Don't forget to backup (export project) before deleting.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply