I have data in two locations:
- geometry data (with attributes) on a PostGIS server (read only)
- a geometryless table on a local SpatiaLite DB (read+write)
I need to select features based on data from the geometryless table. My current solution is to clone the complete geometry data from PostGIS to the SpatiaLite DB (using QGIS) and executing the (simplified) query below but that's not exactly optimal.
SELECT t.ID, t.Attribute1, t.Attribute2, s.Geometry FROM TabularData t, ShapeData s WHERE s.Attribute1 = t.Attribute1 AND s.Attribute2 = t.Attribute2
Any idea how to do this across the databases?