[OSGeo-Standards] Web Feature Service (WFS) and Axis Order

Even Rouault even.rouault at spatialys.com
Wed Oct 19 10:27:39 PDT 2016


Carl,

Thanks for this summary....

> Apparently, the CRS axis order issue never really "dies"!!

I confirm this impression. There is hardly a single month where I haven't had 
to deal with axis order issues. Either software implementation issues, either 
datasets with inconsistant content ( even if people got correctly the lat/long 
order for geographic coordinate systems, the few projected coordinate systems 
with northing/easting axis order are still a common issue ).

> Part of the confusion is probably due to changing OGC policies over the
> last 15 years.

Indeed ! A lot of people find that interoperability is usually better achieved 
when sticking with WFS 1.0.0 and WMS 1.1.1 rather than their latest versions.

If you just look at the number of possibilities to express a crs name  
mentionned in your email, this is just insane :

http://www.opengis.net/gml/srs/epsg.xml#4326
EPSG:4326
urn:ogc:def:crs:EPSG:<ver>:4326
urn:x-ogc:def:crs:EPSG:<ver>:4326
http://www.opengis.net/dev/crs/epsg/0/4326
urn:EPSG:geographicCRS:4326

And others not mentionned but I found in OGR ( 
https://github.com/OSGeo/gdal/blob/trunk/gdal/ogr/ogrspatialreference.cpp#L2030 
) or MapServer ( 
https://github.com/mapserver/mapserver/blob/branch-7-0/mapfile.c#L1564 ) code, 
possibly coming from WMS, WMTS or other OGC specs, or some probably coming 
from non conforming stuff found in the wild:

urn:ogc:def:crs:OGC:1.3:CRS84
urn:ogc:def:crs:OGC:2:84
urn:opengis:def:crs:OGC:2:84
http://www.opengis.net/def/crs/OGC/4326
CRS:84

I think there should be a moratorium to ban introducing new CRS notations...

> 
> Short synopsis: Before WFS 1.1.1 the only sure thing was that the axis
> order was LON/LAT when the notation "EPSG:4326" was used to define the CRS
> and otherwise was undefined.  For WFS 1.1.1 and later, the OGC Axis Order
> policy was in force which meant and still means that the axis order is
> defined by the CRS being referenced, such as lat/lon for EPSG 4326.
> 
> The longer answers is:
> 
> How any WFS instance interprets axis order depends on the version of the
> WFS standard implemented and the notation being used to specify the CRS.

I'm not sure to understand. In WFS 1.1.0, EPSG:4326 would imply lon/lat order, 
and in WFS 1.1.1 or later, the same EPSG:4326 notation should be interpreted 
as lat/lon ??
Whatever the official answer is, personnally I'd consider using EPSG:XXXX 
notation in WFS >= 1.1 a bad practice because of the potential ambiguity that 
might result. 

Even

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com


More information about the Standards mailing list