Created
November 8, 2014 12:02
-
-
Save simonswine/faad01dd4ec6b8577be6 to your computer and use it in GitHub Desktop.
Shell oneliner drop all tables from xx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql -e "SELECT concat('DROP TABLE IF EXISTS ', table_name, ';') FROM information_schema.tables WHERE table_schema = 'xx';" | tail -n +2 | mysql xx |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment