Highlight field is empty

Hi all,
I'm using the https://search-api.swiftype.com/api/v1/engines API and I'm concern about why for some results the highlight field comes empty, that field always should return values right?

I was reading the documentation : API Overview | Swiftype Documentation

https://lucene.apache.org/core/3_0_3/queryparsersyntax.html

So I guess it has something to do with the query, I know that is supported special character, because I have notice that the search results are fine with special characters, but the highlight field is coming empty.

Any thoughts about it?

Hello Jose!

The highlight fields might not contain anything if there was no exact query match. You can use the fallback parameter to ensure something is returned every time. More on this behavior is outlined here: Highlight Fields | Swiftype Documentation.

I also want to note that I'm assuming you're working with Swiftype, and not Elastic App Search. Do correct me if that's not the case.

Let me know if that helps!

Ross

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.