Send the link below via email or IMCopy
Present to your audienceStart remote presentation
- Invited audience members will follow you as you navigate and present
- People invited to a presentation do not need a Prezi account
- This link expires 10 minutes after you close the presentation
- A maximum of 30 users can follow your presentation
- Learn more about this feature in the manual
Do you really want to delete this prezi?
Neither you, nor the coeditors you shared it with will be able to recover it again.
Make your likes visible on Facebook?
Connect your Facebook account to Prezi and let your likes appear on your timeline.
You can change this under Settings & Account at any time.
PostGIS and QGIS: Dynamic Layers with Views
Andrew Bellon 1 July 2014
Transcript of PostGIS and QGIS: Dynamic Layers with Views
What's going to happen?
The Story / Scenario
Live Demo in QGIS
How it works
Layers and SQL
Summary and possibilities
QGIS and PostGIS Trainer
Background in Local Goverment GIS
Identifying points of interest along a route
CREATE TABLE demo.myroutes
id serial NOT NULL,
NOT NULL DEFAULT 20
My Routes Layer
CREATE VIEW demo.routebuffer AS
st_buffer(myroutes.geom, myroutes.buffer) AS buffergeom
CREATE VIEW demo.poi_near_route AS
rb.my_interest = p.pointx_cla::integer
Locations inside buffer
CREATE OR REPLACE FUNCTION demo.tf_deleterecords()
RETURNS trigger AS
IF TG_OP = 'INSERT' THEN
EXECUTE 'DELETE FROM demo.myroutes' ;
ELSE RETURN NEW;
CREATE TRIGGER delete_records
FOR EACH ROW
EXECUTE PROCEDURE demo.tf_deleterecords();
Create Trigger / Trigger Function on My Routes
To delete the previous
Power-up QGIS with using PostGIS!
PostGIS Views & spatial functions enable virtual layers to dynamically return data on the fly.
No need to create shapefiles to buffer!
Enable non-techie GIS user to do cool and techie things.
QGIS is simple and effective
QGIS makes PostGIS queries accessible and visual
The technique uses:
PostGIS connectivity and layers
Data input Forms
HTML map tips
Key QGIS strengths
Live tracking data
AREA AT RISK
QGIS dynamic layers - Andrew Bell.zip