I have an azure cognitive search index and I am using search.ismatch ODATA full text search function to return records that match a particular key work.
Data
Apple
Pineapple
search.ismatch('apple', 'Text')
I am expecting the query to return both values but I am only getting 1. i.e. It only matches first letters in the word.
How to return the data regardless where the search text within the data?
One possible solution to search based on substring of text is by using
ngarm tokenizerin your indexschema.With above schema I have uploaded the given sample data:
With the above index definition and data, I was able to get the required results.
Note: This is sample code for demonstration, you might to have to modify and reconfigure based on your requirement.
For more details related to partial search, you can check this documentation.