How to refer custom analyzer in search query?

(Sam-4) #1


I am using elastic server 0.16.2. i am using following java code for
creating custom analyzer:
I have created gist for used java code that create custom

search query java code :

QueryStringQueryBuilder querystring = new
SearchResponse searchResponse =

I have following doubt regarding custom analyzer:

  1. Is it is necessary to use same analyzer index creation and
    searching time.
  2. how to refer custom analyzer in search query.
    3.if we used following java code for define custom analyzer on
    index ,it can change previous created index mapping.

please help me and clear things.

(system) #2