If you want to use OUTFILE with a variable for the file name you cannot simply put it in place - MySQL will not resolve the name.
But you can do with the following way:
put the whole command into a variable and use "prepare" and "execute"
SELECT @myCommand := concat("SELECT * from mytable into OUTFILE '/home/mysql/archive/", curdate(), ".txt'");
PREPARE stmt FROM @myCommand;
EXECUTE stmt;
Hope this helps....