Domanda

Sometimes, I'm just looking at data in the RavenDB studio, usually by index, and I wanted to know if there was a way to specify a sort option?

For example, if I have simple index like this:

from doc in docs.Pages
select new
{
    Query = new[] { page.Text, page.Views },
    page,
    Views = page.Views
}

If I want to look at all pages that have stackoverflow in the text ordered by the most views, how would I query that in the RavenDB Studio?

È stato utile?

Soluzione

When you are executing your query, There is an "Add Sort By" button. Click that, and you will get a drop-down list of indexed values available for sorting.

In RavenDB 2.0, it looks like this:

enter image description here

If you're still on RavenDB 1.0, it looks a bit different:

enter image description here

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top