Last week we released MySQL Connector/Python v1.0.10. Release notes can be found in the MySQL Developver Zone.
A notable fix in Connector/Python v1.0.10 which might interest a few users is adding support for LOAD DATA LOCAL INFILE. It allows you to import CSV using a simple SQL statement.
Please use the MySQL Bugs website to report any problem.
Some useful links:
- Documentation: http://dev.mysql.com/doc/connector-python/en/index.html
- Release Notes: http://dev.mysql.com/doc/relnotes/connector-python/en/index.html
- Downloads: http://dev.mysql.com/downloads/connector/python/#downloads
- Feedback: http://bugs.mysql.com
- Forum: http://forums.mysql.com/list.php?50
Enjoy!
Comments
Hello Sir,
I am trying to test my MySQL Connector/Python 1.0.10 on my windows client PC connecting to my ubuntu linux desktop PC with MySQL ver. 5.5.1 installed. I am not trying to any fancy codes yet. I cannot get past the initial testing of my connection. I am pretty sure my access rights are OK, because I am able to connnect to the MySQL server command line with username. However, when I try to connect using the sample python code found on the MySQL website, I am getting these errors which I don’t understand. Here is what I am getting:
[edited] mysql.connector.errors.DatabaseError: 1130: b”Host ‘zzyzx.local’ is not allowed to connect to this MySQL server” >>>
Any help would be greatly appreciated.
Regards, Bob Tam
One gotcha for LOAD DATA LOCAL INFILE is that you need to enable ClientFlag.LOCAL_FILE:
import mysql.connector from mysql.connector.constants import ClientFlag flags = [ClientFlag.LOCAL_FILES]
If you don’t you will get an error like:
mysql.connector.errors.ProgrammingError: 1148 (42000): The used command is not allowed with this MySQL version