# 常用姿势

# 1.将数据导出到文本

mysql -h10.10.10.10 -uroot -p123456 -P3306 -Ne "select * from table_name into outfile '/tmp/table_name_result.txt' "
mysql -h10.10.10.10 -uroot -p123456 -P3306 -N < run.sql > /tmp/table_name_result.txt
1
2

# 2.插入或更新数据

insert into class_refund_order_detail (refundds,classid) VALUES (%s,%s) on duplicate key update refundds=values(refundds),classid=values(classid)
1
更新时间: 9/2/2021, 6:47:47 PM