I facing the issue while using wild card search with query containing understore (_) in it with elasticsearch version 6.0.1
And i'm using word_delimiter_filter for the field my_field as mentioned in below query
I have document with my_field = document_02.txt and i want to search for this document using _02* as mentioned in below query but this will give me zero result
I'm not sure why you're using a word_delimiter token filter. When analyzing document_02.txt, it's going to produce the following tokens (obtained from the _analyze endpoint):
Ok I understand. Since document_02.txt gets tokenized and indexed as the three tokens document, 02 and txt, you can search for 02* instead of _02* since the underscore is discarded during the analysis process.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.