lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Spencer <>
Subject SubstringQuery -- Re: Leading Wild Card Search
Date Thu, 12 Feb 2004 21:45:53 GMT
Kristian Hermsdorf wrote:

> Hi
>> I've written a PrefixQuery and it's not hard to do  -I can post it too.
>> Problem is that it is not integrated into the query parser (.jj) so odds
>> are noone will use it, and the general sentiment on this list (and 
>> lucene-dev)
>> is that prefix queries are evil because it's an expensive operation 
>> as the query
>> code has to traverse all terms to "expand" the query. I would prefer
>> a more user oriented view i.e. just allow it as sometimes it's what 
>> you need and
>> the only alternative I can think of, doing a fuzzy query, isn't quite 
>> right.
> wow - great!
> I'm looking for a sample code for quite a goode time. I'd like to test 
> the performance on our data to see if it's really that slow.

2 files attached, SubstringQuery (which you'll use) and 
SubstringTermEnum ( used by the former to be
consistent w/ other Query code).

I find this kind of query useful to have and think that the query parser 
should allow it in spite of the perception
of this being slow, however I think the debate is the "user centric 
view" (say mine, allow substring queries)
vs the "protect the engines performance" view which says not to allow 
expensive queries.

> It would be great if you could post a URL whrer to find your extension.
> thank you
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

View raw message