I'm new to Solr and I'm wondering if the next example is possible.
Let's say I have a core with 2 fields, a string field 'name' and a multiValued field 'ids'. With doc 1:
- Name: Tim
- Ids: 1,2,3
and doc 2:
- Name: Bob
- Ids: 2,3
Now I want a query that gives me a result array with the following elements:
- 1 Tim
- 2 Bob
- 2 Tim
- 3 Bob
- 3 Tim
So the query returns each document per value in the multiValue field, first sorted on the value in 'ids' and second sorted on the name.
You could say, just select all the documents and handle the other stuff after the query, but I have a lot of data and I only want the first 20 documents sorted and per value in the multiValued field.
I hope this is possible and someone can help me! Thanks in advance.