October 5th, 1999, 01:55 PM
I have figured out how to import a tab delimited text file from the webserver directory into the MySQL database with the following:
LOAD DATA LOCAL INFILE '/home/www/textfile.txt' INTO TABLE tablename
But am so far unable to export from a MySQL table into a text file on the web server. Last tried the following:
SELECT * FROM tablename INTO LOCAL OUTFILE '/home/www/exporttext.txt'
October 5th, 1999, 03:18 PM
This command worked for me:
select * into outfile '/home/www/myfile.txt' from <mytable>;
This will save it on the server, so maybe you can ftp it out to your local computer?
I've had troubles using the LOCAL keyword.