lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From peter360 <>
Subject dismax handler and WordDelimiterFilterFactory
Date Wed, 21 May 2008 18:35:28 GMT


Let's say I have an index with two fields: f1 and f2, and queries to both
are analyzed using WhiteSpaceTokenizerFactory and
WordDelimiterFilterFactory.  I use dismax handler for queries and observed
the following anomally.

Suppose I have a document with f1="american" and f2="idol".  Then a search
"q=american+idol&qt=dismax&qf=f1+f2" matches.  However, the search
"q=american-idol&qt=dismax&qf=f1+f2" does not, even though the analyzer
(WordDelimiterFilterFactory) turns "american-idol" into "american idol".

Upon closer look, the dismax handler is parsing the first query as something
+(f1:american f2:american) +(f1:idol f2:idol)
while parsing the second as something like
f1:"american idol" f2:"american idol"

I feel this is an anormaly because from end user point of view american-idol
should be treated the same as american idol.  How do I achieve this?  One
possible solution is to index f1 and f2 as one field, but I want to be able
to give separate boosts to them, such as "qf=f1^2+f2".  Any ideas?  Do
people feel this is a bug in the dismax handler?

View this message in context:
Sent from the Solr - User mailing list archive at

View raw message