This shows you the differences between two versions of the page.
howto_mysql [2012/03/09 10:43] |
howto_mysql [2012/03/09 10:43] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Howto dump the contents of a MySQL database for backup purposes. ====== | ||
+ | Have you ever found yourself in the situation that you had to migrate a database to another server, or that you had to set up a developing environment for a programmer ? | ||
+ | |||
+ | Well mysqldump is your friend - In one line you can make a backup of the contents, tables, basically eveything you need to " | ||
+ | |||
+ | The syntax is as follows: | ||
+ | |||
+ | mysqldump -u USERNAME -p DATABASENAME > DATABASENAME_FOR_BACKUP.sql | ||
+ | |||
+ | This will save the database in the directory where MYSQLDUMP program is residing, it ought to be possible to enter a path in the name. | ||
+ | |||
+ | This is normally done from within the CLI shell of the server. | ||
+ | |||
+ | Loads of other very handy MySQL tips can be found at the following url: http:// |