Performance Schema user_variables_by_thread Table
MariaDB starting with 10.5.2
The user_variables_by_thread
table was added in MariaDB 10.5.2.
The user_variables_by_thread
table contains information about user-defined variables and the threads that defined them.
TRUNCATE TABLE cannot be performed on the table.
The table contains the following columns:
Column | Description |
---|---|
THREAD_ID | The thread identifier of the session in which the variable is defined. |
VARIABLE_NAME | The variable name, without the leading @ character. |
VARIABLE_VALUE | The variable value |
Example
SET @var = 0; SELECT * FROM user_variables_by_thread; +-----------+---------------+----------------+ | THREAD_ID | VARIABLE_NAME | VARIABLE_VALUE | +-----------+---------------+----------------+ | 11 | var | 0 | +-----------+---------------+----------------+
See Also
Content reproduced on this site is the property of its respective owners,
and this content is not reviewed in advance by MariaDB. The views, information and opinions
expressed by this content do not necessarily represent those of MariaDB or any other party.