Documentation Home
MySQL 8.0 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr) - 46.1Mb
PDF (A4) - 46.1Mb
PDF (RPM) - 41.5Mb
HTML Download (TGZ) - 10.6Mb
HTML Download (Zip) - 10.6Mb
HTML Download (RPM) - 9.1Mb
Man Pages (TGZ) - 220.4Kb
Man Pages (Zip) - 325.8Kb
Info (Gzip) - 4.1Mb
Info (Zip) - 4.1Mb
Excerpts from this Manual

MySQL 8.0 Reference Manual  /  ...  /  Performance Schema User-Defined Variable Tables

26.12.10 Performance Schema User-Defined Variable Tables

The Performance Schema provides a user_variables_by_thread table that exposes user-defined variables. These are variables defined within a specific session and include a @ character preceding the name; see Section 9.4, “User-Defined Variables”.

The user_variables_by_thread table contains these columns:

  • 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.

The user_variables_by_thread table has these indexes:

  • Primary key on (THREAD_ID, VARIABLE_NAME)

TRUNCATE TABLE is not permitted for the user_variables_by_thread table.