# mysql.roles\_mapping Table

1. PARTITION BY SYSTEM\_TIME is not supported for transaction-precise system-versioned tables. Attempting

The `mysql.roles_mapping` table contains information about mariaDB [roles](/docs/server/security/user-account-management/roles.md).

This table uses the [Aria](/docs/server/server-usage/storage-engines/aria.md) storage engine.

The `mysql.roles_mapping` table contains the following fields:

| Field         | Type          | Null | Key | Default | Description                                                                                                                                                        |
| ------------- | ------------- | ---- | --- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Host          | char(60)      | NO   | PRI |         | Host (together with User and Role makes up the unique identifier for this record.                                                                                  |
| User          | char(80)      | NO   | PRI |         | User (together with Host and Role makes up the unique identifier for this record.                                                                                  |
| Role          | char(80)      | NO   | PRI |         | Role (together with Host and User makes up the unique identifier for this record.                                                                                  |
| Admin\_option | enum('N','Y') | NO   |     | N       | Whether the role can be granted (see the [CREATE ROLE](/docs/server/reference/sql-statements/account-management-sql-statements/create-role.md) WITH ADMIN clause). |

The [Acl\_role\_grants](/docs/server/server-management/variables-and-modes/server-status-variables.md#acl_role_grants) status variable indicates how many rows the `mysql.roles_mapping` table contains.

<sub>*This page is licensed: CC BY-SA / Gnu FDL*</sub>

{% @marketo/form formId="4316" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://mariadb.com/docs/server/reference/system-tables/the-mysql-database-tables/mysql-roles_mapping-table.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
