En Fri, 19 Oct 2007 05:32:04 -0300, Dennis Lee Bieber  
<[EMAIL PROTECTED]> escribió:

> On Thu, 18 Oct 2007 13:40:53 -0700, Florian Lindner
> <[EMAIL PROTECTED]> declaimed the following in comp.lang.python:

>> That works! Thanks! But a weird error message for this solution...
>
>       Not really... The MySQLdb adapter converts all parameters to
> properly delimited STRINGS (I don't know of any SQL system that passes
> /binary/ numerics). But MySQLdb also uses Python % formatting to then

I'd say the opposite: only poorly implemented systems convert numeric  
arguments to text.
*Real* bound variables are passed as pointers. The SQL sentence can be  
prepared and re-used with different sets of values several times, without  
having to re-parse it again and again.
If the MySQLdb adapter actually converts and inserts the arguments itself  
into the supplied SQL sentence, generating a new string for each call,  
this advantage -and many others- are cancelled, defeating the purpose of  
bound variables.

-- 
Gabriel Genellina

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to