I have taken the type of a field in elastic search as double and while ingesting any value which has some 0's after decimal place then the 0's after decimal place is not shown. For example: for value 23.0 is converted to 23
PFB the mapping which I have used:
curl -X PUT "localhost:9200/test" -H 'Content-Type: application/json' -d'
{
"mappings": {
"abc": {
"properties": {
"price": {
"type": "double"
},
"mrp": {
"type": "long"
}
}
}
},
"settings": {
"index.mapping.coerce": false
}
}'
I expect output for 23.0 to be exactly the same which is 23.0 itself and for integer values I also exppect 23 to be converted itself to 23.0 Please provide an appropriate solution.
Using elastic search version 6.5.0