that'd be very nice. -----Original Message----- From: Doug Cutting [mailto:[EMAIL PROTECTED]] Sent: 31. oktober 2001 23:37 To: 'Lucene Developers List' Subject: RE: PhrasePrefixQuery
> From: Anders Nielsen [mailto:[EMAIL PROTECTED]] > > I would like to be able to make a search that is like a > phrase-query, except > that the last term in the phrase can be a prefix. > > An example would be a search for > > this is a t* > > which would match the string "this is a test" > > > And I was just wondering if anyone else have made a > PhrasePrefixQuery Class, > before I start making one myself. I don't know of any effort to do this. It would not be too difficult to add a method to PhraseQuery: public void add(Term[]); If you added {"a","b"} and {"x","y"} to a PhraseQuery then it would match any of "a x", "a y", "b x" and "b y", and much more efficiently than a query containing these four phrase queries. It would only traverse the TermPositions for each term once, while the four-phrase version would traverse each four times. If that sounds useful, I can add it to my list of tasks... Doug -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
