【发布时间】:2016-11-29 22:24:18
【问题描述】:
我在 ES 中做了如下映射:
curl -XPOST http://localhost:9200/developer/document/_mapping -d '
{
"document" : {
"properties" : {
"content" : {
"type" : "string",
"analyzer": "ik_max_word",
"search_analyzer": "ik_max_word",
"copy_to":"single_word_content"
},
"ID" : {
"type" : "string"
},
"title" : {
"type" : "string",
"analyzer": "ik_max_word",
"search_analyzer": "ik_max_word",
"copy_to":"single_word_content"
},
"single_word_content":{
"type": "string",
"analyzer":"standard",
}
}
}
}'
然后我在 ES 中插入一个 without single_word_content 字段的文档。 当我从 ES 搜索时,搜索结果中没有返回 single_word_content 字段,并且突出显示也不适用于 single_word_content 字段
【问题讨论】:
标签: elasticsearch