You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Rosen Marinov <ro...@sirma.bg> on 2004/09/29 12:15:05 UTC
Seraching in Keyword Field
Hi all,
I have a Keyword field in my Lucene docs.
And i am tring to execure some queries on this field.
1. MyKeywordField:(["ABC" TO "ABC"]) - this query is OK and returns expecting result
2. MyKeywordField:(ABC) - but this returning nothing
I am using SimpleAnalyzer - is the problem in analyzer?
If yes, which i have to use to make query 2 working?
How can i make query 2 working?
I know that Keyword fields are not analyzed, than may be the problem is not in analyzer.
But for QueryParser i use again SimpleAnalyzer, may be here is my mistake?
However, how to make a query 2 to work properly (as i expect)?
I know that it will find only fields with exact ABC value, is this true expecting?
Best Regars
Rosen
Re: Seraching in Keyword Field
Posted by Bernhard Messer <Be...@intrafind.de>.
Hi,
try that query:
MyKeywordField:ABC
regards
bernhard
Rosen Marinov wrote:
>Hi all,
>
>I have a Keyword field in my Lucene docs.
>And i am tring to execure some queries on this field.
>
>1. MyKeywordField:(["ABC" TO "ABC"]) - this query is OK and returns expecting result
>
>2. MyKeywordField:(ABC) - but this returning nothing
>
>I am using SimpleAnalyzer - is the problem in analyzer?
> If yes, which i have to use to make query 2 working?
>
>How can i make query 2 working?
>I know that Keyword fields are not analyzed, than may be the problem is not in analyzer.
>
>But for QueryParser i use again SimpleAnalyzer, may be here is my mistake?
>
>However, how to make a query 2 to work properly (as i expect)?
>I know that it will find only fields with exact ABC value, is this true expecting?
>
>Best Regars
>
>Rosen
>
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org