SpanFirstQuery is the clean option. Another option is to add a "start
token" to each title. Then, search for "startToken oil spill". This
will be faster than SpanFirstQuery. But it also requires doing
something weird to the field.
Lance
On Thu, Jun 17, 2010 at 3:19 PM, Michael McCandless
wrote:
SpanFirstQuery?
Mike
On Thu, Jun 17, 2010 at 3:23 PM, rakesh rakesh wrote:
> Hi,
>
> I have thousands of article titles in lucene index. So for a query "Oil
> spill" I want to return all the article title starts with "Oil spill". I do
> not want those titles which has this phrase but do not star
Hi,
I have thousands of article titles in lucene index. So for a query "Oil
spill" I want to return all the article title starts with "Oil spill". I do
not want those titles which has this phrase but do not start with this.
Can anyone help me.
Thanks in advance
Thanks
rakesh