MySQL连接器/Python发布说明
表的内容
- 10.1 mysql。连接器模块
- 10.2连接。MySQLConnection类
-
- 10.2.1 connection.MySQLConnection()构造函数
- 10.2.2 MySQLConnection.close()方法
- 10.2.3 MySQLConnection.commit()方法
- 10.2.4 MySQLConnection.config()方法
- 10.2.5 MySQLConnection.connect()方法
- 10.2.6 MySQLConnection.cursor()方法
- 10.2.7 MySQLConnection.cmd_change_user()方法
- 10.2.8 MySQLConnection.cmd_debug()方法
- 10.2.9 MySQLConnection.cmd_init_db()方法
- 10.2.10 MySQLConnection.cmd_ping()方法
- 10.2.11 MySQLConnection.cmd_process_info()方法
- 10.2.12 MySQLConnection.cmd_process_kill()方法
- 10.2.13 MySQLConnection.cmd_query()方法
- 10.2.14 MySQLConnection.cmd_query_iter()方法
- 10.2.15 MySQLConnection.cmd_quit()方法
- 10.2.16 MySQLConnection.cmd_refresh()方法
- 10.2.17 MySQLConnection.cmd_reset_connection()方法
- 10.2.18 MySQLConnection.cmd_shutdown()方法
- 10.2.19 MySQLConnection.cmd_statistics()方法
- 10.2.20 MySQLConnection.disconnect()方法
- 10.2.21 MySQLConnection.get_row()方法
- 10.2.22 MySQLConnection.get_rows()方法
- 10.2.23 MySQLConnection.get_server_info()方法
- 10.2.24 MySQLConnection.get_server_version()方法
- 10.2.25 MySQLConnection.is_connected()方法
- 10.2.26 MySQLConnection.isset_client_flag()方法
- 10.2.27 MySQLConnection.ping()方法
- 10.2.28 MySQLConnection.reconnect()方法
- 10.2.29 MySQLConnection.reset_session()方法
- 10.2.30 MySQLConnection.rollback()方法
- 10.2.31 MySQLConnection.set_charset_collation()方法
- 10.2.32 MySQLConnection.set_client_flags()方法
- 10.2.33 MySQLConnection.shutdown()方法
- 10.2.34 MySQLConnection.start_transaction()方法
- 10.2.35 MySQLConnection。autocommit属性
- 10.2.36 MySQLConnection。unread_results财产
- 10.2.37 MySQLConnection。can_consume_results财产
- 10.2.38 MySQLConnection。字符集属性
- 10.2.39 MySQLConnection。排序属性
- 10.2.40 MySQLConnection。connection_id财产
- 10.2.41 MySQLConnection。数据库属性
- 10.2.42 MySQLConnection。get_warnings财产
- 10.2.43 MySQLConnection。in_transaction财产
- 10.2.44 MySQLConnection。raise_on_warnings财产
- 10.2.45 MySQLConnection。server_host财产
- 10.2.46 MySQLConnection。server_port财产
- 10.2.47 MySQLConnection。sql_mode财产
- 10.2.48 MySQLConnection。time_zone财产
- 10.2.49 MySQLConnection。unix_socket财产
- 10.2.50 MySQLConnection。用户属性
- 10.3池。MySQLConnectionPool类
- 10.4池。PooledMySQLConnection类
- 10.5游标。MySQLCursorClass
-
- 10.5.1游标。MySQLCursorConstructor
- 10.5.2 MySQLCursor.callproc()方法
- 10.5.3 MySQLCursor.close()方法
- 10.5.4 MySQLCursor.execute()方法
- 10.5.5 MySQLCursor.executemany()方法
- 10.5.6 MySQLCursor.fetchall()方法
- 10.5.7 MySQLCursor.fetchmany()方法
- 10.5.8 MySQLCursor.fetchone()方法
- 10.5.9 MySQLCursor.fetchwarnings()方法
- 10.5.10 MySQLCursor.stored_results()方法
- 10.5.11 MySQLCursor。column_names财产
- 10.5.12 MySQLCursor.description财产
- 10.5.13 MySQLCursor。lastrowid财产
- 10.5.14 MySQLCursor。rowcount财产
- 10.5.15 MySQLCursor。声明属性
- 10.5.16 MySQLCursor。with_rows财产
- 10.6子类指针。MySQLCursor
- 10.7常数。ClientFlag类
- 10.8常数。FieldType类
- 10.9常数。SQLMode类
- 10.10常数。CharacterSet类
- 10.11常数。RefreshOption类
- 10.12错误和异常
-
- 10.12.1 errorcode模块
- 10.12.2错误。错误异常
- 10.12.3错误。DataError例外
- 10.12.4错误。DatabaseError例外
- 10.12.5错误。IntegrityError例外
- 10.12.6错误。InterfaceError例外
- 10.12.7错误。InternalError例外
- 10.12.8错误。NotSupportedError例外
- 10.12.9错误。OperationalError例外
- 10.12.10错误。PoolError例外
- 10.12.11错误。ProgrammingError例外
- 10.12.12错误。警告例外
- 10.12.13 errors.custom_error_exception()函数
本章包含连接器/Python的公共API参考。示例应该考虑适用于Python 2.7、Python 3.1及更高版本。它们也可能适用于较旧的版本(如Python 2.4),除非它们使用较新的Python版本中引入的特性。的异常处理作为
关键字是在Python 2.6中引入的,在Python 2.4中无效。
请注意
Python 2.7支持在Connector/Python 8.0.24中被移除。
下面的概述显示了mysql.connector
用它的模块打包。目前,只记录了对最终用户最有用的模块、类和方法。
mysql.connectorerrorcode errors connection constants conversion cursor dbapi locales eng client_error protocol utils