ADSM-L

Re: select node summary

2004-11-18 13:50:45
Subject: Re: select node summary
From: Andrew Raibeck <storman AT US.IBM DOT COM>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Thu, 18 Nov 2004 11:50:20 -0700
I think you are looking more for something like this:

select entity as node_name,
      date(start_time) as date,
      cast(activity as varchar(10)) as activity,
      time(start_time) as start,
      time(end_time) as end,
      cast((bytes/1000000) as decimal(6,0)) as megabytes,
      cast(affected as decimal(7,0)) as "files successful"
   from summary
   where date(start_time)='2004-11-12' and
      activity='BACKUP' and
      entity like 'LN%'
   order by entity

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 11/18/2004
10:52:40:

> Hello All!
>
> I believe that I am getting the syntax of a select statement wrong for
> summarizing the backup information summary for all nodes that begin with
> ln* from 11/12/2004 - 11/13/2004.  Here is what I have so far:
>
> select entity as node_name, date(start_date) as date, cast(activity as
> varchar(10)) as activity, time(start_time) as start, time(end_time) as
end,
> cast(bytes/1000000) as decimal(6,0)) as megabytes, cast(affected as
> decimal(7,0)) as files successful from summary where date=11/12/2004 and
> activity='BACKUP' and node_name='LN*' order by node_name
>
> Would anyone happen to know what I am doing wrong?  I just can't seem to
> get this query to work.  Thank you in advance!
>
> ********************************
> 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>