v.24.11New Feature

Add CHECK GRANT query for privilege and existence validation

Add CHECK GRANT query to check whether the current user/role has been granted the specific privilege and whether the corresponding table/column exists in the memory. #68885 (Unalian).
Introduces the CHECK GRANT query to verify if the current user or role has been granted a specific privilege and if the corresponding table or column exists in memory.

Why it matters

This feature helps users and administrators quickly validate access rights and the presence of database objects without executing actual queries, improving security checks and debugging of privilege issues.

How to use it

Use the CHECK GRANT SQL statement followed by the privilege and object to verify. For example:

CHECK GRANT SELECT ON my_table


This will confirm if the current user/role has SELECT privilege on my_table and if the table exists in memory.