Created
November 30, 2024 11:17
-
-
Save romiras/48b5660c00980256bf96b6b47c0ac872 to your computer and use it in GitHub Desktop.
Extract a single table from MySQL DB dump in Linux
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
gunzip < dump.sql.gz | sed -n -e '/DROP TABLE.*`my_table`/,/UNLOCK TABLES/p' > my_table.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment