--- On Thu, 12/23/10, PeterKerk <vettepa...@hotmail.com> wrote: > From: PeterKerk <vettepa...@hotmail.com> > Subject: Sorting results on MULTIPLE fields, not showing expected order > To: solr-user@lucene.apache.org > Date: Thursday, December 23, 2010, 1:01 AM > > I want to sort results as follows > - highest membervalue (float) on top. > - within those results I want to sort the items that share > the same position > on the user rating (integer), once again, highest rating on > top > - and within those results I want to sort the items that > share the same > position on the fact if they have a photo (bit) > > > Now I have this: > &fq=themes:%22Boat%20and%20Water%22&sort=hasphoto%20desc&q=*:*&fl=id,title > > I see the correct item on top. > > But when I have the full query: > &fq=themes:%22Boat%20and%20Water%22&sort=membervalue > %20desc&sort=location_rating%20desc&sort=hasphoto%20desc&q=*:*&fl=id,title > > An item appears on top that has: > membervalue=0.00 > location_rating=0 > hasphoto=false > > There are other location that have either a higher > membervalue, a > locationrating or a photo. This location should NOT be on > top. > Why is this happening?
"Multiple sort orderings can be separated by a comma, ie: sort=<field name>+<direction>[,<field name>+<direction>]..." [1] [1]http://wiki.apache.org/solr/CommonQueryParameters#sort