Table of Contents
Connector/Python supports a C extension that interfaces with the MySQL C client
library. For queries that return large result sets, using the C
Extension can improve performance compared to a “pure
Python” implementation of the MySQL client/server protocol.
Section 8.1, “Application Development with the Connector/Python C Extension”, describes how
applications that use the mysql.connector
module
can use the C Extension. It is also possible to use the C Extension
directly, by importing the _mysql_connector
module rather than the mysql.connector
module.
See Section 8.2, “The _mysql_connector C Extension Module”. For information
about installing the C Extension, see
Chapter 4, Connector/Python Installation.
The C extension was added in version 2.1.1 and is enabled by
default as of 8.0.11. The use_pure
option
determines whether the Python or C version of this connector is
enabled and used.