[postgis-users] Is it possible to do constraint exclusion based on spatial extents?

2015-08-02 Thread Stephen Woodbridge
Hi, I know I can setup table inheritance and constraint exclusion based on say the state field. But I would like to do this based on geom and the table extents. How would I do this? Say for example, I create a roads table, then load data into roads_area1, roads_area2, etc and these inherit

Re: [postgis-users] Is it possible to do constraint exclusion based on spatial extents?

2015-08-02 Thread Rémi Cura
Hey, I asked this question to the postgres mailing list here: http://www.postgresql.org/message-id/CAJvUf_szgMLxC4=b6+agy9hgypares2jvb6btkxiff6cxa_...@mail.gmail.com I would be very interested if you find a solution (I did not). Cheers, Rémi-C 2015-08-02 21:04 GMT+02:00 Stephen Woodbridge

Re: [postgis-users] Is it possible to do constraint exclusion based on spatial extents?

2015-08-02 Thread Stephen Woodbridge
Hi Remi, So I got this far, without any success: -- get the bbox for each table select st_extent(geom) from rawdata.streets_91; -- 'BOX(-87.60196 24.54513,-80.0323 31.00091)' select st_extent(geom) from rawdata.streets_92; -- 'BOX(-88.47265 30.2251,-80.84104 35.00732)' select