Abulifia,
Something like : "where cast((current_timestamp- end_time )hours as
decimal) <= 24" should do the trick ...
However, if I remember properly, TDP's activity is not reported properly
in summary table ... Double check before trusting your query !
Cheers.
Arnaud
************************************************************************
******
Panalpina Management Ltd., Basle, Switzerland,
CIT Department Viadukstrasse 42, P.O. Box 4002 Basel/CH
Phone: +41 (61) 226 11 11, FAX: +41 (61) 226 17 01
Direct: +41 (61) 226 19 78
e-mail: arnaud.brion AT panalpina DOT com
************************************************************************
******
-----Original Message-----
From: ADSM: Dist Stor Manager [mailto:ADSM-L AT VM.MARIST DOT EDU] On Behalf Of
Ronald Le Large
Sent: Wednesday, 14 February, 2007 14:05
To: ADSM-L AT VM.MARIST DOT EDU
Subject: SQL date convert
Hi everybody,
The last time when I posted a question I received a few very useful
and quick replies. Thx for that. Hopefully this question is also easy
for a few of you to answer.
Case:
A client want's to know how big the daily backup is for a Lotus client
backedp up via TDP.
I can embed a "query actlog begind=-1 node=[nodename] msg=4991 " in a
script but the output is useless (even with grep) because TDP reports a
summary for every *.nfs its backing up and I am only interested in the
total bytes transferred. (which is also reported with msg 4991 at the
end of the log).
The alternative (which has my preference ) is an sql query:
select START_TIME,ACTIVITY,ENTITY from summary where
ENTITY='[nodename]' and ACTIVITY='BACKUP'
but I struggle with the date.
The format TSM is using in its table is
2007-01-15 21:08:34.000000
I am only interested in the backupsize of last night so I use "
START_TIME='2007-02-14%' but that is obviously not the correct syntax.
Does anyone of you know how I must convert the date ? Or is there a
possibility to use something like "today-1" like you use with a q
actlog.
Your advise would be highly appreciated.
Thx in advance,
Abulifia
---------------------------------
New Yahoo! Mail is the ultimate force in competitive emailing. Find out
more at the Yahoo! Mail Championships. Plus: play games and win prizes.
|