gpt4 book ai didi

elasticsearch - 麋鹿。找不到嵌套值

转载 作者:行者123 更新时间:2023-12-03 01:17:39 25 4
gpt4 key购买 nike

我有如下的索引映射:

 {
"mapping": {
"properties": {
"MyMapProperty": {
"type": "nested",
"properties": {
"first": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"second": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
}
},
"SecondProperty": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"ThirdProperty": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"Timestamp": {
"type": "date"
}
}
}
}

添加新文档后,其来源如下所示:
{
"_index": "indexName",
"_type": "_doc",
"_id": "idlklkm43rgre",
"_version": 1,
"_score": 0,
"_source": {
"MyMapProperty": {
"first": "value1",
"second": "value2",
},
"SecondProperty": "value3",
"ThirdProperty": "value4",
},
"fields": {
"Timestamp": [
"2020-05-11T12:54:49.049Z"
]
}
}

因此,我在Kibana中看到可用的字段:
MyMapProperty.fist | MyMapProperty.second |第二属性| ThirdProperty

问题是,当我尝试搜索MyMapProperty.fist:value时-它什么也找不到...但是,如果我要搜索SecondProperty:value3-它会返回结果。

我试图了解自己做错了什么,这是kibana问题还是 flex 搜索,或者我正在执行一些奇怪的操作。您能否提一些建议...

最佳答案

在ES 7.6之前,无法在Kibana内搜索嵌套字段。从ES 7.6开始,现在使用特定的搜索语法为possible to do so,如下所示:

MyMapProperty:{ first:value }

您可以尝试一下。

关于elasticsearch - 麋鹿。找不到嵌套值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61750176/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com