Mysql Dump

By admin

I have a love/hate with this program. Here are so notes so I don't have to keep looking it up…

Creates all the tables with the data but don't add the “drop database” statements. Good for if you are going to get a dump so you can restart a replication that's died:

mysqldump -umyuser -pmypasswrd -h localhost –add-drop-table –no-create-db –quick –databases –extended-insert db1 db2 db3

Sometimes, you many want to do this in 2 stages

Dump structure only:
mysqldump -umyuser -pmypasswrd -h localhost –add-drop-table –no-data –no-create-db

Dump data:
mysqldump -umyuser -pmypasswrd -h localhost –quick –extended-insert –no-create-db –no-create-info

mysqldump -usps -p sps_development –quick –extended-insert –no-create-db –no-create-info



categoriaMysql commentoNo Comments dataJune 9th, 2007

About... admin

This author published 340 posts in this site.

Share

FacebookTwitterEmailWindows LiveTechnoratiDeliciousDiggStumbleponMyspaceLikedin

Leave a comment