I have to find all the documents where the size of a certain field, is within a certain limit, in fact within a range. Is there a way to do this Solr. I have tried a lot of permutations and combinations, so any help will be appreciated. Thanks in advance.
Asked
Active
Viewed 104 times
2
-
1I think you can use the method described in this question: http://stackoverflow.com/questions/23270571/string-length-function-query-in-solr . In your case, if you want to find out whether the size of a field is between *m* and *n* characters, you might use `myfield:/.{m,n}/` – David Faber Apr 09 '15 at 18:24
1 Answers
0
Which API are you using to communicate with Solr? I think you have a better chance of going around this on client side (ie on Solrj as a java regex filter function, or if its a web application communicating with solr through a http request this can be done through javascript). I would add this as a comment but I dont have enough rep.

Jorge Lazo
- 388
- 7
- 18