Skip to content

Instantly share code, notes, and snippets.

@clintongormley
Created January 9, 2012 16:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save clintongormley/c85de1c55e0e611c3f15 to your computer and use it in GitHub Desktop.
Save clintongormley/c85de1c55e0e611c3f15 to your computer and use it in GitHub Desktop.
curl -XGET 'http://127.0.0.1:9200/_all/_search?pretty=1' -d '
{
"query" : {
"filtered" : {
"filter" : {
"and" : [
{
"or" : [
{
"terms" : {
"readAccessGroupAccessBits" : [
"1",
2,
4,
64,
524288
]
}
},
{
"term" : {
"readAccessAccounts" : 203
}
}
]
},
{
"not" : {
"filter" : {
"term" : {
"category.categoryTypeID" : 105
}
}
}
}
]
},
"query" : {
"custom_filters_score" : {
"query" : {
"query_string" : {
"fields" : [
"message^1",
"subject^3"
],
"query" : "jboss ssl install",
"analyzer" : "snowball"
}
},
"filters" : [
{
"boost" : 2,
"filter" : {
"range" : {
"lastPostDate" : {
"gte" : "2011-01-01"
}
}
}
}
]
}
}
}
}
}
'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment