I think u need to set the format in SQL for o/p. That will solve ur problem. U need to write sql script and then call it from the connect string on shell script. Balanand
-----Original Message----- From: MC Matt Cooper (2838) [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 27, 2002 9:01 AM To: [EMAIL PROTECTED] Subject: Re: NEED HELP CONTROLLING SCRIPT OUTPUT, FIELD LENGTHS Ike, I am running the following batch job. I added the -TAB and tried -OUTFILE with a redirect in the macro to the data set and that didn't work either. So I tried a few different variation of the above and even went back to adding a / after the ADSMC as the book says. None of it made a difference. It always came back with the output looking the same. Ideally I would want just the needed fields, with fixed length 1 per line. Matt THE JOB..... //TSMJOB1 EXEC PGM=IKJEFT01 //STEPLIB DD DSN=SYS1.CEE.SCEERUN, // DISP=SHR //DSCLANG DD DSN=SYS1.TSM.SANSMSG(ANSMENU),DISP=SHR //DSCOPT DD DSN=AGPP.TSM.TSOADMIN.OPTIONS,DISP=SHR //SYSHELP DD DSN=SYS1.TCPIP.SEZAHELP,DISP=SHR //SYSIN DD DUMMY //D1 DD DSN=AGPP.TSM.INACTIVE.NODES,DISP=SHR //SYSTSIN DD * DSMADMC -ID=ADMINJOB -PASSWORD=xxxxxxxx -OUTFILE=DD:D1 MACRO DD:D2 -TAB //D2 DD * select node_name,lastacc_time,contact from nodes where - cast((current_timestamp-lastacc_time)days as - decimal) >= 7 /* //SYSTSPRT DD SYSOUT=* //SYSUDUMP DD SYSOUT=* THE OUTPUT FILE .... ADSTAR Distributed Storage Manager Command Line Administrative Interface - Version 3, Release 1, Level 0.7 (C) Copyright IBM Corporation, 1990, 1999, All Rights Reserved. ANS8000I Server command: 'select node_name,lastacc_time,contact from nodes where NODE_NAME LASTACC_TIME CONTACT ------------------ ------------------ ------------------ DTE-1710 2002-03-15 Dan 09:28:26.000000 Harrison/Desktop DTE-1720 2002-03-15 SUE 23:27:49.000000 NEBINGER/DESKTOP -----Original Message----- From: Hunley, Ike [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 27, 2002 8:21 AM To: [EMAIL PROTECTED] Subject: Re: NEED HELP CONTROLLING SCRIPT OUTPUT, FIELD LENGTHS Matt, What do you do to execute the select command in the z/OS environment? -----Original Message----- From: MC Matt Cooper (2838) [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 27, 2002 8:15 AM To: [EMAIL PROTECTED] Subject: NEED HELP CONTROLLING SCRIPT OUTPUT, FIELD LENGTHS Hello all, I am trying to write a simple script that shows the nodes that were not accessed by TSM for more than x days and then do an E-mail notification from there. I AM RUNNING TSM 4.1.5 on z/OS 1.1. The select command to get the node name, last access date, and contact name (the e-mail address) seems easy enough. BUT I want the output from this to be in one line, preferably with fixed position or filed lengths. ( I will be using SAS processing to setup the job that will actually do the EMAIL). I have tried the approach documented in the 3rd chapter of the TSM Refernece manual but I can not get the desired results. It always comes back with the output for 1 node with last access and contact name using two lines. Has anyone ever had any success with this in OS390 environment? I could go a long way with an example . Thanks Matt Blue Cross Blue Shield of Florida, Inc., and its subsidiary and affiliate companies are not responsible for errors or omissions in this e-mail message. Any personal comments made in this e-mail do not reflect the views of Blue Cross Blue Shield of Florida, Inc.