Use variables in filename with INTO OUTFILE (timestamped filename)

Posted on

Question :

SELECT *
FROM project
INTO OUTFILE 'C:desktop[timestamped filename like 01/05/2014.csv]';

Can anyone help me out?

Answer :

Has said in this post, you can use:

SET @sql_text =
CONCAT (
"SELECT * FROM `project ` into outfile 'C:desktop"

Leave a Reply

Your email address will not be published. Required fields are marked *