I cannot get the following code to generate any output. The MySQL user has "all" grant level, /tmp is writable, the query returns a results set.
mysql> SELECT field FROM test_table WHERE condition='test'
-> INTO OUTFILE '/tmp/test.csv'
-> FIELDS TERMINATED BY ','
-> ENCLOSED BY '"'
-> LINES TERMINATED BY '\n';
Query OK, 1 row affected (0.00 sec)
mysql>
[1]+ Stopped mysql
[root@web1 ~]# cat /tmp/test.csv
cat: /tmp/test.csv: No such file or directory
Should I be seeing different output from MySQL in case of failure?
Can I verify the result further than "1 row affected"?