Skip to content

Instantly share code, notes, and snippets.

@lihanli
Created April 30, 2012 16:24
Show Gist options
  • Save lihanli/2559755 to your computer and use it in GitHub Desktop.
Save lihanli/2559755 to your computer and use it in GitHub Desktop.
drop all data in mysql database
mysqldump -u <USERNAME> -p<PASSWORD> --add-drop-table --no-data <DB_NAME> | grep ^DROP | mysql -u <USERNAME> -p<PASSWORD> <DB_NAME>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment