Check login permissions
check_permissionsVerify what a login can see and modify in a database: roles, effective permissions, missing GRANTs, and write access, when listings look short or tools hit permission errors.
Instructions
Reports what the connected login can and cannot see in a database: identity, roles, effective permissions, server version and, for each group of tools, whether it sees everything ('complete'), only part ('partial') or nothing ('unavailable'), with the missing permission and the GRANT that adds it in this server version's syntax. Also reports 'write_access', so an account meant to be read-only can be verified rather than assumed. Call it when a listing looks short, a definition comes back hidden, get_database_overview reports incomplete visibility, or a tool fails with a permission error: SQL Server leaves out what a login cannot see without raising any error.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| database | Yes | Name of the database as registered in the configuration. |