Re: execute multiple quries at one shot with DBI/DBD?
Posted by:
web reg
Date: September 06, 2007 08:12AM
Hi Dave,
Thanks for the reply.
I've tried both. Using something like "(X < 2 AND Y > 3) OR (X < 4 AND Y > 5)" actually cost 10x as much time as running individual queries with parameter binding as the following:
$sth->prepare("select name from tableA where X <? and Y >?");
foreach $xy (@xys) {
$sth->execute($xy->[0], $xy->[1]);
... <collecting results> ...
}
Using UNION ALL cost about the same time as using parameter binding shown above.
Since the db querying part is the bottleneck of my program, I really want to make it more efficient.
Subject
Written By
Posted
September 05, 2007 07:55PM
September 06, 2007 06:07AM
Re: execute multiple quries at one shot with DBI/DBD?
September 06, 2007 08:12AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.