我,有表:
id | geo_id | values ....
1 1 wvrevev
2 2 wvrevev
3 3 wvrevev
3 4 wvrevev
7 5 wvrevev
8 6 wvrevev
9 8 wvrevev
在两个字段中的狮身人面像索引:id 和 geo_id
我需要某种东西,那将是我指定记录的顶部。在 SQL 中收到这样的请求:
SELECT * FROM table ORDER BY FIELD(geo_id, "2", "3", "6") DESC
如何在 Sphinx 中指定排序?此条目:
$cl->SetSortMode(SPH_SORT_EXTENDED, "FIELD(geo_id, "2", "3", "6") DESC");
引发错误:
enter code hereindex sphinxoffers: sort-by attribute 'field' not found
如何摆脱困境?