ADSM-L

Re: Select statement question

2005-05-04 12:57:21
Subject: Re: Select statement question
From: Dave Zarnoch <zarnocd AT NATIONWIDEPROVIDENT DOT COM>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Wed, 4 May 2005 12:55:12 -0400
Curtis,

Thanks!

I made a little change, though....

where (end_time between '2005-05-01' and '2005-05-04')

DaveZ




                      Curtis Stewart
                      <Curtis.Stewart@L        To:       ADSM-L AT VM.MARIST 
DOT EDU
                      AWSON.COM>               cc:
                      Sent by: "ADSM:          Subject:  Re: [ADSM-L] Select 
statement question
                      Dist Stor
                      Manager"
                      <[email protected]
                      .EDU>


                      05/04/2005 12:10
                      PM
                      Please respond to
                      "ADSM: Dist Stor
                      Manager"






"Thought I had it....

How would I need to adjust the macro to include information between two
dates?"


Try this...

select
nodes.domain_name,summary.activity,sum(cast(summary.bytes/1024/1024/1024
as decimal(6,2)))
as GB from nodes, summary  where (end_time between current_timestamp - $1
hours and
current_timestamp - $2 hours) and (activity='BACKUP' or activity='RESTORE'
or activity='ARCHIVE' or
activity='RETRIEVE') and ((nodes.node_name=summary.entity)) group by
domain_name,summary.activity

$1 is the start time in hour past... like 72 for three days
$2 is the end time


curtis.stewart AT lawson DOT com

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