簡體   English   中英

Solr geofilt返回所有結果

[英]Solr geofilt returning all results

我正在運行Solr 5.4(在Ubuntu服務器上)並從MySQL索引。 它對於搜索和構面非常有用,但是現在我要實現地理空間過濾。 在我運行的管理界面中,

http://mysite:8983/solr/core/select?q=*%3A*&wt=json&indent=true&defType=edismax&spatial=true&pt=44.8859987%2C-93.0833396&sfield=org_loc&d=50

架構:

 <field name="org_loc" type="location" indexed="true" stored="true"/>
 <fieldType name="location" class="solr.LatLonType" subFieldSuffix="_coordinate"/>

響應:

{
    "responseHeader":{
    "status":0,
    "QTime":13,
    "params":{
        "lowercaseOperators":"true",
        "d":"50",
        "spatial":"true",
        "indent":"true",
        "q":"*:*",
        "sfield":"org_loc",
        "pt":"44.8859987,-93.0833396",
        "stopwords":"true",
        "wt":"json",
        "defType":"edismax"}},
    "response":{"numFound":21,"start":0,"docs":[
      "org_name": "..."
      "org_loc":"44.8259987,-93.0813396",
      ...etc.

問題在於,無論d如何,每次都會返回21個記錄中的21個。

必須使用fq參數明確要求geofilt ,這部分查詢丟失了:

&fq={!geofilt}

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM