MySQL: How to dump single tables instead of a complete database

Posted . Visible to the public.

Sometimes you want to test migrations with production or staging data. Dumping single tables makes sense if a complete dump would be to big.

mysqldump -u deploy_user -p application_production table1 table2 table2 > table1_table2_table2.sql.dump

Hint: If a table has to many constraints, a complete dump could be more handy.


Further reading:

Last edit
Andreas Robecke
License
Source code in this card is licensed under the MIT License.
Posted by Emanuel to makandra dev (2016-09-02 11:30)