diff options
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/func_str.result | 15 | ||||
-rw-r--r-- | mysql-test/r/key_cache.result | 12 | ||||
-rw-r--r-- | mysql-test/t/func_str.test | 5 | ||||
-rw-r--r-- | mysql-test/t/key_cache.test | 16 |
4 files changed, 27 insertions, 21 deletions
diff --git a/mysql-test/r/func_str.result b/mysql-test/r/func_str.result index 9904242b3e0..216e2ed26f2 100644 --- a/mysql-test/r/func_str.result +++ b/mysql-test/r/func_str.result @@ -639,14 +639,21 @@ name aaaaaaaaaaccccc bbbbbbbbbbddddd drop table t1, t2; -create table t1 (c1 INT); -insert into t1 (c1) values ('21474836461'); +create table t1 (c1 INT, c2 INT UNSIGNED); +insert into t1 values ('21474836461','21474836461'); Warnings: Warning 1265 Data truncated for column 'c1' at row 1 +Warning 1265 Data truncated for column 'c2' at row 1 +insert into t1 values ('-21474836461','-21474836461'); +Warnings: +Warning 1265 Data truncated for column 'c1' at row 1 +Warning 1265 Data truncated for column 'c2' at row 1 show warnings; Level Code Message Warning 1265 Data truncated for column 'c1' at row 1 +Warning 1265 Data truncated for column 'c2' at row 1 select * from t1; -c1 -2147483647 +c1 c2 +2147483647 4294967295 +-2147483648 0 drop table t1; diff --git a/mysql-test/r/key_cache.result b/mysql-test/r/key_cache.result index eeb838dc72c..1580f51975e 100644 --- a/mysql-test/r/key_cache.result +++ b/mysql-test/r/key_cache.result @@ -88,11 +88,9 @@ create table t2 (p int primary key, i int, a char(10), key k1(i), key k2(a)); show status like 'key_blocks_used'; Variable_name Value Key_blocks_used 0 -show status like 'The below may fail on 64-bit systems (ingo)'; -Variable_name Value show status like 'key_blocks_unused'; Variable_name Value -Key_blocks_unused 1812 +Key_blocks_unused KEY_BLOCKS_UNUSED insert into t1 values (1, 'qqqq'), (11, 'yyyy'); insert into t2 values (1, 1, 'qqqq'), (2, 1, 'pppp'), (3, 1, 'yyyy'), (4, 3, 'zzzz'); @@ -111,11 +109,9 @@ update t2 set i=2 where i=1; show status like 'key_blocks_used'; Variable_name Value Key_blocks_used 4 -show status like 'The below may fail on 64-bit systems (ingo)'; -Variable_name Value show status like 'key_blocks_unused'; Variable_name Value -Key_blocks_unused 1808 +Key_blocks_unused KEY_BLOCKS_UNUSED cache index t1 key (`primary`) in keycache1; Table Op Msg_type Msg_text test.t1 assign_to_keycache status OK @@ -275,11 +271,9 @@ drop table t1,t2,t3; show status like 'key_blocks_used'; Variable_name Value Key_blocks_used 4 -show status like 'The below may fail on 64-bit systems (ingo)'; -Variable_name Value show status like 'key_blocks_unused'; Variable_name Value -Key_blocks_unused 1812 +Key_blocks_unused KEY_BLOCKS_UNUSED set global keycache2.key_buffer_size=0; set global keycache3.key_buffer_size=100; set global keycache3.key_buffer_size=0; diff --git a/mysql-test/t/func_str.test b/mysql-test/t/func_str.test index 24753c28073..c4413c3ef3f 100644 --- a/mysql-test/t/func_str.test +++ b/mysql-test/t/func_str.test @@ -385,8 +385,9 @@ drop table t1, t2; # Test case for conversion of long string value to integer (Bug #3472) # -create table t1 (c1 INT); -insert into t1 (c1) values ('21474836461'); +create table t1 (c1 INT, c2 INT UNSIGNED); +insert into t1 values ('21474836461','21474836461'); +insert into t1 values ('-21474836461','-21474836461'); show warnings; select * from t1; drop table t1; diff --git a/mysql-test/t/key_cache.test b/mysql-test/t/key_cache.test index ca846a31def..b45df8eb58e 100644 --- a/mysql-test/t/key_cache.test +++ b/mysql-test/t/key_cache.test @@ -67,8 +67,12 @@ create table t1 (p int primary key, a char(10)) delay_key_write=1; create table t2 (p int primary key, i int, a char(10), key k1(i), key k2(a)); show status like 'key_blocks_used'; -show status like 'The below may fail on 64-bit systems (ingo)'; -show status like 'key_blocks_unused'; # This may fail on 64-bit systems (ingo) + +# Following results differs on 64 and 32 bit systems because of different +# pointer sizes, which takes up different amount of space in key cache + +--replace_result 1812 KEY_BLOCKS_UNUSED 1793 KEY_BLOCKS_UNUSED +show status like 'key_blocks_unused'; insert into t1 values (1, 'qqqq'), (11, 'yyyy'); insert into t2 values (1, 1, 'qqqq'), (2, 1, 'pppp'), @@ -80,8 +84,8 @@ update t1 set p=2 where p=1; update t2 set i=2 where i=1; show status like 'key_blocks_used'; -show status like 'The below may fail on 64-bit systems (ingo)'; -show status like 'key_blocks_unused'; # This may fail on 64-bit systems (ingo) +--replace_result 1808 KEY_BLOCKS_UNUSED 1789 KEY_BLOCKS_UNUSED +show status like 'key_blocks_unused'; cache index t1 key (`primary`) in keycache1; @@ -142,8 +146,8 @@ cache index t1,t2 in default; drop table t1,t2,t3; show status like 'key_blocks_used'; -show status like 'The below may fail on 64-bit systems (ingo)'; -show status like 'key_blocks_unused'; # This may fail on 64-bit systems (ingo) +--replace_result 1812 KEY_BLOCKS_UNUSED 1793 KEY_BLOCKS_UNUSED +show status like 'key_blocks_unused'; # Cleanup # We don't reset keycache2 as we want to ensure that mysqld will reset it |