Quantcast
Channel: Active questions tagged ubuntu - Stack Overflow
Viewing all articles
Browse latest Browse all 5956

Permission denied for creating a new csv file using \copy on postgresql in ubuntu

$
0
0

I am doing postgresql exercise from command line using wsl ubuntu. When I want to create a csv file using my tables I get the following error.

test=# \copy (SELECT * FROM person LEFT JOIN car ON car.id = person.car_id) TO '/home/ubuntu/source/results.csv' DELIMITER ',' CSV HEADER;/home/ubuntu/source/results.csv: Permission denied

I am not very experienced in using Linux and the command line. When I browsed the internet a little, I saw that they changed the read-write permissions of the csv file, but I want to create a file that does not exist.


Viewing all articles
Browse latest Browse all 5956

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>