diff options
author | unknown <svoj@mysql.com/june.mysql.com> | 2007-02-28 18:34:35 +0400 |
---|---|---|
committer | unknown <svoj@mysql.com/june.mysql.com> | 2007-02-28 18:34:35 +0400 |
commit | af44be2d25e25189363044265089fab391e060d1 (patch) | |
tree | c71e3a8227be82a70c99397a2e2270c208e6b430 /mysql-test/r/delayed.result | |
parent | c5beed03464e9b74d75a701721154d68fc4f84ea (diff) | |
download | mariadb-git-af44be2d25e25189363044265089fab391e060d1.tar.gz |
BUG#26238 - inserted delayed always inserts 0 for BIT columns
INSERT DELAYED inserts garbage for BIT columns.
When delayed thread clones TABLE object, it didn't adjusted bit_ptr
to newly created record (though it correctly adjusts ptr and null_ptr).
This is fixed by correctly adjusting bit_ptr when performing a clone.
With this fix BIT values are stored correctly by INSERT DELAYED.
mysql-test/r/delayed.result:
A test case for BUG#26238.
mysql-test/t/delayed.test:
A test case for BUG#26238.
sql/field.h:
Added move_field() to Field_bit class. When moving a field, adjust
bit_ptr also, which is specific to Field_bit class.
Diffstat (limited to 'mysql-test/r/delayed.result')
-rw-r--r-- | mysql-test/r/delayed.result | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/mysql-test/r/delayed.result b/mysql-test/r/delayed.result index 6295fceec2b..82a308c63e7 100644 --- a/mysql-test/r/delayed.result +++ b/mysql-test/r/delayed.result @@ -243,3 +243,10 @@ SET @@session.auto_increment_offset= @bug20830_old_session_auto_increment_offset; SET @@session.auto_increment_increment= @bug20830_old_session_auto_increment_increment; +CREATE TABLE t1(a BIT); +INSERT DELAYED INTO t1 VALUES(1); +FLUSH TABLE t1; +SELECT HEX(a) FROM t1; +HEX(a) +1 +DROP TABLE t1; |