Opened 17 years ago
Closed 17 years ago
#43 closed defect (fixed)
SHP, SDF: wrong results when quering multi polygons
Reported by: | danstoica | Owned by: | danstoica |
---|---|---|---|
Priority: | major | Milestone: | 3.3.0 |
Component: | SHP Provider | Version: | 3.2.0 |
Severity: | 3 | Keywords: | |
Cc: | External ID: |
Description
A decision was previosly made to not alter the polygon returned from a shp file. As a result when reading, SHP provider never returns a MultiPolygon. They are all Polygons.
In consequence, when doing spatial queries on a Polygon (which is in fact a multipolygon) and the selected area in not inside the external ring or touching the ring's boundary, nothing will be returned.
The solution was fix the spatial query (not the reading). That is, before passing the geometry to the spatial filter, the Polygon needs to be checked and see "Is this polygon actually a multipolygon?" If so, create a multipolygon and pass it down to the spatial filter instead.
The same applies to the SDF provider.