I didn't get it :( for example, I'm using: SELECT * INTO OUTFILE 'result_a.csv' FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' LINES TERMINATED BY '\n' FROM lista_switches;
But this only saves the rows of data, with no column name; I would like to store the column name so the .csv is easier to read. If MySQL has options for storing, for example, the date as the last row, first column, even better; although I think I see what you mean, it reallly depends on the sleect statement? I f I manage to display what I want with the select, I'll be able to store it? That should work... But I though there was a -include_column_names option or something :) Which way should I go? Ariel -----Mensaje original----- De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Enviado el: miércoles, 01 de marzo de 2006 10:58 Para: Ariel Sánchez Mora; mysql@lists.mysql.com Asunto: RE: file permission [snip] This function is great! Anyone know how to include the column names, table info, any extra miscellaneous info? I use SQLyog for exporting to csv and they do include the columns, my bet is its some SQL option. The manual doesn't specify, at least in the select syntax part. [/snip] Any select query will be handled properly. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]