3

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 ?

3

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

  • 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. – AndreJ Dec 13 '12 at 13:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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