sql 101

  • From: "David" <thump@xxxxxxxxxxxxxxxx>
  • To: oracle-l@xxxxxxxxxxxxx
  • Date: Thu, 12 Aug 2004 16:35:13 -0700 (PDT)

I don't know if I'm just tired or inept, but I know this is a simple issue
and I have not been able to whip out a solution just yet.
ANy help is appreciated.

I'm trying to convert this script to work in a 9i db that utilizes the
parameter db_cache_size instead of db_block_buffers:

SELECT obj object, COUNT(1) buffers, (COUNT(1)/totsize) * 100 pct_cache
FROM x$bh, (SELECT value totsize FROM v$parameter
WHERE name = 'db_block_buffers')
WHERE tch = 1
OR (tch = 0 AND lru_flag < 8)
GROUP BY obj, totsize
HAVING (COUNT(1)/totsize) * 100 > 5;

I'm thinking divide db_cache_size by db_block_size from v$parameter but
the sql syntax has me a bit perplexed.  I'm blaming maybe lack of sleep
and sticking to it.

Thanks in advance for any assistance.
-- 
..
David

----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
--
Archives are at //www.freelists.org/archives/oracle-l/
FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------

Other related posts:

  • » sql 101