Redian新闻
>
How to load data into Mysql from txt file?
avatar
How to load data into Mysql from txt file?# Database - 数据库
j*k
1
I tried to load a text file into an empty table,with "load data local infile
"file.txt" into table tablename", got error 1148:
the used command is not allowed with is MySQL version
My version is 3.23.52 and the manual dose suggests using load data.
Anybody can help?
avatar
o*z
2
it's disabled by default for security reason
you need to invoke the client with --local-infile=1
mysql --help for more information

【在 j*****k 的大作中提到】
: I tried to load a text file into an empty table,with "load data local infile
: "file.txt" into table tablename", got error 1148:
: the used command is not allowed with is MySQL version
: My version is 3.23.52 and the manual dose suggests using load data.
: Anybody can help?

avatar
s*i
3

yes, loading local file is not enabled by default.
can upload to server first then use
load data infile

【在 o***z 的大作中提到】
: it's disabled by default for security reason
: you need to invoke the client with --local-infile=1
: mysql --help for more information

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。