1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
|
SET @start_global_value = @@global.max_user_connections;
SELECT @start_global_value;
@start_global_value
10
SET @start_session_value = @@session.max_user_connections;
SELECT @start_session_value;
@start_session_value
10
'#--------------------FN_DYNVARS_087_01-------------------------#'
SET @@global.max_user_connections = 1000;
SET @@global.max_user_connections = DEFAULT;
SELECT @@global.max_user_connections;
@@global.max_user_connections
0
SET @@session.max_user_connections = 1000;
ERROR HY000: SESSION variable 'max_user_connections' is read-only. Use SET GLOBAL to assign the value
'#--------------------FN_DYNVARS_087_02-------------------------#'
SET @@global.max_user_connections = DEFAULT;
SELECT @@global.max_user_connections = 0;
@@global.max_user_connections = 0
1
SET @@session.max_user_connections = DEFAULT;
ERROR HY000: SESSION variable 'max_user_connections' is read-only. Use SET GLOBAL to assign the value
SELECT @@session.max_user_connections;
@@session.max_user_connections
0
'#--------------------FN_DYNVARS_087_03-------------------------#'
SET @@global.max_user_connections = 1;
SELECT @@global.max_user_connections;
@@global.max_user_connections
1
SET @@global.max_user_connections = 2;
SELECT @@global.max_user_connections;
@@global.max_user_connections
2
SET @@global.max_user_connections = 65536;
SELECT @@global.max_user_connections;
@@global.max_user_connections
65536
SET @@global.max_user_connections = 2147483647;
SELECT @@global.max_user_connections;
@@global.max_user_connections
2147483647
SET @@global.max_user_connections = 2147483646;
SELECT @@global.max_user_connections;
@@global.max_user_connections
2147483646
'#------------------FN_DYNVARS_087_05-----------------------#'
SET @@global.max_user_connections = -1024;
Warnings:
Warning 1292 Truncated incorrect max_user_connections value: '-1024'
SELECT @@global.max_user_connections;
@@global.max_user_connections
-1
SET @@global.max_user_connections = 4294967296;
Warnings:
Warning 1292 Truncated incorrect max_user_connections value: '4294967296'
SELECT @@global.max_user_connections;
@@global.max_user_connections
2147483647
SET @@global.max_user_connections = -1;
SELECT @@global.max_user_connections;
@@global.max_user_connections
-1
SET @@global.max_user_connections = 429496729500;
Warnings:
Warning 1292 Truncated incorrect max_user_connections value: '429496729500'
SELECT @@global.max_user_connections;
@@global.max_user_connections
2147483647
SET @@global.max_user_connections = 65530.34;
ERROR 42000: Incorrect argument type to variable 'max_user_connections'
SELECT @@global.max_user_connections;
@@global.max_user_connections
2147483647
SET @@global.max_user_connections = test;
ERROR 42000: Incorrect argument type to variable 'max_user_connections'
SELECT @@global.max_user_connections;
@@global.max_user_connections
2147483647
'#------------------FN_DYNVARS_087_06-----------------------#'
SELECT @@global.max_user_connections = VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='max_user_connections';
@@global.max_user_connections = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_087_08-----------------------#'
SET @@global.max_user_connections = TRUE;
SELECT @@global.max_user_connections;
@@global.max_user_connections
1
SET @@global.max_user_connections = FALSE;
SELECT @@global.max_user_connections;
@@global.max_user_connections
0
'#---------------------FN_DYNVARS_087_09----------------------#'
SET @@global.max_user_connections = 20;
SELECT @@max_user_connections = @@global.max_user_connections;
@@max_user_connections = @@global.max_user_connections
1
'#---------------------FN_DYNVARS_087_11----------------------#'
SET @@global.max_user_connections = 102;
SELECT @@max_user_connections;
@@max_user_connections
102
SELECT local.max_user_connections;
ERROR 42S02: Unknown table 'local' in SELECT
SELECT session.max_user_connections;
ERROR 42S02: Unknown table 'session' in SELECT
SELECT max_user_connections = @@session.max_user_connections;
ERROR 42S22: Unknown column 'max_user_connections' in 'SELECT'
SET @@global.max_user_connections = @start_global_value;
SELECT @@global.max_user_connections;
@@global.max_user_connections
10
|