view_privileges.md 307 字节
Newer Older
M
Mars Liu 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
# 查看用户权限

Joe 想要查看 Fred 的 MySQL 账户 `'fred'@'%'` 的权限,他应该怎么做?

## 答案

```mysql
show grants for fred;
```

## 选项

### A

```mysql
select grants from fred;
```

### B

```mysql
show privileges for fred;
```

### B

```mysql
show privileges from fred;
```