首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Elastic4s -如何表达"matched_fields“

Elastic4s -如何表达"matched_fields“
EN

Stack Overflow用户
提问于 2015-06-14 08:08:34
回答 1查看 221关注 0票数 1

我想在Elastic4s中实现以下查询。看不到在荧光笔中实现matched_fields子句的任何方法。有什么帮助吗?

代码语言:javascript
复制
{
  "query": {
    "multi_match": {
      "type": "most_fields",
      "query": "hello world",
      "fields": [ "text", "text.human" ]
    }
  },
  "highlight": {
    "order": "score",
    "fields": {
      "text": {
        "matched_fields": [ "text", "text.human" ],
        "fragment_size": 100,
        "number_of_fragments": 10
      }
    }
  }
}
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2015-06-14 19:43:25

一个答案很简单的问题。您还不能在elastic4s中这样做:)

所以,我刚加了一句:https://github.com/sksamuel/elastic4s/commit/3f8a4e47ae603b7a3263bc3d31c27f2b6706cd8e

这将出现在下一个1.5.x版本和1.6.0版本中。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/30827214

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档