Sunday, April 17, 2011

Lucene and forward slash

In my index there is a value companyName:opel/vauxhall
Searching for "opel/vauxhall" returns the correct results.
Searching for "opel/*" returns nothing.

Currently I'm replacing the '/' with spaces. But that does give my code a bit of a smell.

Any better ideas?

From stackoverflow
  • Hi,

    What database is that?

    M.

    borisCallens : http://incubator.apache.org/lucene.net/
  • This kind of problem is almost always caused by the analyzer used for indexing and searching (parsing the query).

    Try using a different analyzer, for example StopAnalyzer.

0 comments:

Post a Comment

Note: Only a member of this blog may post a comment.