Created
March 29, 2017 14:31
-
-
Save amccarty/c5e5a14e6b45be4279f2c525904f569d to your computer and use it in GitHub Desktop.
Prepend to a sql file before importing via command line
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
sed -i '1s;^;SET\ FOREIGN_KEY_CHECKS\ =\ 0\;\nSET\ UNIQUE_CHECKS\ = \ 0\;\nSET\ AUTOCOMMIT\ =\ 0\;\n;' scholarsdev-opt.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment