RE: Need help : SpanNearQuery

2009-04-17 Thread Steven A Rowe
Hi Radha, On 4/17/2009 at 6:19 AM, Radhalakshmi Sreedharan wrote: > What I need is the following : > If my document field is ( ab,bc,cd,ef) and Search tokens are > (ab,bc,cd). > > Given the following : > I should get a hit even if all of the search tokens aren't present > If the tokens are f

RE: Need help : SpanNearQuery

2009-04-17 Thread Steven A Rowe
On 4/17/2009 at 10:33 AM, Radhalakshmi Sreedharan wrote: > > > I have a question related to SpanNearQuery. > > > > > > As of now, the SpanNearQuery has the constraint that all the > > > terms need to present in the document. [...] > > > But [...] I need a hit even if there are 2/3 terms found with

Re: Need help : SpanNearQuery

2009-04-17 Thread Paul Elschot
On Friday 17 April 2009 16:33:27 Radhalakshmi Sreedharan wrote: > Thanks Paul. Is there any alternative way of implementing this requirement? Start from scratch perhaps? Anyway, spans can be really tricky, so in case you're writing code for this, I have only four advices: test, test, test and test

RE: Need help : SpanNearQuery

2009-04-17 Thread Radhalakshmi Sreedharan
To: java-user@lucene.apache.org Subject: Re: Need help : SpanNearQuery To avoid passing all combinations to a NearSpansQuery some non trivial changes would be needed in the spans package. NearSpansUnOrdered (and maybe also NearSpansOrdered) would have to be extended to provide matching Spans when

Re: Need help : SpanNearQuery

2009-04-17 Thread Paul Elschot
e. > > I even overrode the queryNorm method to return a one, still the percentage > did not increase. > > Any suggestions ? > -Original Message- > From: Radhalakshmi Sreedharan [mailto:radhalakshm...@infosys.com] > Sent: Friday, April 17, 2009 12:37 PM > To:

RE: Need help : SpanNearQuery

2009-04-17 Thread Radhalakshmi Sreedharan
e.org Subject: RE: Need help : SpanNearQuery Hi Steven, Thanks for your reply. I tried out your approach and the problem got solved to an extent but still it remains. The problem is the score reduces quite a bit even now as bc is not found in the combinations ( bc,cd) ( bc,ef) and ( ab,bc,

RE: Need help : SpanNearQuery

2009-04-17 Thread Radhalakshmi Sreedharan
(SearchField: cd=1 ef=1) 1.0 = fieldNorm(field=SearchField, doc=0) Regards, Radha -Original Message- From: Steven A Rowe [mailto:sar...@syr.edu] Sent: Thursday, April 16, 2009 10:35 PM To: java-user@lucene.apache.org Subject: RE: Need help : SpanNearQuery Hi Radha, On 4/16/2009 at 8

RE: Need help : SpanNearQuery

2009-04-16 Thread Steven A Rowe
Hi Radha, On 4/16/2009 at 8:35 AM, Radhalakshmi Sredharan wrote: > I have a question related to SpanNearQuery. > > I need a hit even if there are 2/3 terms found with the span being > applied for those 2 terms. > > Is there any custom implementation in place for this? I checked > SrndQuery but t

Need help : SpanNearQuery

2009-04-16 Thread Radhalakshmi Sreedharan
Hi , I have a question related to SpanNearQuery. As of now, the SpanNearQuery has the constraint that all the terms need to present in the document. Eg : If my SpanNearQuery terms are ( ab,bc,cd) all of them need to be found within a span of "n" and unordered. But my requirement is similar t