Actually, I am working on a Question dataset where multiple questions are mapped in the question prompt field.
question prompt field consist question such as
For Ex-"1a. How GOOD are you at collecting or managing information or data?"
Questions starting with 1a,2a,2b, and so on are not present in the question_prompt.keyword field.
It May be due to the integer value present in the field and the text field is not working due to that.
Can someone tell me how to set correct mapping for such field which will show all questions starting from integer value in question_prompt.keyword field.
keyword, which is used for structured content such as IDs, email addresses, hostnames, status codes, zip codes, or tags.
text [2]:
A field to index full-text values, such as the body of an email or the description of a product. These fields are analyzed , that is they are passed through an analyzer to convert the string into a list of individual terms before being indexed.
Note we're using the text field here. It analyzes the field and lets us perform full text search on the field.
Keyword fields are generally used for exact matches and aggregations. You may be able to perform a wildcard lookup by searching for 1a* with question_prompt.keyword.
Do either of these options work for you? If we want to get into specifics and best practices, we have to move this thread over to the Elasticsearch forum.
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.