Please ignore this.

Robert <[EMAIL PROTECTED]> wrote:Hi list,
When I run this program it is not returning any value, I am not sure where I have 
problem in this code.
#!C:\perl\ActivePerl\Perl\bin\perl -w
use DBI;
use strict;
my $dbh = DBI->connect( 'dbi:Oracle:db1',
'test',
'test',
{
RaiseError => 1,
AutoCommit => 0
}
) || die "Database connection not made: $DBI::er
rstr";
#$dbh->trace(9);
my $sql = qq( select round((1-(phy.value / (cur.value + con.value)))*1
00,2) "% Ratio"
from v\$sysstat\ cur, v\$sysstat\ con, v\$sysstat\ phy
where cur.name = 'db block gets' and
con.name = 'consistent gets' and
phy.name = 'physical reads' );
my $sth = $dbh->prepare( $sql );
$sth->execute();
while( my $aref = $sth->fetchrow_arrayref ) {
if ( $aref->[0] > 90 )
{ print "Good\n" }
else
{ print "Buffer cache is running low" }
}
$dbh->disconnect();

Please let me know.




---------------------------------
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.




---------------------------------
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.

Reply via email to