Re: Combining several documents in a terms filter

2015-04-23 Thread Bruno Miranda
Is there an upper limit of bool filters?

On Friday, April 17, 2015 at 10:18:38 PM UTC-7, vineeth mohan wrote:
>
> Hello Daniel , 
>
> Feel free to use should clause in bool filter 
> 
> .
> Here you can give multiple terms filter and each of them can point to a 
> different document/field.
>
> Thanks
>Vineeth Mohan,
>Elasticsearch consultant,
>qbox.io ( Elasticsearch service provider )
>
>
> On Sat, Apr 18, 2015 at 3:49 AM, Daniel Nill  > wrote:
>
>> In the example here 
>> http://www.elastic.co/guide/en/elasticsearch/reference/0.90/query-dsl-terms-filter.html#_terms_lookup_twitter_example,
>>  
>> it is indicated that the id field can only be for a single document.  Is 
>> there a way to do:
>>
>> curl -XGET localhost:9200/tweets/_search -d '{
>>   "query" : {
>> "filtered" : {
>>   "filter" : {
>> "terms" : {
>>   "user" : {
>> "index" : "users",
>> "type" : "user",
>> "id" : ["2", "3", "4"],
>> "path" : "followers"
>>   },
>>   "_cache_key" : "user_2_friends"
>> }
>>   }
>> }
>>   }
>> }'
>>
>>
>> Is the only way to get results for this to do a separate terms filter for 
>> each id?
>>
>> -- 
>> 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 elasticsearc...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/elasticsearch/d8032d4a-fdb7-48c9-9828-64253c5d4b90%40googlegroups.com
>>  
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
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 elasticsearch+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/835275d7-ab86-41f1-b149-a7d644120bed%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Combining several documents in a terms filter

2015-04-17 Thread vineeth mohan
Hello Daniel ,

Feel free to use should clause in bool filter

.
Here you can give multiple terms filter and each of them can point to a
different document/field.

Thanks
   Vineeth Mohan,
   Elasticsearch consultant,
   qbox.io ( Elasticsearch service provider )


On Sat, Apr 18, 2015 at 3:49 AM, Daniel Nill  wrote:

> In the example here
> http://www.elastic.co/guide/en/elasticsearch/reference/0.90/query-dsl-terms-filter.html#_terms_lookup_twitter_example,
> it is indicated that the id field can only be for a single document.  Is
> there a way to do:
>
> curl -XGET localhost:9200/tweets/_search -d '{
>   "query" : {
> "filtered" : {
>   "filter" : {
> "terms" : {
>   "user" : {
> "index" : "users",
> "type" : "user",
> "id" : ["2", "3", "4"],
> "path" : "followers"
>   },
>   "_cache_key" : "user_2_friends"
> }
>   }
> }
>   }
> }'
>
>
> Is the only way to get results for this to do a separate terms filter for
> each id?
>
> --
> 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 elasticsearch+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/elasticsearch/d8032d4a-fdb7-48c9-9828-64253c5d4b90%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 elasticsearch+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DPmPFdhK6bUhT6WYxWMZtZWAJGNDc8VJF-8tC1z%3Dy7Uw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.