hi all,
is it possible to write a WFS filter that intersects a subset of the
geometry from one layer with a subset of the geometry from another layer?
This is mainly for performance reasons.

In the below query I am intersecting a subset of geometry over the whole
base layer. Instead, can I first select a part of the base layer?

Is there any other way to increase performance of this query? I am using
the area calculation as the boundaries of the geometries on the two layers
do not coincide exactly, so Within, Intersection, etc give false positives.

Regards

<wfs:GetFeature xmlns:wfs="http://www.opengis.net/wfs";

        xmlns:sf="http://www.openplans.org/spearfish"; xmlns:ogc="
http://www.opengis.net/ogc";

        xmlns:fes="http://www.opengis.net/fes/2.0";

        service="WFS" version="1.0.0">

        <wfs:Query typeName="ABS_States_2016_40M">

                <wfs:PropertyName>STATE_CODE</wfs:PropertyName>

                <ogc:Filter>

                        <ogc:PropertyIsGreaterThan>

                                <ogc:Function name="area">

                                        <ogc:Function name="intersection">


<ogc:PropertyName>the_geom</ogc:PropertyName>

                                                <ogc:Function
name="querySingle">


<ogc:Literal>MMM_by_State</ogc:Literal>


<ogc:Literal>the_geom</ogc:Literal>


<ogc:Literal>regionCode = '77'</ogc:Literal>

                                                </ogc:Function>

                                        </ogc:Function>

                                </ogc:Function>

                                <ogc:Literal>0.001</ogc:Literal>

                        </ogc:PropertyIsGreaterThan>

                </ogc:Filter>

        </wfs:Query>

</wfs:GetFeature>
_______________________________________________
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to