My .NET/OpenLayers/GeoServer/PostGres-PostGIS application allows users to create custom queries to get data from my PostGIS tables.
The queries are called in .NET (not javascript) using a web method using the following SQL query:
SELECT "tract_name", ST_AsGeoJSON("geom") FROM a_postgis_table;
The query works fine when I run it in the PostGres SQL window.
How can I pass the PostGIS results, including the GeoJSON column, back to javascript/openlayers from the .NET web method so that OpenLayers can render the vector layer in the map? There has to something really simple I am missing here. Seems like this should be an extremely common thing that people need to do.
أكثر...
The queries are called in .NET (not javascript) using a web method using the following SQL query:
SELECT "tract_name", ST_AsGeoJSON("geom") FROM a_postgis_table;
The query works fine when I run it in the PostGres SQL window.
How can I pass the PostGIS results, including the GeoJSON column, back to javascript/openlayers from the .NET web method so that OpenLayers can render the vector layer in the map? There has to something really simple I am missing here. Seems like this should be an extremely common thing that people need to do.
أكثر...