I have only been able to find examples where geometry attributes are returned 
from cross layer filtering functions, but the GeoServer documentation says:

A common use case is to extract a geometry-valued attribute, and then use the 
value(s) in a spatial predicate against a geometry attribute in the primary 
layer.<http://docs.geoserver.org/stable/en/user/extensions/querylayer/index.html>

Which leads me to believe that it was intended to be used to return other data.

I'm looking for examples of how that might be done in a CQL filter.

________________________________

I have attempted something like this: 
http://localhost:8181/geoserver/test/wms?service=WMS&version=1.1.0&request=GetMap&layers=test:layer1,test:layer2&styles=&bbox=-81.54053,41.61621,-77.33826,43.41248&width=768&height=330&srs=EPSG:4326&format=application/openlayers&cql_filter=INCLUDE;property2a=querySingle('test:layer1','property1b','property1a=123')

Where only records in layer2 that have layer2.property2a = layer1.property1b 
are returned.

I get the exception: "Could not parse CQL filter list."

________________________________

Similarly: 
http://localhost:8181/geoserver/test/wms?service=WMS&version=1.1.0&request=GetMap&layers=test:layer1,test:layer2&styles=&bbox=-81.54053,41.61621,-77.33826,43.41248&width=768&height=330&srs=EPSG:4326&format=application/openlayers&cql_filter=INCLUDE;property2a
 IN queryCollection('test:layer1','property1b','INCLUDE')

Where the values of layer2 will only be returned if layer2.property2a has a 
value in the returned values from layer1.property1b
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
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


Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to