I'm sorry, missed that part. It's true, you cannot sort on multivalued fields. The workaround will be pretty complex; you'll either have to find the max or min value of the fields at index time and store those in separate fields and use those to sort, or somehow come up with some function that can convert the values from your multivalued field into a single value (something like sum(field)) but it surely won't be trivial.
Instead you should do what Emir's saying. Boost your fields at index or query time based on how you want to sort your documents. So in your case, give the highest boost to topic_title then a little lower to subtopic_title and so on. This should return your documents in the correct order. You will have to play around with the boost values a little to get them right, though. Alternatively, you could boost on the multivalued fields and then sort based on your single valued fields. Either ways, you'll have to experiment and see what works best for you. On Mon, Feb 15, 2016 at 8:21 PM Nitin.K <nitin.kanu...@adi-mps.com> wrote: > Thanks Binoy.. > > Actually it is throwing following error: > > can not sort on multivalued field: index_term > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/SOLR-ranking-tp4257367p4257378.html > Sent from the Solr - User mailing list archive at Nabble.com. > -- Regards, Binoy Dalal