noirello
noirello

Reputation: 51

Python3 MySQL Drivers

Recently, I switched to Python 3 (3.1 on a FreeBSD system), and i would like to work with MySQL databases.

Could you recommend me a properly working MySQL driver for Python 3, or at least solve one of these problems? I would be very greatfull.

Upvotes: 2

Views: 1258

Answers (1)

noirello
noirello

Reputation: 51

The oursql documentation is a little tricky. :$ There is a list of Connection's parameters, but it doesn't contain the unix_socket parameter. If i set that and the the protocol parameter the whole thing is just work fine :)

If someone has trouble with inserting (get _statment charset AttributeError): https://bugs.launchpad.net/oursql/+bug/669184 change the lines in oursql.c with the code in the report, and rebuild it. (it will be fixed in 0.9.3)

Upvotes: 1

Related Questions