It appears that StringField instances are treated as literals, even though my
analyzer lower-cases (on both write and read sides). So, for example, I can
match with a term query (e.g. "NEW YORK"), but only if the case matches. If I
use a QueryParser (or MultiFieldQueryParser), it never works b
chael
-Original Message-
From: Shahak Nagiel [mailto:snag...@yahoo.com]
Sent: Tuesday, May 21, 2013 10:06 AM
To: java-user@lucene.apache.org
Subject: Case insensitive StringField?
It appears that StringField instances are treated as literals, even though my
analyzer lower-cases (on both
to trim exterior white space and normalize interior white
space.
-- Jack Krupansky
-Original Message-
From: Shahak Nagiel
Sent: Tuesday, May 21, 2013 10:06 AM
To: java-user@lucene.apache.org
Subject: Case insensitive StringField?
It appears that StringField instances are treated as
s. Is a QueryParser the wrong way to generate the query for
this type of analyzer?
Thanks again!
From: Jack Krupansky
To: java-user@lucene.apache.org
Sent: Tuesday, May 21, 2013 10:22 AM
Subject: Re: Case insensitive StringField?
To be clear, an
Yes it is. It always will. But... you can escape the spaces with a
backslash:
Query q = qp.parse("new\\ york");
-- Jack Krupansky
-Original Message-
From: Shahak Nagiel
Sent: Tuesday, May 21, 2013 10:09 PM
To: java-user@lucene.apache.org
Subject: Re: Case insensitive S