Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I often get an ogr error when I try to save a shapefile after working on it in Qgis ( adding features, removing, modifying attributes.. )

The error says :
"OGR ERROR : Attempt to delete shape with feature id (-28 ) which does not exist"

Does anyone have an idea about the reason why I'm getting this error and/or how to avoid it ?

share|improve this question

1 Answer 1

I think you will not get this error if you Save between adding and removing features.

share|improve this answer
    
Thanks for the answer, using save between each operation may solve the problem but when working with a large number of features and a considerable amount of operation it becomes "annoying" to have to save changes to the shapefile after each action! –  QgisTn Dec 13 '12 at 13:33
2  
Ok, then try the 'Save' always before deleting anything. Until you save, the features are only stored in memory, with negative ID. 'Save' might try to save and delete them in one step, which causes the error message. Same goes to adding and deleting table columns. –  Andre Joost Dec 13 '12 at 13:48

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.