Bug report #8459

Add Part on NULL geometry

Added by Jean BAri over 10 years ago. Updated over 10 years ago.

Status:Closed
Priority:Normal
Assignee:-
Category:-
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:17227

Description

I have a PostGIS table with some polygons having NULL geometry. The rows are correctly displayed in the attribute table in QGIS. As expected, there is no geometry draw in QGIS.

I have tried different things in QGIS. The logical one for me was to use the tool "Add part" in the advanced editing toolbar. Unfortunately this hasn't work.

I receive a message:
"error, could not add part"
"New part's geometry is not valid."
"Ok"

I log this as a bug, because I believe if I add a part to a null geometry, as a result I should have this part as my geometry. But I understand, if this should be considered a new feature!

Before logging this as a bug, I also asked a question about how I can add a geometry to a NULL one:
http://gis.stackexchange.com/questions/67569/qgis-how-to-add-a-geometry-to-an-existing-feature-that-has-null-geometry

Thanks!

Note: It's the first time I create a new issue, so excuse me if it's not clear or not at the right place.

Associated revisions

Revision 872e5006
Added by Laurent Defert over 10 years ago

Use the layer type when adding a part to a featureless entry. Fix #8459

Revision e3e22be3
Added by Marco Hugentobler over 10 years ago

Merge pull request #984 from BioEcoForests/master

Use the layer type when adding a part to a featureless entry. Fix #8459

History

#1 Updated by Laurent Defert over 10 years ago

I can reproduce this issue on the master of today.
The behaviour is also similar when adding a part to a WFS record that has a NULL geometry, with a different error message:
"Selected geometry could not be found"

#2 Updated by Laurent Defert over 10 years ago

Added a pull request to fix the issue:
https://github.com/qgis/QGIS/pull/984

#3 Updated by Marco Hugentobler over 10 years ago

  • Status changed from Open to Closed

Also available in: Atom PDF