Richard, Sorry. The error msg was: tsm: ABZBKUP001>SELECT STGPOOL_NAME AS " STORAGE POOL ", CHAR(VOLUME_NAME,6) AS "VOLNAME", PCT_UTILIZED as "PC T UTIL", DEC(EST_CAPACITY_MB,6) AS "MB_CAPACITY", CHAR(ACCESS,11) AS "ACCESS", LEFT(CHAR(LAST_WRITE_DATE),19) AS "LAST_WRITE_DATE" FROM VOLUMES WHERESTATUS='FILLING' ORDER BY STGPOOL_NAME ANR2907E Unexpected SQL operator token - '='.
| ...............................V............................... _DATE" FROM VOLUMES WHERESTATUS='FILLING' ORDER BY STGPOOL_NAME ANS8001I Return code 3. And right enough, I'd entered it as one line. I tried again with the continuation characters and it errored out, then I tried chaning the est_capacity to 7 as suggested, but got the same error: SELECT STGPOOL_NAME AS " STORAGE POOL ", - cont> CHAR(VOLUME_NAME,6) AS "VOLNAME", PCT_UTILIZED as "PCT UTIL", - cont> DEC(EST_CAPACITY_MB,6) AS "MB_CAPACITY", CHAR(ACCESS,11) AS "ACCESS", - cont> LEFT(CHAR(LAST_WRITE_DATE),19) AS "LAST_WRITE_DATE " - cont> FROM VOLUMES WHERE STATUS='FILLING' ORDER BY STGPOOL_NAME ANR2948E The value '381468.0' can not be assigned or converted to SQL data type DECIMAL(6,1). | ........................V...................................... ED as "PCT UTIL", DEC(EST_CAPACITY_MB,6) AS "MB_CAPACITY", CH ANS8001I Return code 26. tsm: ABZBKUP001>SELECT STGPOOL_NAME AS " STORAGE POOL ", - cont> CHAR(VOLUME_NAME,6) AS "VOLNAME", PCT_UTILIZED as "PCT UTIL", - cont> DEC(EST_CAPACITY_MB,7) AS "MB_CAPACITY", CHAR(ACCESS,11) AS "ACCESS", - cont> LEFT(CHAR(LAST_WRITE_DATE),19) AS "LAST_WRITE_DATE " - cont> FROM VOLUMES WHERE STATUS='FILLING' ORDER BY STGPOOL_NAME ANR2948E The value '4096000.0' can not be assigned or converted to SQL data type DECIMAL(7,1). | ........................V...................................... ED as "PCT UTIL", DEC(EST_CAPACITY_MB,7) AS "MB_CAPACITY", CH ANS8001I Return code 26. Regards, Iain Barnetson IT Systems Administrator UKN Infrastructure Operations -----Original Message----- From: ADSM: Dist Stor Manager [mailto:[EMAIL PROTECTED] On Behalf Of Richard Sims Sent: 07 March 2005 12:54 To: ADSM-L@VM.MARIST.EDU Subject: Re: [ADSM-L] LTO Volume On Mar 7, 2005, at 6:25 AM, Iain Barnetson wrote: > Ruichard, > I tried the SQL query below that you gave, but got an error "where > status='filling'" at the '=' bit And the error was... ? The Select is tried-and-true, and works well. Perhaps you tried to string the whole command out on one line, rather than using continuation characters so that the length of each physical line was less than the 256 char maximum? Below is the Select in its original macro form, which includes continuation chars. (I wish I could send it as an attachment, to assure format preservation, but the ADSM-L listserver is configured to reject such attachments.) Richard /* ADSM macro 'filling' */ /* */ /* To display volumes in Filling state. */ /* */ /* INVOCATION: macro filling */ /* */ /* NOTES: - */ /* */ /* HISTORY: */ /* */ /* 2003/05/06 Written by Richard Sims */ /* */ SELECT STGPOOL_NAME AS " STORAGE POOL ", - CHAR(VOLUME_NAME,6) AS "VOLNAME", PCT_UTILIZED as "PCT UTIL", - DEC(EST_CAPACITY_MB,6) AS "MB_CAPACITY", CHAR(ACCESS,11) AS "ACCESS", - LEFT(CHAR(LAST_WRITE_DATE),19) AS "LAST_WRITE_DATE " - FROM VOLUMES WHERE STATUS='FILLING' ORDER BY STGPOOL_NAME