-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Closed
Labels
severity/moderatesig/sql-infraSIG: SQL InfraSIG: SQL Infratype/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.
Description
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
This is really confusing in MySQL:
When granting ALTER, or INSERT, CREATE privileges, it works, see #28533
However, when granting INSERT or SELECT, it doesn't work.
mysql> drop table if exists tmpdb.t1;
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> grant select on tmpdb.t1 to test_user;
Query OK, 0 rows affected (0.18 sec)
mysql> grant insert on tmpdb.t1 to test_user;
Query OK, 0 rows affected (0.18 sec)2. What did you expect to see? (Required)
mysql> drop table if exists tmpdb.t1;
Query OK, 0 rows affected, 1 warning (0.01 sec)
mysql> grant select on tmpdb.t1 to test_user;
ERROR 1146 (42S02): Table 'tmpdb.t1' doesn't exist
mysql> grant insert on tmpdb.t1 to test_user;
ERROR 1146 (42S02): Table 'tmpdb.t1' doesn't exist3. What did you see instead (Required)
mysql> drop table if exists tmpdb.t1;
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> grant select on tmpdb.t1 to test_user;
Query OK, 0 rows affected (0.18 sec)
mysql> grant insert on tmpdb.t1 to test_user;
Query OK, 0 rows affected (0.18 sec)4. What is your TiDB version? (Required)
Release Version: None
Edition: Community
Git Commit Hash: None
Git Branch: None
UTC Build Time: None
GoVersion: go1.16.4
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
severity/moderatesig/sql-infraSIG: SQL InfraSIG: SQL Infratype/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.