Question

select * INTO OUTFILE '/tmp/result.txt' FIELDS TERMINATED BY ',' LINES TERMINATED BY '/n' from ancestor;

So I run this command, and it executes normally. I run it again, and it errors because it says that result.txt already exists. When I check within the tmp folder on my computer, I don't see the file there. I have seen many people run into similar errors, and many people's responses have been that it gets saved on the host server. And it does! Which is fine. But here is the thing. I need it to save on my client computer. How do I make it so it works on the client? Also, the client is running mac os x. Also, the person who uses the client uses workbench and would prefer not to use terminal. Because I know there is the -e command for terminal but I don't know how to replicate that on workbench.

Was it helpful?

Solution 2

So I feel like a fool, but there is an export button in mySQL workbench that allows you to export the result of any query. This avoids the whole issue I've been having. Sorry to trouble you guys. Thanks for all of your help!

OTHER TIPS

On Mac OSX, files in the /tmp directory are hidden in the finder.

You could try this to show hidden files in the finder.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top