ADSM-L

Re: query performance problem

2004-02-19 10:45:47
Subject: Re: query performance problem
From: Thomas Denier <Thomas.Denier AT MAIL.TJU DOT EDU>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Thu, 19 Feb 2004 10:44:31 -0500
> I'm trying to select tapes where has reclamation percentage and utilization
perc
> entage summ of less then 5. this is useful for reclamation as these tapes
usless
>  in library. My problem is my select return result after about 3-7minutes.
Can a
> nyone help to optimize this select or any tips
> how to better use inner select.
>
> TSMserver version:5.1
> Database size: 100GB
> hardware: RS/6000 H80
> RAM:2GB
>
>
> SELECT="select
volume_name,stgpool_name,pct_utilized,pct_utilized+pct_reclaim as
>  summa
> from volumes
> where volume_name in (select volume_name from media where state like
'MOUNTABLEI
> NLIB')
> and stgpool_name like 'BACK1_3590'
> and READ_ERRORS = 0
> and WRITE_ERRORS = 0
> and ERROR_STATE like 'No'
> and STATUS not like 'EMPTY'
> and ACCESS not like 'UNAVAILABLE'
> and pct_utilized+pct_reclaim < 5
> order by pct_utilized"
>
As far as I can tell, the 'like' and 'not like' operations could
just as well be equality and inequality comparisons. The wild
card capabilities of 'like' might have some overhead even when
they are not really used.

I don't get the underlying goal. As far as I can tell, the script
will find pending volumes and filling volumes with small amounts of
data. I don't see why you would want to remove the filling volumes
from the library. I can imagine circumstances where one would want
to remove pending volumes, but those volumes could be found with a
significantly simpler select.

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