mysql -u db_user -p db_name --xml -e "SELECT * FROM table_name" > table_name.xml--该片段来自于http://www.codesnippet.cn/detail/141120137176.html
来源: http://www.codesnippet.cn/detail/141120137176.html