【问题标题】:Faceted Search with Solrnet使用 Solrnet 进行分面搜索
【发布时间】:2015-05-06 23:33:12
【问题描述】:

喜欢 Solrnet,太棒了。

我已经成功创建了一个返回构面的 Solrnet 搜索。

articles = solr.Query(new SolrQuery(sQuery), new QueryOptions
        {
        Facet = new FacetParameters
        {
          Queries = new[] { new SolrFacetFieldQuery("content_type") }
        },
        Highlight = new HighlightingParameters
        {
          Fields = new[] { "description" },
          Snippets = 4,
          MaxAnalyzedChars = 10000,
        },
        Rows = sr.recordsPerPage,
        Start = pageI,
   });

现在我需要在用户单击单个构面时执行 Solrnet 搜索,然后随着结果变窄,他们继续单击更多构面? Solrnet API 是如何做到的?你使用过滤器吗?

【问题讨论】:

标签: solrnet facets


【解决方案1】:

我为以下每个字段构建查询字符串...

Queries = new[] { 
   new SolrFacetFieldQuery("content_type"), 
   new SolrFacetFieldQuery("subject"), new SolrFacetFieldQuery("category"), 
   new SolrFacetFieldQuery("timestamp")
},

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-05-12
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多