operation with unicode parameters. SQLAlchemy now passes both
the statement as well as the bound parameters as unicode
objects, as PyMySQL generally uses string interpolation
internally to produce the final statement, and in the case of
executemany does the "encode" step only on the final statement.
fixes #3337
.. changelog::
:version: 0.9.10
+ .. change::
+ :tags: bug, mysql, pymysql
+ :tickets: 3337
+ :versions: 1.0.0b4
+
+ Fixed unicode support for PyMySQL when using an "executemany"
+ operation with unicode parameters. SQLAlchemy now passes both
+ the statement as well as the bound parameters as unicode
+ objects, as PyMySQL generally uses string interpolation
+ internally to produce the final statement, and in the case of
+ executemany does the "encode" step only on the final statement.
+
.. change::
:tags: bug, py3k, mysql
:tickets: 3333
driver = 'pymysql'
description_encoding = None
+
+ # generally, these two values should be both True
+ # or both False. PyMySQL unicode tests pass all the way back
+ # to 0.4 either way. See [ticket:3337]
supports_unicode_statements = True
+ supports_unicode_binds = True
@classmethod
def dbapi(cls):
('postgresql', 'pypostgresql'),
('postgresql', 'pg8000'),
('postgresql', 'zxjdbc'),
+ ('mysql', 'pymysql'),
('mysql', 'oursql'),
('mysql', 'zxjdbc'),
('mysql', 'mysqlconnector'),