Last active
August 29, 2015 14:20
-
-
Save tjmgis/e377d80b248061ea3ace to your computer and use it in GitHub Desktop.
New Topographic Point SQL
This file contains hidden or 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
ALTER TABLE osmm_topo.topographicpoint ADD COLUMN style_description VARCHAR; | |
COMMIT; | |
ALTER TABLE osmm_topo.topographicpoint ADD COLUMN style_code INTEGER; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Triangulation Point Or Pillar', 11) WHERE style_code IS NULL AND descriptiveterm = '{"Triangulation Point Or Pillar"}'; --Must appear above Structure, 5 because it has the same featurecode | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Spot Height', 1) WHERE style_code IS NULL AND featurecode = '10197'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Culvert', 2) WHERE style_code IS NULL AND featurecode = '10085'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Positioned Nonconiferous Tree', 3) WHERE style_code IS NULL AND featurecode = '10048' OR featurecode = '10132'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Water Structure', 4) WHERE style_code IS NULL AND featurecode = '10088'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Structure', 5) WHERE style_code IS NULL AND featurecode = '10186' OR featurecode = '10191'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Road Structure', 6) WHERE style_code IS NULL AND featurecode = '10176' OR featurecode = '10179'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Railway Structure', 7) WHERE style_code IS NULL AND featurecode = '10158' OR featurecode = '10159'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Positioned Coniferous Tree', 8) WHERE style_code IS NULL AND featurecode = '10050'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Landform', 9) WHERE style_code IS NULL AND featurecode = '10094'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Boundary Post', 10) WHERE style_code IS NULL AND featurecode = '10129'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Historic', 12) WHERE style_code IS NULL AND featurecode = '10072' OR featurecode = '10080'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Positioned Boulder', 13) WHERE style_code IS NULL AND featurecode = '10051'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Tidal Water', 14) WHERE style_code IS NULL AND featurecode = '10209'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Diused Feature', 15) WHERE style_code IS NULL AND featurecode = '10100'; | |
COMMIT; | |
UPDATE osmm_topo.topographicpoint SET (style_description, style_code) = ('Path', 16) WHERE style_code IS NULL AND featurecode = '10120'; | |
COMMIT; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment