I parsed a csv through logstash and saved the data in elastic search. Now I have to condition to search like below.
((column08=Submit & column10=Delivered & column09=Something) | (column12=SMSC_No_error & column56=DEV))
As from page "https://www.elastic.co/guide/en/elasticsearch/guide/current/combining-filters.html"
I written the code as
GET /ramya_testing/_search { "query": { "constant_score": { "filter": { "bool": { "should":[ { "bool":{ "must":[ {"term":{"column08":"Submit"}}, {"term":{"column10":"Delivered"}}, {"term":{"column09":"Something"}} ] } }, { "bool":{ "must":[ {"term":{"column12":"SMSC_No_error"}}, {"term":{"column56":"DEV"}} ] } } ] } }, "boost": 1.2 } } }
This is my condition. Is it the good way to write or any better ways???