ADSM-L

Re: tsm select statement help

2003-12-30 13:55:38
Subject: Re: tsm select statement help
From: "Prather, Wanda" <Wanda.Prather AT JHUAPL DOT EDU>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Tue, 30 Dec 2003 13:55:06 -0500
Here ya go.


This joins the occupancy table and the filespaces table to give me a list of
the filespaces that haven't been backed up in over 60 days, and the SIZE
they occupy on the server in my pool named BAKUPTAPE.  the "oc" and "fs" are
made up shorthand tags that let you distinguish between the column in one
table and the column of the same name in a different table.  Not intuitively
obvious.
Good to make friends with your local DBA, they know how to do this (I
married mine, but that solution is probably too extreme for most people ;>)


select current_date,oc.node_name, oc.filespace_name, physical_mb as mbytes ,
stgpool_name,  -
   date(fs.backup_start) as bkup_date from occupancy oc, filespaces fs -
   where oc.node_name=fs.node_name and -
   oc.filespace_name=fs.filespace_name   and -
   stgpool_name='BACKUPTAPE' and    -
   cast((current_timestamp-backup_start)days as integer)>=60 -
   order by stgpool_name, oc.node_name, oc.filespace_name




-----Original Message-----
From: Justin Bleistein [mailto:justin.bleistein AT SUNGARD DOT COM]
Sent: Tuesday, December 30, 2003 12:44 PM
To: ADSM-L AT VM.MARIST DOT EDU
Subject: tsm select statement help


Does anyone have an sql syntax/statement example on how to join two sql
tables in adsm/tsm?
I have two tables in that adsm schema which both contain info that the
other doesn't respectively.
So I want to join them to get the desired results. I'm looking at Oracle
examples on the web none
really good. Any assistance would be appreciated. I know I could figure it
out but if someone could
save me trial and error time. I would really appreciate it..
Thanks in advance.

--Justin Richard Bleistein
Unix/TSM Systems Administrator

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