How to alter ElasticSearch Field name


(Binuraj P Sasidharan) #1

curl -XPUT 'http://myhostname:9200/data/my_data/_mapping' -d '
{
"my_data" : {
"properties" : {
"empID" : {"type" : "integer"},
"empName" : {"type" : "string"}
}
}
}'
so, i want to alter fieldname 'empName' to 'Emp_Name'.whether it is possible,and also i had data existing for this mapping.


(David Pilato) #2

You have to create a new index/mapping and reindex.


(Binuraj P Sasidharan) #3

How copy existing data to new filed? Is that possible?


(system) #4