Well, if you can write a custom function that does the right thing
with multiValued fields you could sort by that.

You still haven't defined the exact use case. The problem here is
that sorting by a multiValued field is meaningless. Consider a
field with aardvark and zebra. Where should it sort? Of course you
can define rules like "the minimum value of the field", which will at
least give consistent results... until the next person wants to sort
by the average of all the numbers in a field.


On Sat, Nov 8, 2014 at 5:32 AM, Yago Riveiro <yago.rive...@gmail.com> wrote:
> Re-index data is bad for me, it's 5TB of data, the time to re-index this
> data it's too much, but seem to be the only option I have.
>
>
> On Sat 8 Nov 2014 at 13:10 Anurag Sharma <anura...@gmail.com> wrote:
>
>> Is it possible to describe the exact use case here.
>>
>> On Fri, Nov 7, 2014 at 10:26 PM, Alexandre Rafalovitch <arafa...@gmail.com
>> >
>> wrote:
>>
>> > You encode that knowledge by using UpdateRequestProcessor. Clone the
>> > field, replace it with true, map it to boolean. That way, you will pay
>> > the price once per document indexed not (documentCount*) times per
>> > request.
>> >
>> > Regards,
>> >   Alex.
>> > Personal: http://www.outerthoughts.com/ and @arafalov
>> > Solr resources and newsletter: http://www.solr-start.com/ and @solrstart
>> > Solr popularizers community: https://www.linkedin.com/groups?gid=6713853
>> >
>> >
>> > On 7 November 2014 06:43, Nickolay41189 <klin892...@yandex.ru> wrote:
>> > > I want to sort by multivalued field like boolean values.
>> > > Something like that:
>> > > *sort exist(multivalued field name) desc*
>> > >
>> > > Is it possible?
>> > >
>> > > P.S. I know that sorting doesn't work for multivalued fields, but it
>> work
>> > > for single boolean field...
>> > >
>> > >
>> > >
>> > > --
>> > > View this message in context:
>> > http://lucene.472066.n3.nabble.com/Sort-documents-by-
>> exist-multivalued-field-tp4168141.html
>> > > Sent from the Solr - User mailing list archive at Nabble.com.
>> >
>>

Reply via email to