抽取数据到数据库本地:
mysql> select * from test into outfile '/usr/mysql/out.txt' fields terminated by ',' enclosed by '"' lines termi
nated by '\r\n';
抽取某种表的数据到其他地方:
比如要抽取到win7系统里面,可以这样:
先在win7系统上使用mysql客户端登陆远程连接到数据库:
F:\workSoft\mysql-5.6.14-winx64\bin> mysql -uroot -h192.168.5.65 -p --default-character-set=utf8 -e "select * from usertrack.T_BZ_Client
ActionLog" > F:/out.txt