ded up just taking the tab delimited output and copy pasting it to a spreadsheet and then exporting that to csv. Also realized that I could have used the concat or concat_ws function to do the job and will do that next time.
SELECT CONCAT_WS(',', field1, field2, field3) FROM table;
You may want to use '--silent' option to remove tabular output
-
--silent,-sSilent mode. Produce less output. This option can be given multiple times to produce less and less output.
This option results in nontabular output format and escaping of special characters. Escaping may be disabled by using raw mode; see the description for the
--rawoption.
-
--raw,-rFor tabular output, the “boxing” around columns enables one column value to be distinguished from another. For nontabular output (such as is produced in batch mode or when the
--batchor--silentoption is given), special characters are escaped in the output so they can be identified easily. Newline, tab,NUL, and backslash are written as\n,\t,\0, and\\. The--rawoption disables this character escaping.The following example demonstrates tabular versus nontabular output and the use of raw mode to disable escaping:
%
mysqlmysql> SELECT CHAR(92); +----------+ | CHAR(92) | +----------+ | \ | +----------+ %mysql -smysql> SELECT CHAR(92); CHAR(92) \\ %mysql -s -rmysql> SELECT CHAR(92); CHAR(92) \
http://dev.mysql.com/doc/refman/5.5/en/mysql-command-options.html#option_mysql_silent
6764

被折叠的 条评论
为什么被折叠?



