lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Watkins <rwatk...@foo-bar.org>
Subject Re: wildcards within a phrase query
Date Wed, 12 Oct 2005 22:48:42 GMT
Thank you, Daniel. Once I get an environment suitable enough I will
certainly give this a whirl.

-- Robert

On Wed, 12 Oct 2005, Daniel Naber wrote:

> On Mittwoch 12 Oktober 2005 17:18, Robert Watkins wrote:
>
>> Does that sound reasonable -- and scalable -- to you?
>
> I don't think you need to iterate at all, you can easily expand the terms
> of a query:
>
>    QueryParser qp = new QueryParser("f", new StandardAnalyzer());
>    Query q = qp.parse("e*");
>    IndexReader ir = IndexReader.open("/tmp/index");
>    System.out.println(q.rewrite(ir));
>
> This will expand e* to all of your indice's words that start with "e". Same
> for wildcard queries.
>
> I'll leave the guessing about performance to others. Why not just give it a
> try when it's so easy?
>
> Regards
> Daniel
>
> -- 
> http://www.danielnaber.de

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


Mime
View raw message