Hi, According to sqlalchemy/dialects/mysql/base.py, MySQL v3.23 should be supported in some form. However, with SA 0.6.1 and MySQL 3.23.58, I get the following error:
>>> import sqlalchemy as sa >>> e = sa.create_engine('mysql://user:passw...@host') >>> e.execute('select "Hello World"') Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/engine/base.py", line 1714, in execute connection = self.contextual_connect(close_with_result=True) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/engine/base.py", line 1742, in contextual_connect self.pool.connect(), File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/pool.py", line 157, in connect return _ConnectionFairy(self).checkout() File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/pool.py", line 321, in __init__ rec = self._connection_record = pool.get() File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/pool.py", line 176, in get return self.do_get() File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/pool.py", line 670, in do_get con = self.create_connection() File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/pool.py", line 137, in create_connection return _ConnectionRecord(self) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/pool.py", line 217, in __init__ l.first_connect(self.connection, self) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/engine/strategies.py", line 145, in first_connect dialect.initialize(c) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/dialects/mysql/base.py", line 1755, in initialize default.DefaultDialect.initialize(self, connection) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/engine/default.py", line 138, in initialize self.returns_unicode_strings = self._check_unicode_returns(connection) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/engine/default.py", line 183, in _check_unicode_returns unicode_for_varchar = check_unicode(sqltypes.VARCHAR(60)) File "/ve/sa6/lib/python2.5/site-packages/sqlalchemy/engine/default.py", line 173, in check_unicode ]).compile(dialect=self) File "/ve/sa6/lib/python2.5/site-packages/MySQL_python-1.2.2-py2.5-linux-i686 .egg/MySQLdb/cursors.py", line 166, in execute self.errorhandler(self, exc, value) File "/ve/sa6/lib/python2.5/site-packages/MySQL_python-1.2.2-py2.5-linux-i686 .egg/MySQLdb/connections.py", line 35, in defaulterrorhandler raise errorclass, errorvalue _mysql_exceptions.ProgrammingError: (1064, "You have an error in your SQL syntax near '('test unicode returns' AS CHAR(60)) AS anon_1' at line 1") According to http://dev.mysql.com/doc/refman/4.1/en/cast-functions.html, the CAST function was added in 4.0.2. Is there any way that I can avoid this error? Perhaps with some engine or dialect option that configures the returns_unicode_strings attribute without running the test? Thanks a lot, Simon -- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalch...@googlegroups.com. To unsubscribe from this group, send email to sqlalchemy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en.