In data model, we have the possibility to change the visibility of each field like “every where”/“Only in detail views”/“Do not include”.
In my understanding, this feature can be use to hide sensible data to the end user and it works as expected in the sql builder.
But unfortunately, it doesn’t seems to be apply if we write a custom sql query. Something like “select * from mytablewithhidenfield” will return all field even those which should be hidden.
@williamherry There’s a request open for it, but it would require that Metabase interprets the SQL/Native query, which is something we’ve been looking at, but that’s a huge project. https://github.com/metabase/metabase/issues/1689 - upvote by clicking on the first post
The workaround is either not give query permissions to the users, or use a database view where the column is never returned to Metabase.