[Mapserver-dev] Re: OGR Layers

Daniel Morissette morissette at dmsolutions.ca
Tue Sep 30 09:45:16 EDT 2003


Frank Warmerdam wrote:
> 
> I noticed that the OGR layer in mapserver doesn't seem to have any way of
> passing an attribute query down to the OGR driver other than doing the
> request as an OGR SQL query.  What do you think of the idea of treating
> the FILTER as an OGR attribute query if FILTERITEM isn't set, and treating
> it as a mapserver-side filter if FILTERITEM is set?
> 

I can see why it could be nice to have OGR perform the filter sometimes, 
but I'm not very comfortable with using FILTERITEM to control that.  Do 
you know if any of the other data sources (PostGIS, SDE, Oracle) support 
this way of passing down the filter and how they do it?  We should 
probably implement things the same way in OGR as in the PostGIS/SDE drivers.

I'm a bit worried that we would create confusion if the expression was 
handled differently when FILTERITEM isn't set.  AFAIK everywhere else in 
MapServer the FILTERITEM/CLASSITEM/etc is optional when you use logical 
expressions (it is ignored) and then MapServer scans the expression 
itself to find the fields that it needs to read.  With that change, OGR 
would become an exception to this and I'm worried that someone could set 
or unset FILTERITEM by accident and then would not understand why their 
expression doesn't work the same way as before.  (Until they go and read 
the docs of course but that shouldn't be required in a consistent system.)

I'll forward this to mapserver-dev to see what Steve and others think.

Daniel
-- 
------------------------------------------------------------
  Daniel Morissette               morissette at dmsolutions.ca
  DM Solutions Group              http://www.dmsolutions.ca/
------------------------------------------------------------




More information about the mapserver-dev mailing list