Server IP : 104.21.38.3 / Your IP : 108.162.226.115 Web Server : Apache System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /www/server/mysql/src/mysql-test/suite/sys_vars/t/ |
Upload File : |
############################################################################### # # # File containing basic tests for offline mode variable # # # ############################################################################### --source include/not_embedded.inc --echo # --echo # Variable name : offline_mode --echo # Scope : Global --echo # --echo # Global - default SELECT @@global.offline_mode; --error ER_INCORRECT_GLOBAL_LOCAL_VAR SELECT @@session.offline_mode; --echo --error ER_WRONG_VALUE_FOR_VAR SET @@global.offline_mode= 'true'; --echo --error ER_WRONG_VALUE_FOR_VAR SET @@global.offline_mode= 100; --echo --error ER_WRONG_VALUE_FOR_VAR SET @@global.offline_mode= WRONGVALUE; --echo --echo # via INFORMATION_SCHEMA.GLOBAL_VARIABLES --disable_warnings SELECT * FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME LIKE 'offline_mode'; --enable_warnings # Save the global value to be used to restore the original value. SET @global_saved_tmp = @@global.offline_mode; --echo --echo # Altering global variable's value SET @@global.offline_mode = 0; SELECT @@global.offline_mode; SET @@global.offline_mode = TrUe; SELECT @@global.offline_mode; SET @@global.offline_mode = FaLsE; SELECT @@global.offline_mode; --echo --echo # Variables' values in a new session. connect (con1,"127.0.0.1",root,,test,$MASTER_MYPORT,); --echo # Global - expect 0 SELECT @@global.offline_mode; --echo --echo # Switching to the default connection. connection default; SELECT @@global.offline_mode; --echo --echo # Test if DEFAULT is working as expected. SET @@global.offline_mode = DEFAULT; --echo --echo # Global - expect 0 SELECT @@global.offline_mode; --echo --echo # Restoring the original values. SET @@global.offline_mode = @global_saved_tmp; --echo # End of tests.