No handler for type [string] declared on field [name]

When type is declared as string, Elasticsearch 6.0 will show this error.

"name" => [
"type" => "string",
"analyzer" => "ik_max_word"
]
57183 次浏览

Elasticsearch 已经删除了 string类型,现在使用的是 text

"name" => [
"type" => "text",
"analyzer" => "ik_max_word"
]