[DB-SIG] API suggestion: expose 'quote' method

Jekabs Andrushaitis jekabs.andrusaitis at tietoenator.com
Thu Jun 5 21:12:24 EDT 2003

Usually DB itself does convert the query arguments to the correct types
1) the client passes sql statement with arguments in whatever data type 
	it wants;
2) database engine parses the sql statement, decides on query execution 
	path and what types data should be in;
3) database engine converts the arguments to correct data types and 
	executes the statement and returns results.

So what normally Python database adapter does is - converting the Python
data types to the underlaying db engine data types, while letting the
db engine do the conversion from one type to another.

Of course there might be exceptions, like db engines which do not use
"bind variables" at all, and all the parameters have to be passed through
the sql statement itself.

Jekabs Andrushaitis
Senior system analyst
TietoEnator Financial Solutions
41 Lacplesa Str.
Riga, LV-1011, Latvia
Tel: +371 7286660
Fax: +371 7243000
E-mail: jekabs.andrusaitis at tietoenator.com

More information about the DB-SIG mailing list