Skip to content

Instantly share code, notes, and snippets.

@duizendnegen
Created July 30, 2016 15:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save duizendnegen/d4b31b5c4ad9380bb7b1ed293982890c to your computer and use it in GitHub Desktop.
Save duizendnegen/d4b31b5c4ad9380bb7b1ed293982890c to your computer and use it in GitHub Desktop.
\copy (SELECT tags -> 'to' AS route_to, tags -> 'from' AS route_from, tags -> 'to' AS route_to2, tags -> 'from' AS route_from2 FROM railmap_line WHERE tags -> 'route' = 'train' AND tags -> 'from' != '' AND tags -> 'to' != '') TO /psql/dump.csv CSV DELIMITER ','
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment