On Thu, Oct 14, 1999 at 05:53:15PM -0700, Perrin Harkins wrote:
> On Thu, 14 Oct 1999, Jeffrey Baker wrote:
> > Zero optimization: 41.67 requests/second
> > Stage 1 (persistent connections): 140.17 requests/second
> > Stage 2 (bound parameters): 139.20 requests/second
> > Stage 3 (persistent statement handles): 251.13 requests/second
> 
> I know you said you don't like it because it has extra overhead, but would
> you mind trying stage 3 with prepare_cached rather than your custom
> solution with globals?  For some applications with lots of SQL statements,
> the prepare_cached appraoch is just much more manageable.
> 
> > It is interesting that the Stage 2 optimization didn't gain anything
> > over Stage 1.
> 
> I think Oracle 8 is doing some magic by parsing your SQL and matching it
> up to previous statements, whether you use bind variables or not.  It may
> matter more on other databases.
> 
> - Perrin

You may also find that the use of bind variables become more and more
effecient when used in complex, multi-table joins.

Tim.

-- 

 ____________________________________________   _                       _ 
                           Timothy E. Peoples  |_| C o l l e c t i v e |_|
                            Senior Consultant   |_    technologies     _| 
                             [EMAIL PROTECTED]     []                 []   
                                                    a pencom company

                            There is no spoon.

Reply via email to