Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
0.9.52, 0.9.1
-
None
Description
Currently only paramstyle 'qmark' is supported. This makes it hard to migrate application which use the pyformat style (which is default in MySQLDB and MySQL Connector/C).
Suggestion: Additionally support the following paramstyles:
1. format
cursor.execute("SELECT a FROM b WHERE id=%s", ('foo',)) |
2. pyformat
cursor.execute("SELECT a FROM b WHERE id=%(name)s", {'name' : 'foo'})) |
mixing paramstyles shouldn't be allowed and should result in a parsing error.