I'm on a GCE instance with a postgresql DB and I'm running the following command:
COPY (Select * from mytable) TO '/home/myuser/myfile.txt' DELIMITER '#' CSV HEADER;
and getting the following error:
could not open file "/home/myuser/myfile.txt" for writing: Permission denied
how to fix it? (on my local machine this command works fine)