ADSM-L

Re: [ADSM-L] issue with sql syntax in TSM database

2010-03-16 16:39:21
Subject: Re: [ADSM-L] issue with sql syntax in TSM database
From: Bob Levad <blevad AT WINNEBAGOIND DOT COM>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Tue, 16 Mar 2010 15:38:52 -0500
We do multiple queries, activity for today, today-1, today-2, etc.

-----Original Message-----
From: ADSM: Dist Stor Manager [mailto:ADSM-L AT VM.MARIST DOT EDU] On Behalf Of
yoda woya
Sent: Tuesday, March 16, 2010 2:41 PM
To: ADSM-L AT VM.MARIST DOT EDU
Subject: Re: [ADSM-L] issue with sql syntax in TSM database

any workarounds if need to group them by the date only portion of the
timestamp.

On Tue, Mar 16, 2010 at 2:02 PM, Grigori Solonovitch <G.Solonovitch AT bkme DOT 
com
> wrote:

> You should not use function date in "group by". So try:
> select start_time,  sum(bytes)
>        from
>        summary
>                where
>                ACTIVITY in ('BACKUP','RESTORE')
>                group by start_time
>
>
> ________________________________________
> From: ADSM: Dist Stor Manager [ADSM-L AT VM.MARIST DOT EDU] On Behalf Of yoda
> woya [yodawoya AT GMAIL DOT COM]
> Sent: Tuesday, March 16, 2010 8:15 PM
> To: ADSM-L AT VM.MARIST DOT EDU
> Subject: [ADSM-L] issue with sql syntax in TSM database
>
> I am trying to run this sql and cannot get a result
>
> select date(start_time),  sum(bytes)
>
>        from
>        summary
>
>                where
>                ACTIVITY = 'BACKUP'
>                or ACTIVITY = 'RESTORE'
>
>                group by date(start_time)
>
>
> any reasons why??
>
> Please consider the environment before printing this Email.
>
> "This email message and any attachments transmitted with it may
> contain confidential and proprietary information, intended only for
> the named recipient(s). If you have received this message in error, or
> if you are not the named recipient(s), please delete this email after
> notifying the sender immediately. BKME cannot guarantee the integrity
> of this communication and accepts no liability for any damage caused
> by this email or its attachments due to viruses, any other defects,
> interception or unauthorized modification. The information, views,
> opinions and comments of this message are those of the individual and not
necessarily endorsed by BKME."
>

This electronic transmission and any documents accompanying this electronic 
transmission contain confidential information belonging to the sender.  This 
information may be legally privileged.  The information is intended only for 
the use of the individual or entity named above.  If you are not the intended 
recipient, you are hereby notified that any disclosure, copying, distribution, 
or the taking of any action in reliance on or regarding the contents of this 
electronically transmitted information is strictly prohibited.