Elasticsearch query to find occurrences of some word in message

"hits": [
{
"_index": "filebeat-2016.05.06",
"_type": "log",
"_id": "AVSFCkQD9VvAndW3DfOv",
"_score": 1,
"_source": {
"message": "javax.mail.internet.AddressException: Missing local name in string ``@gmail.com''",
"@version": "1",
"@timestamp": "2016-05-06T07:48:38.986Z",
"beat": {
"hostname": "akash",
"name": "akash"
},
"count": 1,
"fields": null,
"input_type": "log",
"offset": 0,
"source": "c:\Users\akashsoni\Downloads\k\Test\new 1.log",
"type": "log",
"host": "akash",
"tags": [
"beats_input_codec_plain_applied"
],
"message_type": "Exception"
}
--------------------------------------------------------------------------------------------------------------------------------------------------Hi,
My question is how to find out the occurrences of "Missing local name in string" ,which is present in message.Number of count that how many time this word is in my elasticsearch database.

Or presented in my particular index.

You can run a simple query for this - https://www.elastic.co/guide/en/elasticsearch/reference/2.3/search-search.html - or maybe a count query - https://www.elastic.co/guide/en/elasticsearch/reference/2.3/search-count.html

Not working sir ,

GET /filebeat-2016.05.10/_count
{
"query" : {
"term" : { "message": "javax.mail.internet.AddressException: Missing local name in string ``@gmail.com''" }
}
}

output:
{
"count": 0,
"_shards": {
"total": 5,
"successful": 5,
"failed": 0
}
}

{
"took": 2,
"timed_out": false,
"_shards": {
"total": 5,
"successful": 5,
"failed": 0
},
"hits": {
"total": 3,
"max_score": 1,
"hits": [
{
"_index": "filebeat-2016.05.10",
"_type": "log",
"_id": "AVSZY2wJpqVzoumUKIdO",
"_score": 1,
"_source": {
"message": "javax.mail.internet.AddressException: Missing local name in string ``@gmail.com''",
"tags": [
"_jsonparsefailure",
"beats_input_codec_json_applied"
],
"@version": "1",
"@timestamp": "2016-05-10T06:38:25.899Z",
"beat": {
"hostname": "akash",
"name": "akash"
},
"count": 1,
"fields": null,
"input_type": "log",
"offset": 0,
"source": "c:\Users\akashsoni\Downloads\k\Test\new 1.log",
"type": "log",
"host": "akash",
"message_type": "Exception"
}
},