# Flt + highlight, no highlight

**URL:** <https://discuss.elastic.co/t/flt-highlight-no-highlight/11703>\
**Category:** Elasticsearch\
**Created:** [April 26, 2013, 1:47pm UTC](https://discuss.elastic.co/t/flt-highlight-no-highlight/11703 "2013-04-26T13:47:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![s\_balard](https://avatars.discourse-cdn.com/v4/letter/s/b38774/32.png) [@s\_balard](https://discuss.elastic.co/u/s_balard)\
**Post date:** [April 26, 2013, 1:47pm UTC](https://discuss.elastic.co/t/flt-highlight-no-highlight/11703/1 "2013-04-26T13:47:15Z")

</div>

Hi all,  
I have a little problem with highlight mechanism, there are already some  
posts on fuzzy + highlight but I don't find any solution to my problem.  
I use ES as part of keywords search engine development for a travel agency  
website.  
Basic requests use match + highlight and all works very good.  
But, when match does not find any result, I try to use flt to see there  
will be not similar results (i.e. a proper name miswritten, ...)

So, here an example of match request which works with highlight :

{  
"query": {  
"match": {  
"\_all": {  
"query": "N'Gorongoro",  
"operator": "and"  
}  
}  
},  
"highlight": {  
"order": "score",  
"fields": {  
"\_all": {},  
"title": {  
"number\_of\_fragments": 0  
},  
"themes": {  
"number\_of\_fragments": 0  
},  
"intro": {  
"number\_of\_fragments": 2,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"summary": {  
"number\_of\_fragments": 2,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"program": {  
"number\_of\_fragments": 3,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"hotel": {  
"number\_of\_fragments": 2,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"accommodations": {  
"number\_of\_fragments": 3,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"vehicles": {  
"number\_of\_fragments": 2,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"options": {  
"number\_of\_fragments": 2,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"extensions": {  
"number\_of\_fragments": 2,  
"fragment\_size": 75,  
"fragment\_offset": 25  
},  
"content": {  
"number\_of\_fragments": 3,  
"fragment\_size": 100,  
"fragment\_offset": 50  
}  
}  
}  
}

And there, an example of flt request which works but where there is not  
highlight :

{  
"query": {  
"flt": {  
"like\_text": "gorogoro"  
}  
},  
"highlight": {  
"order": "score",  
"fields": {  
"\_all": {},  
"title": {  
"number\_of\_fragments": 0  
},  
"themes": {  
"number\_of\_fragments": 0  
},  
"intro": {  
"number\_of\_fragments": 2,  
"fragment\_size": 50  
},  
"summary": {  
"number\_of\_fragments": 2,  
"fragment\_size": 50  
},  
"program": {  
"number\_of\_fragments": 3,  
"fragment\_size": 50  
},  
"hotel": {  
"number\_of\_fragments": 2,  
"fragment\_size": 50  
},  
"accommodations": {  
"number\_of\_fragments": 3,  
"fragment\_size": 50  
},  
"vehicles": {  
"number\_of\_fragments": 2,  
"fragment\_size": 50  
},  
"options": {  
"number\_of\_fragments": 2,  
"fragment\_size": 50  
},  
"extensions": {  
"number\_of\_fragments": 2,  
"fragment\_size": 50  
},  
"content": {  
"number\_of\_fragments": 3,  
"fragment\_size": 100  
}  
}  
}  
}

Does someone have any suggestion ?  
Thank you.

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:39am UTC](https://discuss.elastic.co/t/flt-highlight-no-highlight/11703/2 "2017-07-06T02:39:28Z")

</div>


