I'm having problems with a CQL filter on a WFS layer, using Openlayers and
Geoserver 2.0.2.

 

The following layer definition returns all features, not just those where
Desc contains bird. 

                var photopoints = new OpenLayers.Layer.Vector("Photos", {

                                strategies: [new
OpenLayers.Strategy.Fixed()], 

                                projection: new
OpenLayers.Projection("EPSG:2193"),

                                protocol: new OpenLayers.Protocol.WFS({

                                                version: "1.1.0",

                                                srsName: "EPSG:2193",

                                                url: "../wfs",

                params: {CQL_FILTER: "Desc LIKE '%bird%'"},

                                                featureNS :
"http://www.orokonui.org.nz/orok";,

                                                featureType: 'photopoints',

                                                featurePrefix: 'Orokonui',

                                                geometryName: "the_geom"

                                }),

                                displayInLayerSwitcher: true,

                                styleMap: smap

                });

 

However, if I enter a nonsense filter, for example {CQL_FILTER: "Desc x
'%bird%'"}, nothing is returned and Firebug shows that Geoserver has
responded with ....<ows:Exception exceptionCode="NoApplicableCode">
<ows:ExceptionText>Could not parse CQL filter list.....
 
Thanks
Tony

 

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to