Hello guys, I am a new starter to elasticsearch. I am trying to use Java API to search and retrieve files.
The problem is, i cannot figure out a good way to do the substring searching.
For example, if the file's content is :
"aaaa-bbbb-cccc"
then I can use the "matchQuery()" or "regexpQuery()" to search for "aaaa" or "bbbb" and get the target file.
However, if the file's content change to :
"aaaa.bbbb.cccc"
I just cannot search for it with a substring! No matter I use matchQuery or regexpQuery or any other kinds of queries, I cannot get this file by searching "aaaa", "bbbb", or "cccc".
I don't understand why this is happening, because If i use Kibana and search from the gui, I can get the satisfying result.
Would any guys help me out please? I really appreciate that. Thanks in advance.