lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Duval <du...@aps.org>
Subject phrase query not working in boolean clause
Date Wed, 09 Jun 2004 16:25:29 GMT

Hello,

I'm using lucene 1.4 rc2 and I've come across a problem using exact 
phrase queries as
part of a composite query.

A little background on the problem:

We have two fields in the index:
    title:  Field.Text (tokenized)
    journal: Field.Keyword

When doing an exact phrase query on the title the expected results are 
returned:

    +(title:"Mass Asymmetry")
       after tokenizing/filtering:  +title:"mass asymmetri"
    returns 20 Hits
    example hit: "Mass asymmetry, equation of state, and nuclear 
multifragmentation"

When attempting to confine the results to a particular journal the query 
used is:
    +(journal:L) +(title:"Mass Asymmetry")
       after t/f :  +journal:L +title:"mass asymmetri"

    returns 315 Hits!!
    example hit 1:  Towards dynamical mass calculations
    example hit 2:  Up down-asymmetric gravitational fields of spinning 
masses

It would seem that the search engine is treating
    +title:"mass asymmetri"  as +title:mass asymmetri

However, this behavior is only apparent on composite queries as shown 
previously.

For a sanity check I built the query using both the standard query 
parser and
the lucene search api (TermQuery, PhraseQuery, BooleanQuery).   The results
were the same both ways.

Is this a well known limitation of the lucene search engine?  Is there a 
different
means of obtaining the desired results?

Any help with this problem would be greatly appreciated.

Thanks in advance,

Mike Duval
   

-- 
Michael R. Duval   <duval@aps.org >
E-Journal Programmer/Analyst
The American Physical Society
1 Research Road
Ridge, NY 11961

www.aps.org
631 591 4127



---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org


Mime
View raw message