In Unity Catalog, enabling users to query a view while hiding its definition is currently not supported directly. Unity Catalog requires view definitions to be visible during query execution for metadata access purposes. While querying, users typically need permissions such as SELECT on the view, alongside USAGE on the schema and catalog containing the view.
Dynamic row-level or column-level security can be applied using specific functions or masking in Unity Catalog to restrict access to sensitive data. However, options to fully obscure view definitions or apply "execute-only" access are not explicitly provided within the current capabilities of Unity Catalog.
If your organization requires strict access control that prevents users from seeing view definitions, creating a sandboxed schema or using external tools for governance (such as Privacera or Immuta) might be viable alternatives. These tools can integrate with Unity Catalog to enforce granular privacy policies at the query level