You could use a script filter:
"filtered" : {
"query" : {
...
},
"filter" : {
"script" : {
"script" : "doc['subject'].value.length() < 20"
}
}
}
Dan
On Thursday, May 22, 2014 8:45:41 AM UTC+1, David Nielsen wrote:
>
> Hi.
> I am trying to find a way to express a character count filter in a
> querystring, for instance: I need to find all documents with field
> "subject" that holds less than 20 chars.
> How would i do that in a querystring ?
>
> /David
>
--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/9d7cff9d-1449-4635-b780-89ce6102ec77%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.