The MySQL server is running with the --secure-file-priv option so it cannot execute this statement
1、如出现上述问题,利用:show variables like '%secure%';
mysql> load data infile 'C:\Users\lenovo\Desktop\201805.csv'
-> into table pay_tab222 character set gb2312
-> fields terminated by ',' optionally enclosed by '"' escaped by '"'
-> lines terminated by '\r\n';
2、如果value值为NULL,修改my.ini,注意:如果是解压版本mysql-5.6.38-winx64,文件为my-default.ini,将其改为my.ini就好;
然后在文件中加入,重启mysql或者重启电脑;
#Secure File Priv.
secure-file-priv=C:\Users\lenovo\Desktop