Skip to content

Instantly share code, notes, and snippets.

@soumyamrs
Created November 21, 2012 11:35
Show Gist options
  • Save soumyamrs/4124453 to your computer and use it in GitHub Desktop.
Save soumyamrs/4124453 to your computer and use it in GitHub Desktop.
{
"from": "0",
"size": "100",
"query": {
"bool": {
"must": [
{
"bool": {
"must": [
{
"query_string": {
"query": "official",
"default_field":"Content"
}
},
{
"range": {
"actualTimeStamp": {
"from": "08-04-2011 23:37:06",
"to": "16-11-2012 00:00:00"
}
}
}
]
}
},
{
"bool": {
"should": [
{
"fuzzy": {
"SourceName": {
"value": "reuters"
}
}
},
{
"fuzzy": {
"SourceName": {
"value": "economic_times"
}
}
},
{
"fuzzy": {
"SourceName": {
"value": "cnn"
}
}
},
{
"fuzzy": {
"SourceName": {
"value": "bloomberg"
}
}
}
]
}
}
]
}
},
"highlight": {
"fields": {
"Content": {
"fragment_size":"10"
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment