Created
June 6, 2012 19:56
-
-
Save McKinneyDigital/2884338 to your computer and use it in GitHub Desktop.
Export a CSV of user info from database table in a single SQL Query
This file contains 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
SELECT id,email FROM users INTO OUTFILE '/tmp/users.csv' FIELDS TERMINATED BY ',' LINES TERMINATED BY '\n' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment