Syntax
SET variable_assignment [, variable_assignment] ...
variable_assignment:
user_var_name = expr
| [GLOBAL | SESSION] system_var_name = expr
| [@@global. | @@session. | @@]system_var_name = exprDescription
The SET statement assigns values to different types of
variables that affect the operation of the server or your client. Older
versions of MySQL employed SET OPTION, but this syntax is
deprecated in favor of SET without OPTION.
See SHOW VARIABLES for documentation on viewing server system variables.
See Server System Variables for a list of all the system variables.
Examples
MariaDB [(none)]> SHOW VARIABLES WHERE Variable_name LIKE "maria_group_commit%"; +-----------------------------+-------+ | Variable_name | Value | +-----------------------------+-------+ | maria_group_commit | none | | maria_group_commit_interval | 0 | +-----------------------------+-------+ 2 rows in set (0.00 sec) MariaDB [(none)]> SET GLOBAL maria_group_commit="HARD"; Query OK, 0 rows affected (0.00 sec) MariaDB [(none)]> SET GLOBAL maria_group_commit_interval=100; Query OK, 0 rows affected (0.00 sec) MariaDB [(none)]> SHOW VARIABLES WHERE Variable_name LIKE "maria_group_commit%"; +-----------------------------+-------+ | Variable_name | Value | +-----------------------------+-------+ | maria_group_commit | hard | | maria_group_commit_interval | 100 | +-----------------------------+-------+ 2 rows in set (0.00 sec)
Comments
Comments loading...