Is it possible to highlight matches in MongoDB text search results?

Is it possible to determine what part of the text in which the indexed text fields match the query?

+3


source to share


1 answer


No, as far as I know and can tell from Jira, such a feature does not currently exist . You can, of course, try to highlight parts of the text yourself, but for this you need to implement highlighting, and also perform stemning in accordance with the rules applied by MongoDB.



This whole function is somewhat tricky - even consuming it - as you can see from the related elasticsearch documentation .

+1


source







All Articles