ADSM-L

Re: select statement

2005-03-28 12:51:01
Subject: Re: select statement
From: Joni Moyer <joni.moyer AT HIGHMARK DOT COM>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Mon, 28 Mar 2005 12:50:35 -0500
Hello!

Thanks for the suggestion!  I am now getting another bizarre rc=3 when I
enter the command: dsmadmc -id= -pass= -tabdelimited 'select statement'
within single quotes.  The node name is CS-NICE-STORAGE so I entered the
following select statement: 'select node_name,filespace_name,hl_name ||
ll_name as "File",date(archive_date) as "Date",class_name from archives
where node_name="CS-NICE-STORAGE"'

It doesn't seem to like double quotes or single quotes around the
node_name.  Are quotes not needed?  Thanks again!


==>  archives where node_name="CS-NICE-STORAGE"'
<
IBM Tivoli Storage Manager
Command Line Administrative Interface - Version 5, Release 2, Level 0.0
(c) Copyright by IBM Corporation and other(s) 1990, 2003. All Rights
Reserved.

Session established with server TSMPROD: AIX-RS/6000
  Server Version 5, Release 2, Level 2.5
  Server date/time: 03/28/05   12:43:02  Last access: 03/28/05   12:31:12

ANS8000I Server command: 'select node_name,filespace_name,hl_name ||
ll_name as
"File" ,date(archive_date) as "Date" from archives where
node_name="CS-NICE-STOR
AGE"'
ANR2940E The reference 'CS-NICE-STORAGE' is an unknown SQL column name.

                                                       |
         ..............................................V................
         date) as "Date" from archives where node_name="CS-NICE-STORAGE"

ANS8001I Return code 3.

ANS8002I Highest return code was 3.
********************************
Joni Moyer
Highmark
Storage Systems
Work:(717)302-6603
Fax:(717)302-5974
joni.moyer AT highmark DOT com
********************************



             "Andrew Raibeck"
             <storman AT US DOT IBM.C
             OM>                                                        To
             Sent by: "ADSM:           ADSM-L AT VM.MARIST DOT EDU
             Dist Stor                                                  cc
             Manager"
             <[email protected]                                     Subject
             .EDU>                     Re: select statement


             03/28/2005 11:22
             AM


             Please respond to
             "ADSM: Dist Stor
                 Manager"
             <[email protected]
                   .EDU>






> Is there a way that I can get all of the info. on 1
> line

This was just discussed a week or so ago. You can start dsmadmc with the
-tabdelimited or -commadelimited option to get output on a single line,
then load the resulting output into a spreadsheet or db for easy viewing.

> and also make the archive_date split into date & time?

Specify columns names like this for getting separate date & time:

select date(archive_date) as "ARCHIVE DATE", time(archive_date) as
"ARCHIVE TIME", ...

Regards,

Andy

Andy Raibeck
IBM Software Group
Tivoli Storage Manager Client Development
Internal Notes e-mail: Andrew Raibeck/Tucson/IBM@IBMUS
Internet e-mail: storman AT us.ibm DOT com

The only dumb question is the one that goes unasked.
The command line is your friend.
"Good enough" is the enemy of excellence.

"ADSM: Dist Stor Manager" <ADSM-L AT VM.MARIST DOT EDU> wrote on 2005-03-28
09:14:24:

> Hey!
>
> I am trying to put together a select statement to find all archives for
> CS-NICE-STORAGE, but it is showing me the output in the below format. Is
> there a way that I can get all of the info. on 1 line and also make the
> archive_date split into date & time?  Thanks in advance!
>
> Here is the command I was running: select
node_name,filespace_name,hl_name
> || ll_name as "File",archive_date,class_name from archives where
> node_name='CS-NICE-STORAGE'
>
>      NODE_NAME: CS-NICE-STORAGE
> FILESPACE_NAME: \\cs-nice-storage\c$
>           File: \COMPAQ
>   ARCHIVE_DATE: 1900-01-01 00:00:00.000000
>     CLASS_NAME: DEFAULT
>
>      NODE_NAME: CS-NICE-STORAGE
> FILESPACE_NAME: \\cs-nice-storage\c$
>           File: \COMPAQ
>   ARCHIVE_DATE: 1900-01-01 00:00:00.000000
>     CLASS_NAME: DEFAULT
>
>      NODE_NAME: CS-NICE-STORAGE
> FILESPACE_NAME: \\cs-nice-storage\c$
>           File: \COMPAQ
>   ARCHIVE_DATE: 1900-01-01 00:00:00.000000
>     CLASS_NAME: DEFAULT
>
>      NODE_NAME: CS-NICE-STORAGE
> FILESPACE_NAME: \\cs-nice-storage\c$
>           File: \COMPAQ
>   ARCHIVE_DATE: 1900-01-01 00:00:00.000000
>     CLASS_NAME: DEFAULT
>
> ********************************
> Joni Moyer
> Highmark
> Storage Systems
> Work:(717)302-6603
> Fax:(717)302-5974
> joni.moyer AT highmark DOT com
> ********************************

<Prev in Thread] Current Thread [Next in Thread>