Reputation: 3183
I am trying to use a field for only copying purpose and not to index itself with below mapping
"Line2": {
"type": "text",
"copy_to": "AllFields" ,
"enabled": false
}
But getting exception
{"error":{"root_cause":[{"type":"mapper_parsing_exception","reason":"Mapping definition for [Line2] has unsupported parameters: [enabled : false]"}],"type":"mapper_parsing_exception","reason":"Failed to parse mapping [_doc]: Mapping definition for [Line2] has unsupported parameters: [enabled : false]","caused_by":{"type":"mapper_parsing_exception","reason":"Mapping definition for [Line2] has unsupported parameters: [enabled : false]"}},"status":400}
Can this be done ?
ES version : 6.7
Upvotes: 1
Views: 614
Reputation: 7854
If you don't want to index (make searchable) a field use "index": false
for the field.
"Line2": {
"type": "text",
"copy_to": "AllFields",
"index": false
}
Upvotes: 2