Hi all, Problem :-
Assume that, I am searching for car care centers. Solr collection has the data for all the major car care centers. As an example I search for Firestone car care centers in a 5 miles radius. In the search results I am supposed to receive the firestone car care centers list within 5 miles from the specified location and the centers should be sorted in distance order. In the solr query handler I have specified the following. i) I have specified the query condition (q) to be based on distance parameter (basically search for records within a certain distance in miles). ii) I have specified the filter query conditions (fq) where fields accepting general text are matching free text input (for ex :- Firestone Carcare) iii) I have specified the sort condition(sort ) to be based on score(calculated based on the filter query (fq) conditions applied in the 2nd item in the list) and distance. If there are duplicate records matching by score, then distance should be used to order the duplicate records. I am not getting the desired results. Records are still sorted by score which was calculated using the distance field but not using the filter query conditions that were specified. Basically, the firestone car care centers that I am looking for are not appearing in the top of the results and also they are not in the order of distance if the records are matching. Queries :- i) Why is my sort clause specified by me (based on fq conditions score and distance) not being applied correctly? ii) Is my approach to fix the problem correct? iii) Please let me know the corrective action. Thanks in advance. Regards, Deepak The information contained in this email message and any attachments is confidential and intended only for the addressee(s). If you are not an addressee, you may not copy or disclose the information, or act upon it, and you should delete it entirely from your email system. Please notify the sender that you received this email in error.