lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Robinson <mark123lea...@gmail.com>
Subject Re: SOLR edismax and mm request parameter
Date Wed, 04 May 2016 10:18:03 GMT
Thanks for the mail Jaques.
I have a doubt here.

When we use q.op=AND what I understood is, ALL query terms should be
present any where across the various "qf" fields ie all of the query terms
need not be present in one single field, but just need to be present for
sure among the various qf fields.

My requirement is I need *ALL query terms* to be present in at least *any
one of the qf fields* for a doc to qualify.
So not sure whether q.op=AND will help me.

Pls correct me if I am missing something.

Thanks!
Mark.



On Wed, May 4, 2016 at 5:57 AM, Jacques du Rand <jacques@pricecheck.co.za>
wrote:

> Sorry I meant "Ahmet Arslan" answer :)
>
>
> On 4 May 2016 at 11:56, Jacques du Rand <jacques@pricecheck.co.za> wrote:
>
> > Although Mark Robinson's answer is correct you are now using the DISMAX
> > not the Edismax parser...
> > You can also play around with changing  q.op parameter  to 'AND'
> >
> >
> >
> > On 4 May 2016 at 11:40, Mark Robinson <mark123learns@gmail.com> wrote:
> >
> >> Thanks much Ahmet!
> >>
> >> I will try that out.
> >>
> >> Best,
> >> Mark
> >>
> >> On Tue, May 3, 2016 at 11:53 PM, Ahmet Arslan <iorixxx@yahoo.com.invalid
> >
> >> wrote:
> >>
> >> > Hi Mark,
> >> >
> >> > You could do something like this:
> >> >
> >> > _query_:{!dismax qf='field1' mm='100%' v=$qq}
> >> > OR
> >> > _query_:{!dismax qf='field2' mm='100%' v=$qq}
> >> > OR
> >> > _query_:{!dismax qf='field3' mm='100%' v=$qq}
> >> >
> >> >
> >> >
> >> >
> >>
> https://cwiki.apache.org/confluence/display/solr/Local+Parameters+in+Queries
> >> >
> >> > Ahmet
> >> >
> >> >
> >> >
> >> > On Wednesday, May 4, 2016 4:59 AM, Mark Robinson <
> >> mark123learns@gmail.com>
> >> > wrote:
> >> > Hi,
> >> > On further checking cld identify that *blue *is indeed appearing in
> one
> >> of
> >> > the qf fields.My bad!
> >> >
> >> > Cld someone pls help me with the 2nd question.
> >> >
> >> > Thanks!
> >> > Mark.
> >> >
> >> >
> >> >
> >> > On Tue, May 3, 2016 at 8:03 PM, Mark Robinson <
> mark123learns@gmail.com>
> >> > wrote:
> >> >
> >> > > Hi,
> >> > >
> >> > > I made a typo err in the prev mail for my first question when I
> listed
> >> > the
> >> > > query terms.
> >> > > Let me re-type both questions here once again pls.
> >> > > Sorry for any inconvenience.
> >> > >
> >> > > 1.
> >> > > My understanding of the mm parameter related to edismax is that,
> >> > > if mm=100%,  only if ALL my query terms appear across any of the qf
> >> > fields
> >> > > will I get back
> >> > > documents ... ie all the terms *need not be present in one single
> >> field*
> >> > ..
> >> > > they just need to be present across any of the fields in my qf list.
> >> > >
> >> > > But my query for  the terms:-
> >> > > *blue stainless washer*
> >> > > ... returns a document which has *Stainless Washer *in one of my qf
> >> > > fields, but *blue *is not there in any of the qf fields. Then how
> did
> >> it
> >> > > get returned even though I had given mm=100% (100%25 when I typed
> >> > directly
> >> > > in browser). Any suggestions please.. In fact this is my first
> record!
> >> > >
> >> > > 2.
> >> > > Another question I have is:-
> >> > > With edismax can I enforce that all my query terms should appear in
> >> ANY
> >> > of
> >> > > my qf fields to qualify as a result document? I know all terms
> >> appearing
> >> > in
> >> > > a single field can give a boost if we use the "pf" query parameter
> >> > > accordingly. But how can I insist that to qualify as a result, the
> doc
> >> > > should have ALL of my query term in one or more of the qf fields?
> >> > >
> >> > >
> >> > > Cld some one pls help.
> >> > >
> >> > > Thanks!
> >> > >
> >> > > Mark
> >> > >
> >> > > On Tue, May 3, 2016 at 6:28 PM, Mark Robinson <
> >> mark123learns@gmail.com>
> >> > > wrote:
> >> > >
> >> > >> Hi,
> >> > >>
> >> > >> 1.
> >> > >> My understanding of the mm parameter related to edismax is that,
> >> > >> if mm=100%,  only if ALL my query terms appear across any of the
qf
> >> > >> fields will I get back
> >> > >> documents ... ie all the terms *need not be present in one single
> >> field*
> >> > >> .. they just need to be present across any of the fields in my
qf
> >> list.
> >> > >>
> >> > >> But my query for  the terms:-
> >> > >> *blue stainless washer*
> >> > >> ... returns a document which has *Stainless Washer *in one of
my qf
> >> > >> fields, but *refrigerator *is not there in any of the qf fields.
> Then
> >> > >> how did it get returned even though I had given mm=100% (100%25
> when
> >> I
> >> > >> typed directly in browser). Any suggestions please.
> >> > >>
> >> > >> 2.
> >> > >> Another question I have is:-
> >> > >> With edismax can I enforce that all my query terms should appear
in
> >> ANY
> >> > >> of my qf fields to qualify as a result document? I know all terms
> >> > appearing
> >> > >> in a single field can give a boost if we use the "pf" query
> parameter
> >> > >> accordingly. But how can I insist that to qualify as a result,
the
> >> doc
> >> > >> should have ALL of my query term in one or more of the qf fields?
> >> > >>
> >> > >>
> >> > >> Cld some one pls help.
> >> > >>
> >> > >> Thanks!
> >> > >> Mark.
> >> > >>
> >> > >
> >> > >
> >> >
> >>
> >
> >
> >
> > --
> > Jacques du Rand
> > Senior R&D  Programmer
> >
> > T: +27214688017
> > F: +27862160617
> > E: jacques@pricecheck.co.za
> > <
> https://mail.naspers.com/owa/redir.aspx?SURL=uQ0aY47BwKkgYjLPs4CuWJgrQlRUZlf73Ere0TGrauf5NrymvPnSCG0AYQBpAGwAdABvADoAagBhAGMAcQB1AGUAcwBAAHAAcgBpAGMAZQBjAGgAZQBjAGsALgBjAG8ALgB6AGEA&URL=mailto%3ajacques%40pricecheck.co.za
> >
> >
>
>
>
> --
> Jacques du Rand
> Senior R&D  Programmer
>
> T: +27214688017
> F: +27862160617
> E: jacques@pricecheck.co.za
> <
> https://mail.naspers.com/owa/redir.aspx?SURL=uQ0aY47BwKkgYjLPs4CuWJgrQlRUZlf73Ere0TGrauf5NrymvPnSCG0AYQBpAGwAdABvADoAagBhAGMAcQB1AGUAcwBAAHAAcgBpAGMAZQBjAGgAZQBjAGsALgBjAG8ALgB6AGEA&URL=mailto%3ajacques%40pricecheck.co.za
> >
>

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