Upstream changelog:
Added SQL Modes as constants, making it easier to use them (WL#6411) * Setting the SQL Modes meant that developers had to make sure the string passed to MySQL was correctly formatted and contains the correct modes. To make it easier, a new class constants.SQLMode containing all the SQL Modes was added: for example, constants.SQLMode.TRADITIONAL will return the string 'TRADITIONAL'. * Additonally, MySQLConnection.sql_mode property now accepts a sequence of SQL Modes. For example, to set 2 SQL Modes, you can do the following cnx.sql_mode = [SQLMode.REAL_AS_FLOAT, SQLMode.NO_ZERO_DATE]
Added descriptive error codes for both client and server errors (WL#6351) * The errorcode module contains client and server error codes which can be used instead of the error numbers. For example, errorcode.CR_CONNECTION_ERROR is 2002. * A new locales sub-package has been created in mysql.connector. This will provided localized content. The first support language is the default English and contains the client error messages: locales.eng.client_error. To retrieve a client error based on the error number or code (name) you can use the get_client_error() function importing it from locales: from mysql.connector.locales import get_client_error() * Error messages and error codes are automatically fetch from the latest development release of MySQL. The errorcode.py and all files in the locales package are generated. You can see the generation date and the version of MySQL which was used in those files.
Please log in to add feedback.
This update has been submitted for testing by remi.
This update is currently being pushed to the Fedora EPEL 6 testing updates repository.
This update has been pushed to testing
This update has reached 14 days in testing and can be pushed to stable now if the maintainer wishes
This update has been submitted for stable by remi.
This update is currently being pushed to the Fedora EPEL 6 stable updates repository.
This update has been pushed to stable