MySQL ERROR : The used command is not allowed with this MySQL version 解决办法


目的:向MySql数据库导入.txt文件,通过load命令来实现

 

输入如下命令,报错:

 

 

修改命令,依旧报错:

 

可能原因(from mysql reference manual):

If LOAD DATA LOCALis disabled, either in the server or the client, a client that attempts to issue such a statement receives the fol-lowing error message:

ERROR 1148: The used command is not allowed with this MySQL version
可见,出于安全考虑,默认是不允许从client host远程通过load data命令导数据的
 
解决办法:

登录MySql时,需用--local-infile[=1]显式指定参数

 

问题解决

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM