Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
export psql query result to csv file
\copy (select column1, column2 from mytable) To '/tmp/dump.csv' With CSV DELIMITER ',' HEADER
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment