Paul Appleby wrote:
Try measuring the time it takes to connect with SqlPlus by using
You mean DBI? (I already sent the result for sqlplus.)
"Time::HiRes" with the variables $time1 and $time2 both set to gettimeofday() and the the length of time set to $time2-$time1, as follows:
$time1=gettimeofday(); your code runs here; $time2=gettimeofday(); print $time2-$time1;
O.k., for the record:
Platform:
x86 1193 MHz, 500 MB Mem W2K Workstation Oracle 8.1.7.2.1 Perl 5.6.1.
CGI script:
use DBI(); use Time::HiRes();
print "Content-type: text/html\n\n<pre>";
$time1 = Time::HiRes::gettimeofday;
my $dbh = DBI->connect;
print Time::HiRes::gettimeofday - $time1, "\n";
my $sth = $dbh->prepare('select * from dual');
$sth->execute;
$sth->dump_results;Result:
0.09375 'X' 1 rows
Both - Perl/DBI and sqlplus - connect in about 1/10 sec. Could you run the sqlplus test, please? I guess we can exclude Perl/DBI from causing your delay. It may help if you say more about your platform/environment.
Steffen
