Reputation: 11
I have a big problem and questions regarding solr behaviour,could you please help me to solve this.
Don't mind my questions are too long.
My client have a requirement like the following below.
and we have wildcard as well left,right,both are the wildcard entries.
I used Keyword tokenizer for indexing as well as querying it is satisfying my requirement in all scenarios.But synonyms,stopwords and stemming not working at all.Because i used keyword tokenizer and it is building queries like whole phrase.I tried with StandaradTokenizer factory it is failing only matchall scenario remaining it is working fine.
Could you please post some example queries and suggestions to get exact matches with single word/multiword .
e.g. If my field has "Indicators Indicator Components" this is whole phrase.i am getting results even though i am searching for "indicator" i don't want that.
If i use keyword tokenizer i am getting what i want but it is failing in synonyms,stopwords scenarios.
Some times(depends on the logic) i will use same text filed for matchallpartial scenario that time i want results for "indicator" how can i get exact matchall for whole phrase/word by using stadardtokenizer.
Please help me.
Thanks, Sri
Upvotes: 1
Views: 2071
Reputation: 589
I am listing two examples which will surely help to get exact match
My first query is :- /select?q=name:anand kishore
- By this way I will get 1000 records which will be having name anand or kishore or both
My Second query is :- /select?q=name:"anand kishore"
- By this I will get 60 results of the records which will have anand kishore like, (anand kishore tripathy, kamal anand kishore)
My Third query is :- /select?q=name:"kamal anand kishore"
- By this I will get only one result which is matching exactly, i.e kamal anand kishore
Upvotes: 1