>From the various list inputs and trials, this seems the simplest way: >From the AIX command line:
dsmadmc -dataonly=yes -TAB -id=admin -pa=<password> "Select 'del vol ' || volume_name || ' discard=yes wait=yes' from volumes where stgpool_name='CPSATABG'" > XYZ5 then from TSM admin command line: macro XYZ5 >>> [EMAIL PROTECTED] 12/08/06 10:13 AM >>> >> On Thu, 7 Dec 2006 14:13:01 -0500, Lawrence Clark <[EMAIL PROTECTED]> said: > This was a bear trying to get output in a friendly form to execute as a > macro. Might be helpful to others. > What worked for me: > 1). I built the query in one file with redirtection in the command > line: > /home/root/bin/dsmcmdx "select 'move data', volume_name from volumes > where stgpo > ol_name='CPSATABG'" > DSMSQLTEXT > 2) I have the dsmadmc in another file with the -TAB option: > dsmadmc -id=<admin> -pa=<password> -TAB $1 *koff* >> On Tue, 05 Dec 2006 17:32:08 -0500, "Allen S. Rout" <[EMAIL PROTECTED]> said: } dsmadmc -dataonly -tab " select 'del vol ',volume_name,' wait=yes' where your_criterion_here " > something.macro I really like the SQL concatenation suggestion Bill made: dsmadmc -dataonly -tab " select 'del vol ' || volume_name || ' wait=yes' where your_criterion_here " > something.macro would be the revised suggestion. - Allen S. Rout The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain information that is confidential, privileged, and/or otherwise exempt from disclosure under applicable law. If this electronic message is from an attorney or someone in the Legal Department, it may also contain confidential attorney-client communications which may be privileged and protected from disclosure. If you are not the intended recipient, be advised that you have received this message in error and that any use, dissemination, forwarding, printing, or copying is strictly prohibited. Please notify the New York State Thruway Authority immediately by either responding to this e-mail or calling (518) 436-2700, and destroy all copies of this message and any attachments.
