Created
March 16, 2019 01:46
-
-
Save chapmanjacobd/98b8ce57f1c7c11174c4e45c3bc216c7 to your computer and use it in GitHub Desktop.
removes properties from geojson. import into database SQL
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
UPDATE wof | |
SET body = substring(body, '(?<=geometry": ).*$'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
use like this
update wof_geojson set geom = st_transform(st_makevalid(st_setsrid(ST_GeomFromGeoJSON(substring(body, '(?<=geometry": ).*$')),4326)),4087)