Thanks that worked for what I needed I just have to adjust the output that
needs sent to group.
Thanks again I am not use to putting two selects in one script but its
good.
Justin
Tomas Hrouda <throuda AT HTD DOT CZ>@VM.MARIST.EDU> on 08/30/2004 10:28:57 AM
Please respond to "ADSM: Dist Stor Manager" <ADSM-L AT VM.MARIST DOT EDU>
Sent by: "ADSM: Dist Stor Manager" <ADSM-L AT VM.MARIST DOT EDU>
To: ADSM-L AT VM.MARIST DOT EDU
cc:
Subject: Re: Data Backed up in last 24 hours by TSM Server Bremen
Hi Justin,
I think you cannot do it by one select, I mean table you posted with
summary
at the end. But you can do script with two selects, first that you posted,
second like that:
select cast(sum(bytes)/1024/1024 as decimal(9,0)) as MB_SUMM from summary
where (activity='BACKUP' or activity='ARCHIVE') and
cast((current_timestamp-end_time)hours as decimal)<24
Regards
Tomas
-----Original Message-----
From: ADSM: Dist Stor Manager [mailto:ADSM-L AT VM.MARIST DOT EDU]On Behalf Of
Justin Case
Sent: Monday, August 30, 2004 3:19 PM
To: ADSM-L AT VM.MARIST DOT EDU
Subject: Data Backed up in last 24 hours by TSM Server Bremen
Have a question on a select statement liste below..
How can I get a Total MB of all the backups in a column named Total ?
Thanks
Justin
---------------------- Forwarded by Justin Case/OIT/Univ/Duke on 08/30/2004
09:17 AM ---------------------------
"root@bremen" <root on 08/30/2004 08:05:00 AM
To: oit-ops AT bremen.oit.duke DOT edu
cc:
Subject: Data Backed up in last 24 hours by TSM Server Bremen
ANS8000I Server command: 'select entity as "Node
" , cast( sum(bytes)/1024/1024 as decimal(9,0) ) as MB
from summary where (activity='BACKUP' or activity='ARCHIVE') and
cast((current_timestamp-end_time)hours as decimal)<24 group by entity ORDER
by MB desc'
Node MB
--------------------------------- -----------
BREMEN_BCV 596719
PRDB00_ORACLE_BWP 60896
BREMEN 17812
PRDN00 7009
PRDB00 3973
CHIMERA_ORACLE_SPSDS 3368
THING_ORACLE_TECPRD 3115
GERYON_ORACLE_OEMPRD 3072
BLITZEN_ORACLE_SPSPRD 2373
GERYON_ORACLE_PCDPRD 2365
BLITZEN_ORACLE_STARPRD 1979
GERYON_ORACLE_RMANPRD 1538
CHIMERA_ORACLE_CGXPRD 1296
BLITZEN_ORACLE_ADGPRD 867
BESS 776
CHIMERA_ORACLE_EBPPPRD 565
GERYON_ORACLE_CSHPRD 544
GERYON_ORACLE_HYPPRD 530
THING 526
KRAKEN_ORACLE_IMSPRD 374
GERYON_ORACLE_FMPRD 356
CHIMERA_ORACLE_SPSTRN 345
GERYON 257
KRAKEN 252
GERYON_ORACLE_DIDPR2 192
GERYON_ORACLE_TSHPRD 187
TYPHON 184
CHIMERA_ORACLE_DOPSPRD 180
BLITZEN 168
CHIMERA 150
PEBBLES 149
GERYON_ORACLE_MP2PRD 125
CHIMERA_ORACLE_IMGPRD 115
GERYON_ORACLE_RMTPRD 108
PRDAS02 106
PRDAS03 63
PRDAS04 54
PRDAS05 54
PRDAS01 53
KRAKEN_ORACLE_UPPPRD 21
PRDN00_EDI 0
|