On 06/01/2006, at 9:33 AM, Chris Hostetter wrote:
: Think SQL of " ....where title like 'The quick%' ".
I solved this problem by having a variation of my field that was not
tokenized, and did PrefixQueries on that field (so in your case, leave
your title field alone for generic matches, and have a
titleUntokenized
field for PrefixMatches.
Thanks Chris, I had thought of that one, but unfortunately the title
could be quite long, and there are literally millions of documents.
Isn't each title going to be included as one "term" in the index
dictionary? If so, won't the index get ridiculously large and slow?
Another approach i have not tried that should work as long as your
"starts
with" input is allways whole Terms (ie: "The quick %" and not "The
qu%")
is to use a SpanFirstQuery wrapped arround a a SpanNearQuery
containing
successive SpanTermQueries with no slop.
ooh err, Span queries, I'd better go have a look at them.
thanks,
Paul
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]