ThinkGeo.com    |     Documentation    |     Premium Support

How to query PostGIS on-the-fly

We need the ability to query the PostGIS database on-the-fly. For example, if the user draws an area or define an area, then I will query the database and display the data only in the selected area. The PostgreSQLFeatureLayer only accepts a table name, can not pass in a query string


We have very large data tables that continuously grow so I can not retrieve the whole table every time an area is selected.


Please advise me what is the best way to do this?



Steve, 


The current edition (3.0.199) doesn’t support View for Postgre but we have a new extension now which support it. Please have a look at the following post, where you can get that extension, see the sample codes, and see David's comments which introduced some other methods to accomplish it.
gis.thinkgeo.com/Support/Dis....aspx#7632
 
Thanks,
 
Ben