[mapserver-dev] Support for feature querying without spatial filtering

Tamas Szekeres szekerest at gmail.com
Sun Sep 16 13:55:22 PDT 2012


Hi Devs,

I'd like to establish support for querying the shapes without a spatial
filter. The query would be initiated from the mapscript interface, but I
would prefer to notify the driver not to use the spatial filter in some
cases.

The most compelling reasons to implement such change are:

1. When using an attribute query or a filter expression query, we don't
know or don't want to specify a search rectangle.
2. We can experience a performance increment (especially for the database
drivers) by reducing the complexity of the query execution plan.

The most straightforward implementation would be to modify the parameters
of whichShapes from:

int msLayerWhichShapes(layerObj *layer, rectObj rect, int isQuery)

to:

int msLayerWhichShapes(layerObj *layer, rectObj rect, int options)

we could use constant values for options such as:

#define MS_QUERYOPT_ISQUERY  0x01
#define MS_QUERYOPT_NONSPATIAL  0x02

Drivers should take care of using MS_QUERYOPT_NONSPATIAL. In the first
turn, I'd like to implement using this for mssql2008 specifically.

Let me know what you think.


Best regards,

Tamas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20120916/d4384947/attachment.html>


More information about the mapserver-dev mailing list