How to sort two fields in Solr 3.6

The web request url has a sort option. However, how do I sort by two fields? If I do something like:

sort=field1 asc&sort=field2 desc 

Only the first field will be used to sort by my observations.

+6
source share
2 answers

do it like this:

 sort=field1 asc, field2 desc 
+19
source

GUMZ (3.6.2) but if you want to sort additional intField paired with an "account"
try searching instead:

 sort=score desc,intField desc 

this:

 sort=intField desc,score desc 
+1
source

Source: https://habr.com/ru/post/922094/


All Articles