Created
January 18, 2018 23:22
-
-
Save fititnt/dfe99a0f0db5f84dcc403012c8ff6392 to your computer and use it in GitHub Desktop.
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
--------- RUN QUERY 1 --------- | |
-- Run this query to get SQL to drop each table | |
SELECT concat('DROP TABLE IF EXISTS ', table_name, ';') | |
FROM information_schema.tables | |
WHERE table_schema = 'database_name'; | |
-- Copy results | |
--------- RUN QUERY 2 --------- | |
SET FOREIGN_KEY_CHECKS = 2; | |
--- PASTE HERE RESULTS | |
SET FOREIGN_KEY_CHECKS = 1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment