[ python-Bugs-1010253 ] Fix DB-API parameter substitution

noreply at pgfoundry.org noreply at pgfoundry.org
Sun Feb 3 00:50:38 UTC 2008


Bugs item #1010253, was opened at 2008-01-27 14:49
You can respond by visiting: 
http://pgfoundry.org/tracker/?func=detail&atid=442&aid=1010253&group_id=1000094

Category: fe/proboscis
Group: None
Status: Open
Resolution: None
Priority: 3
Submitted By: James Pye (jwp)
Assigned to: James Pye (jwp)
Summary: Fix DB-API parameter substitution

Initial Comment:
Currently the DB-API layer stupidly substitutes '?' for $n. This can cause issues if a question-mark is placed in a quoted section.

Additionally, switch the paramstyle to named parameters to sync up with psycopg2.

This depends on the strings module being added to pg_foundation.

----------------------------------------------------------------------

>Comment By: James Pye (jwp)
Date: 2008-02-02 17:50

Message:
strings module has been added to pg_foundation-1.0dev(HEAD).
Small matter of code.

An alteration, however. Make the paramstyle consistent with psycopg2's. Considering that psyco is undoubtably the most popular driver available, try to make the dbapi2 module compatible with it.

----------------------------------------------------------------------

You can respond by visiting: 
http://pgfoundry.org/tracker/?func=detail&atid=442&aid=1010253&group_id=1000094


More information about the Python-general mailing list