Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ssis/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
<img src="//i.stack.imgur.com/RUiNP.png" height="16" width="18" alt="" class="sponsor tag img">elasticsearch 类型关键字和未分析的关键字有什么区别?_<img Src="//i.stack.imgur.com/RUiNP.png" Height="16" Width="18" Alt="" Class="sponsor Tag Img">elasticsearch - Fatal编程技术网 elasticsearch 类型关键字和未分析的关键字有什么区别?,elasticsearch,elasticsearch" /> elasticsearch 类型关键字和未分析的关键字有什么区别?,elasticsearch,elasticsearch" />

elasticsearch 类型关键字和未分析的关键字有什么区别?

elasticsearch 类型关键字和未分析的关键字有什么区别?,elasticsearch,elasticsearch,“”字段类型与在Elasticsearch中使用“”作为分析器的字段之间是否有任何区别?如果有,何时使用哪个?如文档中所示,关键字数据类型是ES 5中出现的新数据类型。它旨在将字符串字段替换为“索引”:“未分析” 所以在ES1.x和2.x中,这个声明 "field": { "type": "string", "index": "not_analyzed" } "field": { "type": "string" } 等同于ES 5中的此声明 "field": {

“”字段类型与在Elasticsearch中使用“”作为分析器的字段之间是否有任何区别?如果有,何时使用哪个?

如文档中所示,
关键字
数据类型是ES 5中出现的新数据类型。它旨在将
字符串
字段替换为
“索引”:“未分析”

所以在ES1.x和2.x中,这个声明

"field": {
    "type": "string",
    "index": "not_analyzed"
}
"field": {
    "type": "string"
}
等同于ES 5中的此声明

"field": {
    "type": "keyword"
}
"field": {
    "type": "text"
}
类似地,
text
数据类型将替换正常分析的字符串字段,因此在ES 1.x和2.x中,此声明

"field": {
    "type": "string",
    "index": "not_analyzed"
}
"field": {
    "type": "string"
}
将等同于ES 5中的此声明

"field": {
    "type": "keyword"
}
"field": {
    "type": "text"
}

更新了突破性变化的链接:这是一个精彩的解释。ES团队应该明确提到这一点。