/ Published in: SQL
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
USE YOUR_DB_NAME; SELECT * INTO OUTFILE 'PATH/TO/FILE.csv' FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' ESCAPED BY '\\' LINES TERMINATED BY '\n' FROM TABLE_NAME WHERE FILTERS_GO HERE = 1;