Robomongo: Sorting of result's columns when in Table mode

Created on 18 Sep 2013  路  17Comments  路  Source: Studio3T/robomongo

Clicking on table header item doesn't sort the corresponding column, is that a feature?
(OS: Win7x64)

enhancement high vote

Most helpful comment

@stmoroz

I think sorting the shown batch makes more sense. All the sql database management apps that I have used behave the same way.

All 17 comments

Hi @saatchiCEO!
Currently sorting shouldn't work by design.
However, we are looking for ways to implement sorting which will be user-friendly for every user.
Thanks for reporting!

Clicking the table header to sort that table is the most user-friendly way I think.

In tree mode a new context menu item can be added when right click on a particular key called "Sort by this key", with two sub-items: "Ascending" and "Descending".

@levani

We think similar way. However, the main question is to sort entire collection or sort shown batch of documents?
What do you think?

@stmoroz

I think sorting the shown batch makes more sense. All the sql database management apps that I have used behave the same way.

:+1:

Okay, then we'll implement it as sorting of currently loaded documents only. Thanks for the suggestions!

For me it is preferable to sort the entire collection, not on a page level. I'm using MongoDB mostly for logs, and I want to see the most recent records. Currently by default it shows the most old records which is inconvenient.
Sorting on a page level does not make much sense. There are only 50 records by default which could be easily scrolled by a mouse wheel. Writing ".sort({"_id":-1})" every time is much more annoying!
Please make it! That is almost the only issue that I have with this excellent application!

Sounds simple to implement...
clicking or 2click on the table header should add something like: .sort({"fieldName":1})

Is this project still alive?

@heldersepu The Robomongo project is definitely alive, but unfortunately there isn't a lot of developer bandwidth at the moment.

I'm not sure if this specific feature is as simple as it sounds. Per the earlier discussion on this issue there are a few ways to consider sorting:

  • sorting the current result batch that is displayed
  • adding a sort() value and re-executing the query

I don't think the choice of sorting needs to be exclusive - I could envision wanting to iterate results in a certain sort() order but also sorting the current page to help find specific documents in that batch.

There are also several cases where adding a sort() value to the query won't work. For example:

  • when the results aren't from a simple find() (i.e. aggregation query or JS output)
  • when the table column represents an embedded document or array
  • when the sort() is on an unindexed field and the results are >32 MB

Given there is a mandatory index on _id, I think a simpler use case to implement would be adding a user preference for the default sort order. I created issue #539 for this; please comment on that issue if you think it's worthwhile to implement.

If you'd like to help, pull requests are always welcome :)

I see, I was thinking just the easiest approach, just append the .sort() to the query.

After playing with this for a bit longer, I see that the table view is not really that useful...
Many documents are not "translatable" to a table, fields with arrays the table view is useless.
I will give this a low priority. Looking at the other requests you guys have bigger fish to fry

Any update on this?

I want this feature. It is not pretty deal to find a key in document which have 20+ keys in random sorting.
Soon 2017 year. Maybe somebody return to this issue ?

Hi @EvgeniyMakhmudov , currently we are focused on delivering critical features Replica Sets and Export/Import asap. I tagged this as high vote, we will for sure consider to include this feature in the next releases. Thanks for your interest.

Thanks @simsekgokhan!

+1 for this feature

+1

+1

Was this page helpful?
0 / 5 - 0 ratings