标签:closed mys rmi field 存在 scp mysq class sed
1、查询数据到CSV文件
select * from account into outfile ‘/root/account.csv‘ fields terminated by ‘,‘ enclosed by ‘"‘ lines terminated by ‘\r\n‘
注意:可通过终端方式查询或者服务器上连接数据查询所得。
2、将大文件数据(SQL)导入到服务器
scp -P 端口号 -i 私钥绝对路径地址 数据存放的绝对路径 root@IP:/tmp/
3、导入数据
load data local infile ‘/tmp/account.csv‘ into table account fields terminated by ‘,‘ enclosed by ‘"‘ lines terminated by ‘\r\n‘;
标签:closed mys rmi field 存在 scp mysq class sed
原文地址:https://www.cnblogs.com/dadonggg/p/10908380.html