sphinix search with custom field ordering with relevence

63 Views Asked by At

I'm using Sphinx QL for processing results. In my Sphinx Index there are numbers of fields like sub_cate_name, area_name, city_name and company_priority etc...

With my company priority field there were 1,2,3,4,5 priority into database. Company having low priority get first via sphinx search (order by priority asc).

I am searching with following query

SELECT * FROM sub_cate_index
 WHERE MATCH('(@(sub_cate_name,sub_cate_area,area_name,business_name) "^car dealers$")')
         AND city_name='ahmedabad'
 ORDER BY area_name ASC
 LIMIT 0,100000
 OPTION max_matches=100000, ranker=sph04;

I also tried out ORDER BY clause into Sphinx QL, but it would lose relevance of actual keyword search.

Any help will be appreciated.

0

There are 0 best solutions below