Hi,
i am using value count aggragtion and with the script, pfb the script
"script": {
"lang": "painless",
"source": "for(int i=0; i<1; i++){if(doc['message.code'].size() >0 && doc['message.code'].value >= 300){doc['message.code'].value}}"
}
it is showing error as invalid argument exception. if i remove the for loop it is giving result but it will not give the expected result.
can some please help on this