Skip to content

Instantly share code, notes, and snippets.

@slarosa
Last active October 24, 2017 10:29
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 slarosa/18d67175befd341176e92cfc9b54c518 to your computer and use it in GitHub Desktop.
Save slarosa/18d67175befd341176e92cfc9b54c518 to your computer and use it in GitHub Desktop.
CREATE TABLE A1 AS
SELECT * FROM A WHERE comune = 'Y';
CREATE TABLE B1 AS
SELECT *, ST_Intersection(b.geom,
ST_Buffer(
(SELECT geom FROM A WHERE comune = 'Y'),
X)) as geom1 FROM B as b;
CREATE TABLE C1 AS
SELECT *, ST_Intersection(c.geom,
ST_Buffer(
(SELECT geom FROM A WHERE comune = 'Y'),
X)) as geom1 FROM C as c;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment