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 Alex Kiselevski <AL...@Amdocs.com> on 2004/12/27 09:21:23 UTC
Correct query
Hello,
I indexed some document that included a word RPG/4.
So, when I made a search - I builded a query
Text:RPG but it didn't find a thing only Text:RPG/4 gave me the correct
result.
Tell me please what have I do to build a a dynamic (not hardcoded like
in this example )query to get right results
Thanks in advance
Alex Kiselevsky
Speech Technology Tel: 972-9-776-43-46
R&D, Amdocs - Israel Mobile: 972-53-63 50 38
mailto:alexkis@amdocs.com
The information contained in this message is proprietary of Amdocs,
protected from disclosure, and may be privileged.
The information is intended to be conveyed only to the designated recipient(s)
of the message. If the reader of this message is not the intended recipient,
you are hereby notified that any dissemination, use, distribution or copying of
this communication is strictly prohibited and may be unlawful.
If you have received this communication in error, please notify us immediately
by replying to the message and deleting it from your computer.
Thank you.
Re: Correct query
Posted by Erik Hatcher <er...@ehatchersolutions.com>.
On Dec 27, 2004, at 3:21 AM, Alex Kiselevski wrote:
> Hello,
> I indexed some document that included a word RPG/4.
> So, when I made a search - I builded a query
>
> Text:RPG but it didn't find a thing only Text:RPG/4 gave me the correct
> result.
> Tell me please what have I do to build a a dynamic (not hardcoded like
> in this example )query to get right results
What Analyzer did you use? Are you using QueryParser and using the
same analyzer with it? Please read the AnalysisParalysis page on the
wiki. Also, running the AnalyzerDemo from Lucene in Action's source
code yields this, which should help illuminate the situation:
$ ant -emacs AnalyzerDemo
Buildfile: build.xml
AnalyzerDemo:
Demonstrates analysis of sample text.
Refer to the "Analysis" chapter for much more on this
extremely crucial topic.
Press return to continue...
String to analyze: [This string will be analyzed.]
RPG/4
Running lia.analysis.AnalyzerDemo...
Analyzing "RPG/4"
WhitespaceAnalyzer:
[RPG/4]
SimpleAnalyzer:
[rpg]
StopAnalyzer:
[rpg]
StandardAnalyzer:
[rpg/4]
---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org