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 Alok Bhandari <al...@gmail.com> on 2016/01/11 19:25:43 UTC

Solr /export handler is exporting only unique values from multivalued field?

Hello ,

I am using solr /export handler to export search results and it is
performing well.
Today I faced an issue , actually there are 2 multivalued fields I am
fetching lets say <item> which holds list of items and <seller> which holds
list of sellers.

here I am storing information such that seller for 1st item is 1st seller
from seller list , 
item1--1
item2--1
item3--2 

I am expecting these 2 lists of same size.
When I export I get 3 entries in item list but only 2 entries in seller
list. Also these entries are sorted so it is not giving me the expected
results. So I cant find seller for item1,item2....

This is priority for me and I am stuck , please can someone help.

I am using solr 5.2

Thanks,
Alok



--
View this message in context: http://lucene.472066.n3.nabble.com/Solr-export-handler-is-exporting-only-unique-values-from-multivalued-field-tp4249986.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Solr /export handler is exporting only unique values from multivalued field?

Posted by Alok Bhandari <al...@gmail.com>.
Thanks Joel.



--
View this message in context: http://lucene.472066.n3.nabble.com/Solr-export-handler-is-exporting-only-unique-values-from-multivalued-field-tp4249986p4250067.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Solr /export handler is exporting only unique values from multivalued field?

Posted by Joel Bernstein <jo...@gmail.com>.
Perhaps you can achieve what you're trying to do with a prefix on the data
so the sort is maintained and duplicates are not eliminated.

Joel Bernstein
http://joelsolr.blogspot.com/

On Mon, Jan 11, 2016 at 1:42 PM, Joel Bernstein <jo...@gmail.com> wrote:

> The /export handler is using DocValues for export, which stores the
> multi-value fields as a sorted set. So the sorting is the expected
> behavior. If you have duplicates in the multi-value field this could
> account for the list being of different sizes.
>
>
>
> Joel Bernstein
> http://joelsolr.blogspot.com/
>
> On Mon, Jan 11, 2016 at 1:25 PM, Alok Bhandari <
> alokomprakashbhandari@gmail.com> wrote:
>
>> Hello ,
>>
>> I am using solr /export handler to export search results and it is
>> performing well.
>> Today I faced an issue , actually there are 2 multivalued fields I am
>> fetching lets say <item> which holds list of items and <seller> which
>> holds
>> list of sellers.
>>
>> here I am storing information such that seller for 1st item is 1st seller
>> from seller list ,
>> item1--1
>> item2--1
>> item3--2
>>
>> I am expecting these 2 lists of same size.
>> When I export I get 3 entries in item list but only 2 entries in seller
>> list. Also these entries are sorted so it is not giving me the expected
>> results. So I cant find seller for item1,item2....
>>
>> This is priority for me and I am stuck , please can someone help.
>>
>> I am using solr 5.2
>>
>> Thanks,
>> Alok
>>
>>
>>
>> --
>> View this message in context:
>> http://lucene.472066.n3.nabble.com/Solr-export-handler-is-exporting-only-unique-values-from-multivalued-field-tp4249986.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>
>

Re: Solr /export handler is exporting only unique values from multivalued field?

Posted by Joel Bernstein <jo...@gmail.com>.
The /export handler is using DocValues for export, which stores the
multi-value fields as a sorted set. So the sorting is the expected
behavior. If you have duplicates in the multi-value field this could
account for the list being of different sizes.



Joel Bernstein
http://joelsolr.blogspot.com/

On Mon, Jan 11, 2016 at 1:25 PM, Alok Bhandari <
alokomprakashbhandari@gmail.com> wrote:

> Hello ,
>
> I am using solr /export handler to export search results and it is
> performing well.
> Today I faced an issue , actually there are 2 multivalued fields I am
> fetching lets say <item> which holds list of items and <seller> which holds
> list of sellers.
>
> here I am storing information such that seller for 1st item is 1st seller
> from seller list ,
> item1--1
> item2--1
> item3--2
>
> I am expecting these 2 lists of same size.
> When I export I get 3 entries in item list but only 2 entries in seller
> list. Also these entries are sorted so it is not giving me the expected
> results. So I cant find seller for item1,item2....
>
> This is priority for me and I am stuck , please can someone help.
>
> I am using solr 5.2
>
> Thanks,
> Alok
>
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Solr-export-handler-is-exporting-only-unique-values-from-multivalued-field-tp4249986.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>