pingcap / pingcap/tidb

Support partial revokes for better privilege management

Open
#40,065 1 comment 0 reactions 1 assignee Claimed by @CbcWestwolf View on GitHub
type/feature-request
Dominant language
Go
Stars
40.5k
Forks
6.2k
PR merge metrics
PR metrics pending

Description

MySQL 8.0.16 has implemented [Partial Revokes](https://dev.mysql.com/doc/refman/8.0/en/partial-revokes.html) to grant privileges that apply globally except for certain schemas. TiDB does not support this now:
```sql
tidb0> SET partial_revokes = ON;
(1193, "Unknown system variable 'partial_revokes'")
tidb0> CREATE USER u1;
Query OK, 0 rows affected
Time: 0.008s
tidb0> GRANT SELECT, INSERT ON *.* TO u1;
Query OK, 0 rows affected
Time: 0.008s
tidb0> REVOKE INSERT ON world.* FROM u1;
(1105, "There is no such grant defined for user 'u1' on host '%' on database world")
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.