WFS GetFeature response globalbounding box issue

Kralidis,Tom [Burlington] Tom.Kralidis at EC.GC.CA
Fri Dec 30 12:20:36 EST 2005


@(#&&

I just tried this on another dataset in my WFS and get back the root boundedBy element in native coordinates rather than that advertised by the WFS:

http://devgeo.cciw.ca/cgi-bin/mapserv/kyw?VERSION=1.0.0&SERVICE=WFS&REQUEST=GetFeature&outputFormat=GML3&TYPENAME=canadwshed&Filter=%3cFilter%3e%3cPropertyIsEqualTo%3e%3cPropertyName%3eWSHED%3c/PropertyName%3e%3cLiteral%3e01A01%3c/Literal%3e%3c/PropertyIsEqualTo%3e%3c/Filter%3e

Native datatype: shp/shx/dbf
Native projection of data: 42304
WFS SRS: 4326

whereas this works okay:

http://devgeo.cciw.ca/cgi-bin/mapserv/kyw?VERSION=1.0.0&SERVICE=WFS&REQUEST=GetFeature&outputFormat=GML3&TYPENAME=canadwscssda&Filter=%3CFilter%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3EWSCSDA%3C/PropertyName%3E%3CLiteral%3E01B%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3C/FILTER%3E&

Native datatype: PostGIS
Native projection of data: 42304
WFS SRS: 4326

Any ideas?

..Tom


-----Original Message-----
From:	Steve Lime [mailto:steve.lime at dnr.state.mn.us]
Sent:	Fri 30-Dec-05 11:36
To:	Kralidis,Tom [Burlington]; MAPSERVER-DEV at LISTS.UMN.EDU
Cc:	
Subject:	Re: [UMN_MAPSERVER-DEV] WFS GetFeature response globalbounding box issue

I figured you would! Thanks for testing. I'll commit tonite.

Steve

>>> "Kralidis,Tom [Burlington]" <Tom.Kralidis at EC.GC.CA> 12/29/05 2:39 PM >>>
So I was feeling adventurous :)

I made the changes to mapquery.c, make clean, ./configure, make.

When invoking the request again:

http://devgeo.cciw.ca/cgi-bin/mapserv/kyw?VERSION=1.0.0&SERVICE=WFS&REQU
EST=GetFeature&outputFormat=GML3&TYPENAME=canadwscssda&Filter=%3CFilter%
3E%3CPropertyIsEqualTo%3E%3CPropertyName%3EWSCSDA%3C/PropertyName%3E%3CL
iteral%3E01B%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3C/FILTER%3E&

...looks like that did the trick.

Thanks Steve -- once again, this is what I love about open source
software!

Looking forward to a formal commit.

..Tom


> -----Original Message-----
> From: UMN MapServer Developers List 
> [mailto:MAPSERVER-DEV at LISTS.UMN.EDU] On Behalf Of Steve Lime
> Sent: Thursday, December 29, 2005 2:20 PM
> To: MAPSERVER-DEV at LISTS.UMN.EDU
> Subject: Re: [UMN_MAPSERVER-DEV] WFS GetFeature response 
> global bounding box issue
> 
> 
> I gotta feeling I know what's wrong. Are you using that 
> latest code? That change in mapproject.c changed things so 
> that the bounds of the projected shape are recomputed after 
> projection. Previously that wasn't the case. Prior to that 
> the shape and its bounds could be in different projections. 
> The result set merges all those bounds into one layer bbox, 
> but again, in previous versions that box would have been in 
> the native projection of the layer NOT the main map 
> projection. That has changed.
> 
> If you are feeling adventurous try editing mapquery.c, 
> starting at line 1168 in the function
> msGetQueryResultBounds() and remove the 4 lines starting with:
> 
> #ifdef USE_PROJ
> 
> and ending with:
> 
> #endif
> 
> The projection would not be necessary since it would already 
> have done. What is happening is that we end up projecting 
> twice- bad news.
> 
> Let me know if that helps and I'll make the change before 
> releasing 4.8 (which I think should wait until Monday).
> 
> Steve
> 
> >>> "Kralidis,Tom [Burlington]" <Tom.Kralidis at EC.GC.CA> 
> 12/29/05 9:20 AM 
> >>> >>>
> Anyone have any updates / pointers w.r.t. this issue?
> 
> ..Tom
> 
> > 
> > 
> > Hi,
> > 
> > Against latest CVS, if I invoke the following OGC:WFS
> > GetFeature w/ Filter request: 
> > http://devgeo.cciw.ca/cgi-bin/mapserv/kyw?VERSION=1.0.0&SERVIC 
> E=WFS&REQUEST=GetFeature&outputFormat=GML3&TYPENAME=canadwscss
> da&Filter=
> %3CFilter%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3EWSCSDA%3C
> /PropertyN
> ame%3E%3CLiteral%3E01B%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3
> C/FILTER%3
> E
> 
> I receive a response back with results as expected.
> 
> When inspecting /msFeatureCollection/gml:boundedBy, the 
> actual values are not representative of the entire set of 
> results.  Infact, they're way off.  The gml:boundedBy chunk 
> WITHIN each gml:featureMember seem to be fine.
> 
> I notice mapproject.c was changed on 23/12/2005, so I'm not 
> sure if this had any effect.
> 
> Cheers
> 
> ..Tom
> 



More information about the mapserver-dev mailing list