First, I'd ask why you need to search on punctuation. This often leads you
into an overly-complex place. My first suggestion is that you re-think
whether that's desirable. If it's not, just use different analyzer at index
and search time.

If it is desirable, then you probably need to make your own analyzer that
does the same thing as WhitespaceAnalyzer but just lowercases the tokens and
use that in *both* indexing and querying. The actual code to create your own
analyzer is very, very, very small. See the Lucene source for
WhitespaceAnalyzer and WhitespaceTokenizer.........

As far as I know, WhiteSpaceAnalyzer does support the field:text format. Try
getting a copy of Luke (google lucene luke) and use that to examine your
index. You can fire queries at it using, for instance, WhitespaceAnalyzer
and see what actually happens. I'm betting that you're aren't executing the
query you think you are. Could you post a code snippet illustrating the
problem?

Best
Erick

On 11/16/06, Krishnendra Nandi <[EMAIL PROTECTED]> wrote:

Hi all,

I have a specific string query like "Jakarta:" How do i get that? I am
using standardAnalyzer and it seems as if it is stripping ":" and it is
simply searching for "Jakarta".
I have used WhiteSpaceAnalyzer also and its working fine for ":" but I
think it has some other limitations. The limitations of WhiteSpaceAnalyzer
which I have noticed are as follows:
1. It needs the search criteria in the proper case i.e for searching
"Jakarta" I cant give "jakarta" as my search criteria.
2. WhiteSpaceAnalyzer is not supporting FIELD:TEXT kind of search.
e.g ISSUE_TITLE:test
where ISSUE_TITLE is the field in which test is to be searched. But
standardAnalyzer supports this.

May be the limitations I am seeing is because of my code.

Can you please help me out as to how I can do a search like "Jakarta:". I
would appreciate if could please send me the code snippet doing this kind
of search.


Thanks & Regards
Krishnendra Nandi


The information contained in this e-mail and any accompanying documents
may contain information that is confidential or otherwise protected from
disclosure. If you are not the intended recipient of this message, or if
this message has been addressed to you in error, please immediately alert
the sender by reply e-mail and then delete this message, including any
attachments. Any dissemination, distribution or other use of the contents of
this message by anyone other than the intended recipient
is strictly prohibited.




Reply via email to