Page 1 of 1

delete datasets

Posted: Thu Nov 29, 2007 6:46 pm
by just4u_sharath
Can i delete more than 2 or 3 datasets using the execute command activity. i know to delete one dataset by giving "orchadmin rm -f" in command line adn "controlfile.ds" in parameter. but can i delete 2 or 3 datasets in a single execute command

Posted: Thu Nov 29, 2007 9:20 pm
by ray.wurlod
Only by constructing a multiple command pipeline.

Code: Select all

orchadmin rm
controlfile1.ds ; orchadmin rm controlfile2.ds ; orchadmin rm controlfile3.ds
Alternatively (and better, I believe) construct a shell script containing the required commands and execute that.
You can also include other commands (such as echo) to report the results of the individual commands based on their exit status ($?) and to force the script to return successfully (exit 0).

Posted: Fri Nov 30, 2007 12:49 am
by stefanfrost1
Maybe I am terrably wrong here but I remember myself doing the same thing just putting the filenames after eachother in one file command....


orchadmin rm -f controlfile1.ds controlfile2.ds controlfile3.ds

Note: in AIX 5.3 Unix that is

delete datasets

Posted: Fri Nov 30, 2007 4:50 pm
by just4u_sharath
I did the same thing using

"orchadmin rm -f controlfile1.ds controlfile2.ds controlfile3.ds" in execute command activity. It is working. Is this wrong approach
command line:orchadmin rm -f
parameters:controlfile1.ds controlfile2.ds controlfile3.ds

Please tell me abt this approach and anyy other better approaches are welcome

Posted: Sun Dec 02, 2007 11:15 pm
by abc123
I have been deleting datasets using:

orchadmin delete *.ds

This deletes all datasets in the directory where you are executing the command.