Created
November 28, 2013 03:16
-
-
Save kfitfk/7686780 to your computer and use it in GitHub Desktop.
Empty a mysql table
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
CREATE TABLE cloned LIKE the_table_to_drop; | |
RENAME TABLE the_table_to_drop TO drop_me, cloned TO the_table_to_drop; | |
DROP TABLE drop_me; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment