RE: Is there a performance advantage to using placeholders with Sybase?

"Wechsler, Steven" <[email protected]> Tue, 8 Jan 2008 09:41:56 -0500
Newsgroups gmane.comp.lang.perl.modules.dbi.sybase
Message-ID <9BFA664319211B4780C5F8A4FB060FF50121A1B4@LAZYTOWN.mtvn.ad.viacom.com>
Yes, I guess I should have stated that off the bat - I am using
FreeTDS...anyone know if it's been updated?
 
If not, although writing a stored proc beforehand isn't practical, what
I'm doing is simple enough that I could generate a stored proc on the
fly, use do() repeatedly and then drop it at the end. Presumably that
would be better than continual $dbh->do("insert table_x (select * from
table_y where ...)") - right?



Steve Wechsler | [email protected] 
Sybase/SQL Server/MySQL Database Administrator 
212-846-5683 

MTV Networks 

 


________________________________

From: [email protected] [mailto:[email protected]]
On Behalf Of [email protected]
Sent: Tuesday, January 08, 2008 6:10 AM
To: [email protected]
Subject: RE: Is there a performance advantage to using placeholders with
Sybase?



OpenClient can do array binding, though I've never used it. 

For execution of RPC (procs using placeholders) you must use the form
"exec procname ...". 

And lastly - if you are using FreeTDS then most of this (placeholders,
array binding, RPC execution) doesn't work anyway, because FreeTDS's
implementation of OpenClient isn't complete in this respect (or at least
wasn't last time I looked - I have to admit that I don't really look all
that often...) 

Michael