lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Zheng Lin Edwin Yeo <edwinye...@gmail.com>
Subject Re: Sorting for MLT results
Date Sat, 21 May 2016 06:43:19 GMT
Thanks for your reply.

But it didn't work when I execute this query.
http://localhost:8983/solr/collection1/mlt?q=testing&sort=creation_date
desc,id asc&rows=10

This is my configuration for the handler.

<requestHandler name="/mlt" class="solr.MoreLikeThisHandler" > <lst name=
"defaults"> <str name="echoParams">explicit</str> <int name="rows">10</int>
<str name="wt">json</str> <str name="indent">true</str> <str name="defType">
edismax</str> <str name="fl">id, score</str> <!--<str name="mlt.qf">
subject^10.0 content^20.0 </str>--> <str name="df">content</str> <str
name=
"mlt.fl">subject content</str> <str name="mlt.mintf">2</str> <str
name=
"mlt.mindf">5</str> <str name="mlt.minwl">3</str> <str name="mlt.maxqt">25</
str> <str name="mlt.count">10</str> <str name="mlt.boost">false</str>
<str
name="mlt.interestingTerms">details</str> </lst> </requestHandler>

Regards,
Edwin


On 17 May 2016 at 22:35, Alessandro Benedetti <abenedetti@apache.org> wrote:

> using the more like this query parser should solve your problem !
> Just use that query parser and than sort as usual.
>
> Cheers
>
> On Wed, May 11, 2016 at 4:53 AM, Zheng Lin Edwin Yeo <edwinyeozl@gmail.com
> >
> wrote:
>
> > Hi,
> >
> > Would like to check, is there a function to do the sorting for MLT
> results
> > in Solr? I understand that there is a sort function, but that only works
> > for the main query results. It does not do any sorting for the MLT
> results
> >
> > I'm using Solr 5.4.0.
> >
> > Regards,
> > Edwin
> >
>
>
>
> --
> --------------------------
>
> Benedetti Alessandro
> Visiting card : http://about.me/alessandro_benedetti
>
> "Tyger, tyger burning bright
> In the forests of the night,
> What immortal hand or eye
> Could frame thy fearful symmetry?"
>
> William Blake - Songs of Experience -1794 England
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message