Home > AMP

Mysql 导入导出csv

导出csv

select * from test_info
into outfile ‘/tmp/test.csv’
fields terminated by ‘,’ optionally enclosed by ‘”‘ escaped by ‘”‘
lines terminated by ‘\n’;
导入csv

load data local infile ‘/tmp/test.csv’
into table test_info
CHARACTER SET utf8
fields terminated by ‘,’ optionally enclosed by ‘”‘ escaped by ‘”‘
lines terminated by ‘\n’;

请选择你看完该文章的感受:

0不错 0超赞 0无聊 0扯淡 0不解 0路过

随机文章:

纱窗坏了
纱窗坏了

房产证
房产证

夏至
夏至

IBM T42拆机
IBM T42拆机

坑爹的交换机
坑爹的交换机

终于找到密码了
终于找到密码了

发表评论