diff options
author | unknown <bar@mysql.com> | 2004-11-08 14:23:14 +0400 |
---|---|---|
committer | unknown <bar@mysql.com> | 2004-11-08 14:23:14 +0400 |
commit | 06cf873d8f14b6963e2cccf5ca4a214caeb94977 (patch) | |
tree | 8f54723f7ba5e7dd0e74fed10c13366449cbee70 /sql/field_conv.cc | |
parent | bf14010d517460de1e6fa4b342b93917135c0818 (diff) | |
download | mariadb-git-06cf873d8f14b6963e2cccf5ca4a214caeb94977.tar.gz |
alter_table.result, alter_table.test, field_conv.cc:
Bug #6479 ALTER TABLE ... changing charset fails for TEXT columns
Fix: use do_conv_blob rather than do_copy_blob
if the column's character sets are different.
sql/field_conv.cc:
Bug #6479 ALTER TABLE ... changing charset fails for TEXT columns
Fix: use do_conv_blob rather than do_copy_blob
if the column's character sets are different.
mysql-test/t/alter_table.test:
Bug #6479 ALTER TABLE ... changing charset fails for TEXT columns
Fix: use do_conv_blob rather than do_copy_blob
if the column's character sets are different.
mysql-test/r/alter_table.result:
Bug #6479 ALTER TABLE ... changing charset fails for TEXT columns
Fix: use do_conv_blob rather than do_copy_blob
if the column's character sets are different.
Diffstat (limited to 'sql/field_conv.cc')
-rw-r--r-- | sql/field_conv.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/field_conv.cc b/sql/field_conv.cc index 890687fc925..8a36fcd153c 100644 --- a/sql/field_conv.cc +++ b/sql/field_conv.cc @@ -475,6 +475,8 @@ void (*Copy_field::get_copy_func(Field *to,Field *from))(Copy_field*) { if (!(from->flags & BLOB_FLAG)) return do_conv_blob; + if (from->charset() != to->charset()) + return do_conv_blob; if (from_length != to_length || to->table->db_low_byte_first != from->table->db_low_byte_first) { |