Hi all,
I'm trying to display average of a field in visualization bucket.
But when i use below code in inline text of advanced JSON for an integer value, I dont get.
I dont want decimal values.
{
"script": {
"inline":"Math.round(doc['DC_AMOUNT'].value * 100.0)/100.0",
"lang": "painless"
}
}
It works for buckets when i round off values.
But when i take an average of fields and try to implement, it does'nt work.
Any help