测试mysql的select into outfile时,报错“
The MySQL server is running with the --secure-file-priv
”

查询了下,通过mysql命令查看secure-file-priv项:
show variables like '%secure%';
如果secure-file-priv为空,则可任意位置导出导入
如果secure-file-priv为null,则不可导出导入
如果secure-file-priv为指定位置,则指定位置导出
处理:
在mysql目录下找到my.ini,添加:
secure_file_priv=
,然后重启mysql即可

相关文章
我的微信
微信扫一扫


评论