~ubuntu-branches/ubuntu/trusty/mysql-5.6/trusty

« back to all changes in this revision

Viewing changes to mysql-test/suite/sys_vars/t/old_alter_table_basic.test

  • Committer: Package Import Robot
  • Author(s): James Page
  • Date: 2014-02-12 11:54:27 UTC
  • Revision ID: package-import@ubuntu.com-20140212115427-oq6tfsqxl1wuwehi
Tags: upstream-5.6.15
ImportĀ upstreamĀ versionĀ 5.6.15

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
#
 
3
# 2010-01-20 OBN - added check of I_S values after variable value changed
 
4
#
 
5
 
 
6
SET @start_global_value = @@global.old_alter_table;
 
7
SELECT @start_global_value;
 
8
 
 
9
#
 
10
# exists as global and session
 
11
#
 
12
select @@global.old_alter_table;
 
13
select @@session.old_alter_table;
 
14
show global variables like 'old_alter_table';
 
15
show session variables like 'old_alter_table';
 
16
select * from information_schema.global_variables where variable_name='old_alter_table';
 
17
select * from information_schema.session_variables where variable_name='old_alter_table';
 
18
 
 
19
#
 
20
# show that it's writable
 
21
#
 
22
set global old_alter_table=1;
 
23
set session old_alter_table=ON;
 
24
select @@global.old_alter_table;
 
25
select @@session.old_alter_table;
 
26
show global variables like 'old_alter_table';
 
27
show session variables like 'old_alter_table';
 
28
select * from information_schema.global_variables where variable_name='old_alter_table';
 
29
select * from information_schema.session_variables where variable_name='old_alter_table';
 
30
 
 
31
#
 
32
# incorrect types
 
33
#
 
34
--error ER_WRONG_TYPE_FOR_VAR
 
35
set global old_alter_table=1.1;
 
36
--error ER_WRONG_TYPE_FOR_VAR
 
37
set global old_alter_table=1e1;
 
38
--error ER_WRONG_VALUE_FOR_VAR
 
39
set global old_alter_table="foo";
 
40
 
 
41
SET @@global.old_alter_table = @start_global_value;
 
42
SELECT @@global.old_alter_table;