lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <erickerick...@gmail.com>
Subject Re: Tokenized fields in Lucene 3.0.0
Date Tue, 15 Dec 2009 21:42:15 GMT
Thanks for bringing closure, this was scaring me <G>...

On Tue, Dec 15, 2009 at 4:31 PM, Michel Nadeau <akaris@gmail.com> wrote:

> Forget it - I found the problem. There was an escaping problem on the
> search-client side.
>
> Sorry about that.
>
> - Mike
> akaris@gmail.com
>
>
> On Tue, Dec 15, 2009 at 3:48 PM, Michel Nadeau <akaris@gmail.com> wrote:
>
> > I search like this -
> >
> > IndexReader   reader   = IndexReader.open(idx, true);
> > IndexSearcher searcher = new IndexSearcher(reader);
> > QueryParser   parser   = new QueryParser(Version.LUCENE_CURRENT,
> "content",
> > cluStdAn); // StandardAnalyzer
> > q = parser.parse(QUERY);
> > TopDocs td = searcher.search(q, cluCF, md, cluSort);
> >
> > Any idea? I know it worked before... maybe it's not because of TOKENIZED
> vs
> > ANALYZED - maybe it's something else, but really I don't see; I'm using
> the
> > same analyzer to index and to search.
> >
> > - Mike
> > akaris@gmail.com
> >
> >
> >
> > On Tue, Dec 15, 2009 at 3:37 PM, Mark Miller <markrmiller@gmail.com
> >wrote:
> >
> >> Any more info to share?
> >>
> >> In 2.9, Tokenized literally == Analyzed.
> >>
> >>    /** @deprecated this has been renamed to {@link #ANALYZED} */
> >>    public static final Index TOKENIZED = ANALYZED;
> >>
> >> Michel Nadeau wrote:
> >> > Hi,
> >> >
> >> > I just realized that since I upgraded from Lucene 2.x to 3.0.0 (and
> >> removed
> >> > all deprecated things), searches like that don't work anymore:
> >> >
> >> > test AND blue
> >> > test NOT blue
> >> > (test AND blue) OR red
> >> > etc.
> >> >
> >> > Before 3.0.0, I was inserting my fields like this:
> >> >
> >> > doc.add(new Field("content", sValues[j], Field.Store.YES,
> >> > Field.Index.TOKENIZED));
> >> >
> >> > Now I do:
> >> >
> >> > doc.add(new Field("content", sValues[j], Field.Store.YES,
> >> > Field.Index.ANALYZED));
> >> >
> >> > My Index writer is opened like this:
> >> >
> >> > writer = new IndexWriter(idx, new
> >> StandardAnalyzer(Version.LUCENE_CURRENT),
> >> > true, MaxFieldLength.UNLIMITED);
> >> >
> >> > What is the equivalent of tokenized!?
> >> >
> >> > Thanks,
> >> >
> >> > - Mike
> >> > akaris@gmail.com
> >> >
> >> >
> >>
> >>
> >> --
> >> - Mark
> >>
> >> http://www.lucidimagination.com
> >>
> >>
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> >> For additional commands, e-mail: java-user-help@lucene.apache.org
> >>
> >>
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message