Difference between revisions of "Mysqldump selecting tables only"

From MyWiki
Jump to: navigation, search
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
 
<source lang="text">
 
<source lang="text">
 
With mysqldump command you can specify certain tables of your database you want to backup.
 
With mysqldump command you can specify certain tables of your database you want to backup.
For example, to back up only php_tutorials and asp_tutorials tables from the 'Tutorials' database accomplish the command below. Each table name has to be separated by space.
+
For example, to back up only php_tutorials and asp_tutorials tables from the 'Tutorials' database accomplish the command below.
 +
Each table name has to be separated by space.
 
$ mysqldump -u root -p Tutorials php_tutorials asp_tutorials > tut_backup.sql
 
$ mysqldump -u root -p Tutorials php_tutorials asp_tutorials > tut_backup.sql
 
</source>
 
</source>

Latest revision as of 11:20, 2 November 2015

With mysqldump command you can specify certain tables of your database you want to backup.
For example, to back up only php_tutorials and asp_tutorials tables from the 'Tutorials' database accomplish the command below.
Each table name has to be separated by space.
$ mysqldump -u root -p Tutorials php_tutorials asp_tutorials > tut_backup.sql