I have created a scripted field in index patterns section for using it in open search visualization. It is coming correctly there. But the issue is that this field is getting displayed in discovery search result as well. I do not want my scripted fields to be displayed in discovery search result, but need it in visualization. How to achieve it
@pablo : do you know how to remove any field which is part of index or outside of it to remove from display in discover. I know above query was on scripted field.
I want to use one particular field for document level security (dls) to filter the data, but do not want to show that field in discovery search result.
In index patterns, there is a header against each field as ‘excluded’. but i am not seeing any option to set any field to excluded.
Hi @pablo
I was able to achieve with the below change in the index
“mappings”: {
"_source": {
"excludes": [
"filter_criteria"
]
},
so this field will not be visible to admin/non-admins in either dev tools/discovery or any search we are executing. But if we apply dls like below
“dls”: “{"term": {"filter_criteria": "0847976000040"}}” it works.