3nids / itembrowser

A QGIS 2.x plugin to browse a multiple selection, with auto-zooming to current feature and an option to open feature form.
Other
4 stars 4 forks source link

Incorrect Feature ID numbers #2

Closed SrNetoChan closed 9 years ago

SrNetoChan commented 11 years ago

In QGIS Master, the features numbers that appear in Item Browser don't match the feature number in attribute table.

This seams to happen after sorting the attribute table. I'm not sure if it's a itembrowser plugin issue or an attribute table issue in 1.9, but anyway, it might be good to have a look.

3nids commented 11 years ago

What data provider are you using?

Because QGIS feature ID might be different from your provider's ID. A serial primary key from a postgres table would be reused as ID in QGIS. But if you have a shape with a column named ID it won't be reused (even if it's a serial like).

Can you confirm?

SrNetoChan commented 11 years ago

I'm using shapefiles. I was trying to replicate the error, but I'm was not being able to. It seams that the problem only start when I delete a feature, and undo it. Even after commit changes, id numbers don't match. I can only make it match again after removing and add the layer again.

Before delete and undo delete: Itembrowser_BeforeUndo

After delete and undo delete: Itembrowser_AfterUndo

Thanks

PS: Very useful plugin!! Quite good for boring task of review data one feature at a time.

3nids commented 11 years ago

OK. And if you unselect/select again, isn't the problem solved?

Thanks for comment!

SrNetoChan commented 11 years ago

No, like I said, I needed to remove the layer and add it again to be able to use ItemBrowser. Like I said, I'm not sure is the bug is not related to QGIS it self.

3nids commented 11 years ago

ok thanks. I will try to investigate it next week.