小编Nyx*_*yxx的帖子

无法对 Solr 地理空间搜索结果进行排序

我们怎样才能拥有的Solr 3.6.1回报地理空间搜索结果被过滤bbox和排序的距离是多少?

我尝试将 a 添加&sort=geodist() ascSolr 文档中所述的 URL ,但出现错误:

sort param could not be parsed as a query, and is not a field that exists in the index: geodist()

使用排序和 bbox 查询 URL(不工作)

http://localhost8080/solr/select?wt=json&indent=true
&q=*:*
&fl=id,latlng
&fq={!bbox%20pt=42.352455,-71.048069%20sfield=latlng%20d=5}
&sort=geodist() asc
Run Code Online (Sandbox Code Playgroud)

带有排序的查询 URL (Works)

http://localhost:8080/solr/select?wt=json&indent=true
&fl=id,latlng
&q=*:*
&sfield=latlng
&pt=42.352455,-71.048069
&sort=geodist()%20asc
Run Code Online (Sandbox Code Playgroud)

使用 bbox 查询 URL (Works)

http://localhost8080/solr/select?wt=json&indent=true
&q=*:*
&fl=id,latlng
&fq={!bbox%20pt=42.352455,-71.048069%20sfield=latlng%20d=5}
Run Code Online (Sandbox Code Playgroud)

如何bbox按距离 ( geodist())对结果进行过滤和排序?

lucene gis solr geospatial solarium

5
推荐指数
1
解决办法
2792
查看次数

标签 统计

geospatial ×1

gis ×1

lucene ×1

solarium ×1

solr ×1