lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pulkit Singhal <>
Subject How to combine QueryParser and Wildcard search
Date Thu, 18 Nov 2010 15:36:50 GMT

I was wondering if there is any API call in Lucene that allows
something like the following:

Step 1: Take the user input
"hello world" you are beautiful

Step 2: QueryParser does its thing
defaultField:hello world defaultField:you defaultField:are

Step 3: And somehow a desired transformation like the following one is
the next thing to happen:
defaultField:hello world defaultField:you* defaultField:are*

How can I tell QueryParser to throw in the wildcard "*" expression
where applicable?

You can see that I'm not expecting it to use "*" with something that
will turn into a phrase query:
"hello world" becomes defaultField:hello world
Just the rest of the tokens:
defaultField:you* defaultField:are* defaultField:beautiful*


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message