> ## Documentation Index
> Fetch the complete documentation index at: /documents/llms.txt
> Use this file to discover all available pages before exploring further.

# SHOW USERS

> SHOW USERS displays all users in the system.

## 功能

查看当前系统中的所有用户。注意这里的用户不是用户名，而是用户标识 (user identity)。更多信息，参见 [CREATE USER](/documents/cn/4.2/sql-reference/sql-statements/account-management/CREATE_USER.md)。该命令从 3.0 版本开始支持。

您可以通过 `SHOW GRANTS FOR <user_identity>;` 来查看某个用户的权限，参见 [SHOW GRANTS](/documents/cn/4.2/sql-reference/sql-statements/account-management/SHOW_GRANTS.md)。

**Tip**

只有拥有 `user_admin` 角色的用户才可以执行此操作。

## 语法

```SQL theme={null}
SHOW USERS
```

返回字段说明：

| **字段名称** | **描述** |
| - | - |
| User | 用户标识。 |

## 示例

查看当前系统中的所有用户。

```SQL theme={null}
mysql> SHOW USERS;
+-----------------+
| User            |
+-----------------+
| 'lily'@'%'      |
| 'root'@'%'      |
| 'admin'@'%'     |
| 'jack'@'%'      |
| 'tom'@'%'       |
+-----------------+
```

## 相关文档

* [CREATE USER](/documents/cn/4.2/sql-reference/sql-statements/account-management/CREATE_USER.md)
* [ALTER USER](/documents/cn/4.2/sql-reference/sql-statements/account-management/ALTER_USER.md)
* [DROP USER](/documents/cn/4.2/sql-reference/sql-statements/account-management/DROP_USER.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.