mongotron icon indicating copy to clipboard operation
mongotron copied to clipboard

Bug: First and last collection results has the same _id

Open armand1m opened this issue 8 years ago • 3 comments

Hi, first of all, thanks for developing Mongotron. Has made my learning curve way easier to work with MongoDB.

However, I've noticed this problem in the version 1.0.0-alpha.5 when running on macOS and xUbuntu:

This is the result from a db.users.find({}) simple query that returns 2 documents:

captura de tela 2017-10-01 as 14 40 39

If you see, the Id being displayed for the 2 documents are the same. If you look at the _id property of each document, you can know from what document this repeated id belong:

captura de tela 2017-10-01 as 14 40 44

captura de tela 2017-10-01 as 14 40 51

Apparently the last document is its owner. I've tried querying other collections with more documents, and saw that the first item Id is always being the same as the last document from the result:

captura de tela 2017-10-01 as 14 40 23

The problem with this is that, when you use the edit button to edit the first document, the changes applied go to the last document, because of this id mismatch. So in order to update the first document, you need to copy the id and write an updateById (also remind to fix the last change that was a mistake).

armand1m avatar Oct 01 '17 17:10 armand1m

It seems to be the same as #151, and also related to #133 (probably the main cause to this one)

armand1m avatar Oct 01 '17 17:10 armand1m

Has been any work done on this? or what is the status? Thank you.

lattam avatar Feb 28 '19 14:02 lattam

@lattam mongotron seems to be stopped since 2016 =)

armand1m avatar Feb 28 '19 14:02 armand1m