Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#6247 closed defect (fixed)

GML <xx:geometry> behavior does not work correctly

Reported by: JuergenWeichand Owned by: warmerdam
Priority: normal Milestone: 1.11.4
Component: default Version: unspecified
Severity: normal Keywords: gml, inspire
Cc:

Description (last modified by JuergenWeichand)

According to changeset #25183 (https://trac.osgeo.org/gdal/changeset/25183) the geometry inside <xx:geometry> should be used if there are several geometries per feature. This function seems to be broken. The attached test case produces a wrong result after the .gfs file has been written?

Output:

	---> GDAL Version: 2000100 <---
	~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
	Open attempt: 1
	GetGeometryType: 3
	GetGeometryRef: POLYGON ((2 49,2 50,3 50,3 49,2 49))
	~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
	Open attempt: 2
	GetGeometryType: 1
	GetGeometryRef: POINT (-2 -49)
	~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
	Open attempt: 3
	GetGeometryType: 1
	GetGeometryRef: POINT (-2 -49)

Attachments (1)

ogr-bugreport.py (1.3 KB ) - added by JuergenWeichand 8 years ago.
Python Testcase

Download all attachments as: .zip

Change History (6)

by JuergenWeichand, 8 years ago

Attachment: ogr-bugreport.py added

Python Testcase

comment:1 by JuergenWeichand, 8 years ago

Description: modified (diff)

comment:2 by Even Rouault, 8 years ago

Milestone: 2.0.2
Resolution: fixed
Status: newclosed

Can be workarounded by adding to the .gfs :

    <GeometryName>geometry</GeometryName>
    <GeometryElementPath>geometry</GeometryElementPath>

trunk r31859, branches/2.0 r31860 "GML: serialize in .gfs file the name of the geometry element when it is 'geometry' since this is a particular case (#6247)"

comment:3 by JuergenWeichand, 8 years ago

Thank you very much Even! Any chance for a 1.11.4 backport (e.g. for QGIS)?

comment:4 by Even Rouault, 8 years ago

Milestone: 2.0.21.11.4

Backported in 1.11 in r31861

comment:5 by JuergenWeichand, 8 years ago

Perfect, thanks!

Note: See TracTickets for help on using tickets.