You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Bruno Mannina <bm...@free.fr> on 2012/07/06 15:43:15 UTC
How to Request several docs ?
Dear Solr users,
I would like to request/get several docs indexed by solr with only one
request.
I have a schema.xml where my field PN is the key field (unique key), I
have more than 80M docs in my index.
I have a list of PN that I want to get and I don't want to do one
request by PN and I think it's not clean to do
PN1 or PN2 or PN3 or .....
Is it possible to do a request with PN1, PN2, PN3, etc... PNn
Where "n" can be 20 or 30 by example.
Thanks a lot,
Bruno
Re: How to Request several docs ?
Posted by Paul Libbrecht <pa...@hoplahup.net>.
Le 6 juil. 2012 à 15:43, Bruno Mannina a écrit :
> I have a list of PN that I want to get and I don't want to do one request by PN and I think it's not clean to do
> PN1 or PN2 or PN3 or .....
I've always done this so.
paul
Re: How to Request several docs ?
Posted by Bruno Mannina <bm...@free.fr>.
Le 06/07/2012 19:37, Bruno Mannina a écrit :
> Le 06/07/2012 19:26, Erick Erickson a écrit :
>> It should. So, add &debugQuery=on and examine the results. Also, we
>> should
>> see the field definition and results of the above. You might have
>> your default operator set to AND rather than OR (adding the debug param
>> should make this plain)..
> ok I not yet tested but
>
> <solrQueryParser defaultOperator="AND"/>
>
> ;o)
Changed, Tested and results are here !
Thanks a lot !
Re: How to Request several docs ?
Posted by Bruno Mannina <bm...@free.fr>.
Le 06/07/2012 19:26, Erick Erickson a écrit :
> It should. So, add &debugQuery=on and examine the results. Also, we should
> see the field definition and results of the above. You might have
> your default operator set to AND rather than OR (adding the debug param
> should make this plain)..
ok I not yet tested but
<solrQueryParser defaultOperator="AND"/>
;o)
> If your pn is a "string" type, then it will be case sensitive. I'm
> assuming that you've
> tried it with a single value rather than two, right?
yes with one I have result, I take care about Upper/Lower case
> The admin/schema browser link will allow you to examine the actual contents of
> the field in your index, you might look at your pn field to see what
> the values look
> like there, and if they're what you expect.
>
> Consider reviewing: http://wiki.apache.org/solr/UsingMailingLists, you
> haven't provided much information to go on....
sorry, I will be more explicit if I have a new message.
> Best
> Erick
>
> On Fri, Jul 6, 2012 at 12:43 PM, Bruno Mannina <bm...@free.fr> wrote:
>> Hi Gheeta,
>>
>> Sorry but I don't understand, I suppose uniqueKey for me is "pn" field
>> and (pin1 pin2) are values. but if it's that, it not works.
>>
>> I do:
>> http://localhost:8983/solr/select/?q=pn:%28EP1000000A1%20FR2963608A1%29&version=2.2&start=0&rows=10&indent=on
>>
>> no error but no result !
>>
>>
>> Le 06/07/2012 18:35, geetha anjali a écrit :
>>
>>> Hi Bruno,
>>> Check this
>>> http://localhost:8983/solr/select?q=uniqueKey:(pin1 pin2)
>>>
>>>
>>>
>>> On Fri, Jul 6, 2012 at 7:13 PM, Bruno Mannina <bm...@free.fr> wrote:
>>>
>>>> Dear Solr users,
>>>>
>>>> I would like to request/get several docs indexed by solr with only one
>>>> request.
>>>>
>>>> I have a schema.xml where my field PN is the key field (unique key), I
>>>> have more than 80M docs in my index.
>>>>
>>>> I have a list of PN that I want to get and I don't want to do one request
>>>> by PN and I think it's not clean to do
>>>> PN1 or PN2 or PN3 or .....
>>>>
>>>> Is it possible to do a request with PN1, PN2, PN3, etc... PNn
>>>> Where "n" can be 20 or 30 by example.
>>>>
>>>> Thanks a lot,
>>>> Bruno
>>>>
>>
>
Re: How to Request several docs ?
Posted by Erick Erickson <er...@gmail.com>.
It should. So, add &debugQuery=on and examine the results. Also, we should
see the field definition and results of the above. You might have
your default operator set to AND rather than OR (adding the debug param
should make this plain)..
If your pn is a "string" type, then it will be case sensitive. I'm
assuming that you've
tried it with a single value rather than two, right?
The admin/schema browser link will allow you to examine the actual contents of
the field in your index, you might look at your pn field to see what
the values look
like there, and if they're what you expect.
Consider reviewing: http://wiki.apache.org/solr/UsingMailingLists, you
haven't provided much information to go on....
Best
Erick
On Fri, Jul 6, 2012 at 12:43 PM, Bruno Mannina <bm...@free.fr> wrote:
> Hi Gheeta,
>
> Sorry but I don't understand, I suppose uniqueKey for me is "pn" field
> and (pin1 pin2) are values. but if it's that, it not works.
>
> I do:
> http://localhost:8983/solr/select/?q=pn:%28EP1000000A1%20FR2963608A1%29&version=2.2&start=0&rows=10&indent=on
>
> no error but no result !
>
>
> Le 06/07/2012 18:35, geetha anjali a écrit :
>
>> Hi Bruno,
>> Check this
>> http://localhost:8983/solr/select?q=uniqueKey:(pin1 pin2)
>>
>>
>>
>> On Fri, Jul 6, 2012 at 7:13 PM, Bruno Mannina <bm...@free.fr> wrote:
>>
>>> Dear Solr users,
>>>
>>> I would like to request/get several docs indexed by solr with only one
>>> request.
>>>
>>> I have a schema.xml where my field PN is the key field (unique key), I
>>> have more than 80M docs in my index.
>>>
>>> I have a list of PN that I want to get and I don't want to do one request
>>> by PN and I think it's not clean to do
>>> PN1 or PN2 or PN3 or .....
>>>
>>> Is it possible to do a request with PN1, PN2, PN3, etc... PNn
>>> Where "n" can be 20 or 30 by example.
>>>
>>> Thanks a lot,
>>> Bruno
>>>
>
>
Re: How to Request several docs ?
Posted by Bruno Mannina <bm...@free.fr>.
Hi Gheeta,
Sorry but I don't understand, I suppose uniqueKey for me is "pn" field
and (pin1 pin2) are values. but if it's that, it not works.
I do:
http://localhost:8983/solr/select/?q=pn:%28EP1000000A1%20FR2963608A1%29&version=2.2&start=0&rows=10&indent=on
no error but no result !
Le 06/07/2012 18:35, geetha anjali a écrit :
> Hi Bruno,
> Check this
> http://localhost:8983/solr/select?q=uniqueKey:(pin1 pin2)
>
>
>
> On Fri, Jul 6, 2012 at 7:13 PM, Bruno Mannina <bm...@free.fr> wrote:
>
>> Dear Solr users,
>>
>> I would like to request/get several docs indexed by solr with only one
>> request.
>>
>> I have a schema.xml where my field PN is the key field (unique key), I
>> have more than 80M docs in my index.
>>
>> I have a list of PN that I want to get and I don't want to do one request
>> by PN and I think it's not clean to do
>> PN1 or PN2 or PN3 or .....
>>
>> Is it possible to do a request with PN1, PN2, PN3, etc... PNn
>> Where "n" can be 20 or 30 by example.
>>
>> Thanks a lot,
>> Bruno
>>
Re: How to Request several docs ?
Posted by geetha anjali <an...@gmail.com>.
Hi Bruno,
Check this
http://localhost:8983/solr/select?q=uniqueKey:(pin1 pin2)
On Fri, Jul 6, 2012 at 7:13 PM, Bruno Mannina <bm...@free.fr> wrote:
> Dear Solr users,
>
> I would like to request/get several docs indexed by solr with only one
> request.
>
> I have a schema.xml where my field PN is the key field (unique key), I
> have more than 80M docs in my index.
>
> I have a list of PN that I want to get and I don't want to do one request
> by PN and I think it's not clean to do
> PN1 or PN2 or PN3 or .....
>
> Is it possible to do a request with PN1, PN2, PN3, etc... PNn
> Where "n" can be 20 or 30 by example.
>
> Thanks a lot,
> Bruno
>