mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Fix for bug#14271 I_S: columns has no size for (var)binary columns
set character_octet_length, character_maximum_length for
binary and varbinary field types
mysql-test/r/information_schema.result:
Fix for bug#14271 I_S: columns has no size for (var)binary columns
test case
mysql-test/t/information_schema.test:
Fix for bug#14271 I_S: columns has no size for (var)binary columns
test case
This commit is contained in:
@@ -2616,7 +2616,9 @@ static int get_schema_column_record(THD *thd, struct st_table_list *tables,
|
||||
table->field[6]->store((const char*) pos,
|
||||
strlen((const char*) pos), cs);
|
||||
is_blob= (field->type() == FIELD_TYPE_BLOB);
|
||||
if (field->has_charset() || is_blob)
|
||||
if (field->has_charset() || is_blob ||
|
||||
field->real_type() == MYSQL_TYPE_VARCHAR || // For varbinary type
|
||||
field->real_type() == MYSQL_TYPE_STRING) // For binary type
|
||||
{
|
||||
longlong char_max_len= is_blob ?
|
||||
(longlong) field->max_length() / field->charset()->mbminlen :
|
||||
|
||||
Reference in New Issue
Block a user