mysql - How can I set the options for a MySQL Connector/Python X DevAPI connection?
问题描述
How can I set the "--local-infile[={0|1}]" option for a mysqlx connection?
My python code looks the following:
import mysqlx
# Connect to server on localhost
session = mysqlx.get_session({
'host': 'localhost',
'port': 33060,
'user': 'root',
'password': '12345678',
})
解决方案
Currently, there is no LOAD DATA
support in the X Protocol, which means that X DevAPI clients don't provide such an option. You'll need a Classic Protocol connection for that.
Disclaimer: I'm the lead developer of the MySQL X DevAPI Connector for Node.js
推荐阅读
- python - 用没有直方图的地毯复制 distplot
- python - Python - 如何在写入 MS Word 时使段落变为粗体和红色?
- freemarker - 如何在 Freemaker 代码中使用“包含”?
- r - 多断点分析结构,每个断点的意义
- android - Android CoroutineScope 完成后自动取消
- mysql - 如何在mysql触发器中引发之前提交事务?
- c# - C# 中整数或小数(10,2)的正则表达式
- sql-server - 如何在 SQL Server 中将其转换为日期格式
- netsuite - NetSuite 使用 SuiteScript 如何获取当前登录的用户本地信息,例如。日期格式?
- jquery - Kendo for jQuery:将数据加载到图表而不使用 k-rebind