Created
April 18, 2015 21:19
-
-
Save macna/3a97a692e35da91b8ed2 to your computer and use it in GitHub Desktop.
A script for dumping a MySQL database to flat file, including a time/date stamp in the file name.
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
mysqldump <dbname> -uroot --skip-triggers > "D:\<your>\<folder>\<dbname>%time:~0,2%%time:~3,2%%time:~6,2%_%date:~-10,2%%date:~-7,2%%date:~-4,4%.sql" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment