Nick Roth
07/31/2024, 6:08 PMexclude_fields
.
We have some objects in our schema, where we are only indexing portions of them. For example, maybe we have a category assigned to the content, where we index the id and name (category.id, category.name), but there are other display specific fields that might only be used in certain context. While testing, I was using the exclude_fields
parameter to remove some of the data so i could more easily see some of the text matches. However, I noticed that:
Issue: Including the non-indexed object field in the exclude_fields parameter doesn’t remove the entire object like i expected (exclude_fields=category
). However, what it does do is exclude the indexed fields. I tried a wildcard (exclude_fields=category.*
) and that did the same thing. So, it seems you have to specify every single field within an object to remove it if you only index a subset of the fields within it.
Is this expected behavior? Not a blocker or anything for us, since we can use include_fields and/or a search preset, but thought it was odd.