mysql的幾種數據導入導出總結

1、按照某個表的某些字段選擇性導出
SELECT mobile,password FROM t_yonghu INTO OUTFILE ‘/usr/local/sys_user_yun.csv’ FIELDS TERMINATED BY ‘,’;
按照逗號的分隔符進行字段分割

2、使用mysqldump導出某個表的整個表結構和數據
mysqldump -uroot -pwukong123 wo_ips t_news_info > /usr/local/t_news_info.sql

You May Also Like