Last active
November 1, 2016 13:31
-
-
Save ykrkn/2b63d90c83947266b9344f86ccd715c2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\copy (select '<location title="'||locations.title||'" lat="'||latitude||'" lng="'||longitude||'" />' from locations left join spatial on spatial.loc_id=locations.loc_id where latitude is not null and wkt is null union all select '<location title="'||locations.title||'" lat="'||latitude||'" lng="'||longitude||'" wkt="'||spatial.wkt||'" />' from locations left join spatial on spatial.loc_id=locations.loc_id where latitude is not null and wkt is not null) TO 'spatial.xml' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment