0

According to the MySQL documentation you should be able to export to data to CSV files:

The mysqldump command can also generate output in CSV, other delimited text, or XML format.

But the document doesn't reveal how? Can anybody help?

allanth
  • 423
  • 9
  • 23
  • https://dev.mysql.com/doc/refman/5.7/en/mysqldump-delimited-text.html – BenM Oct 16 '17 at 09:23
  • Possible duplicate of [How to output MySQL query results in CSV format?](https://stackoverflow.com/questions/356578/how-to-output-mysql-query-results-in-csv-format) – Thielicious Oct 16 '17 at 09:24

1 Answers1

1
SELECT * FROM `database_name`.`table_name` INTO OUTFILE 'path_to_folder/filename.csv' FIELDS ENCLOSED BY '"' TERMINATED BY ';' ESCAPED BY '"' LINES TERMINATED BY '\r\n';"

This is how you do it.

theBuzzyCoder
  • 2,652
  • 2
  • 31
  • 26