From java-dev-return-27083-apmail-lucene-java-dev-archive=lucene.apache.org@lucene.apache.org Mon Sep 01 12:51:58 2008 Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 30816 invoked from network); 1 Sep 2008 12:51:57 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 1 Sep 2008 12:51:57 -0000 Received: (qmail 71306 invoked by uid 500); 1 Sep 2008 12:51:49 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 71284 invoked by uid 500); 1 Sep 2008 12:51:49 -0000 Mailing-List: contact java-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@lucene.apache.org Delivered-To: mailing list java-dev@lucene.apache.org Received: (qmail 71270 invoked by uid 99); 1 Sep 2008 12:51:49 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Sep 2008 05:51:49 -0700 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [192.100.122.233] (HELO mgw-mx06.nokia.com) (192.100.122.233) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Sep 2008 12:50:51 +0000 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx06.nokia.com (Switch-3.2.6/Switch-3.2.6) with ESMTP id m81CopDP006424 for ; Mon, 1 Sep 2008 15:51:18 +0300 Received: from esebh102.NOE.Nokia.com ([172.21.138.183]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 1 Sep 2008 15:50:53 +0300 Received: from esebe108.NOE.Nokia.com ([172.21.138.114]) by esebh102.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 1 Sep 2008 15:50:53 +0300 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C90C31.5E8B944F" Subject: Multi Phrase Search at the Beginning of a field Date: Mon, 1 Sep 2008 15:50:53 +0300 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Multi Phrase Search at the Beginning of a field Thread-Index: AckMMV5C15lumi7YTceoaYiYWNI7kQ== From: To: X-OriginalArrivalTime: 01 Sep 2008 12:50:53.0379 (UTC) FILETIME=[5E6B4930:01C90C31] X-Nokia-AV: Clean X-Virus-Checked: Checked by ClamAV on apache.org ------_=_NextPart_001_01C90C31.5E8B944F Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi, Can some one please help me in providing a solution for my problem: I have a single field defined in my document. Now I want to do a MultiPhraseQuery - but at the beginning of the field.=20 For e.g: If there are 3 documents with single field ( say 'title' ) has the values -> "Hello Love you", "Love You Sister", "Love Yoxyz"=20 Then my search for "Love yo*" -> MultiPhraseQuery with first term "Love" ( using addTerm("Love") and the next terms ( using addTerms("Yo*" - after getting all terms 'You' and 'Yoxyz' using IndexReader.terms(Yo) ) should return only the documents "Love You Sister", "Love Yoxyz" - but not "Hello Love you". Can some one please help me on how to get it done. Regards, Vinay ------_=_NextPart_001_01C90C31.5E8B944F Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Multi Phrase Search at the Beginning of a field

Hi,

Can some one please help me in = providing a solution for my problem:

I have a single field defined in my = document. Now I want to do a MultiPhraseQuery - but at the beginning of = the field.

For e.g: If there are 3 documents with = single field ( say 'title' ) has the values -> "Hello Love = you", "Love You Sister", "Love Yoxyz" =

Then my search for "Love yo*" = ->  MultiPhraseQuery with first term "Love" ( using = addTerm("Love") and the next terms ( using = addTerms("Yo*"  - after getting all terms 'You' and = 'Yoxyz' using IndexReader.terms(Yo) ) should return only the documents = "Love You Sister", "Love Yoxyz" - but not = "Hello Love you".

Can some one please help me on how to = get it done.


Regards,
Vinay

------_=_NextPart_001_01C90C31.5E8B944F--