Hi All,
I came across Shay Bannon's solution, for enabling porter stemming
while indexing, at the gist- https://gist.github.com/879883 . I have
one more issue for which I have not been able to solve and need help
on this please. How do I enable the stemming on all the fields? In the
example given in the gist, stemming happens on title field only.
Basically, when I construct my search query using XGET, I would like
to give q=fight instead of q=title:fight and I would like stemming to
work on the former case. The gist mentions this "searching on _all
will not do anystemming, unless also configured on the mapping to be
stemmed...".
I tried the following but didn't work:
curl -XPUT localhost:9200/local -d '{
"settings" : {
"analysis" : {
"analyzer" : {
"stem" : {
"tokenizer" : "standard",
"filter" : ["standard", "lowercase", "stop",
"porter_stem"]
}
}
}
},
"mappings" : {
"article" : {
"dynamic" : true,
"properties" : {
"_all" : {
"type" : "string",
"analyzer" : "stem"
}
}
}
}
}'
I changed the title field to _all field, but it is not working. Would
appreciate help here.
Thanks,
Niranjan