1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00
This commit is contained in:
ram@gw.mysql.r18.ru
2004-12-17 18:06:05 +04:00
parent 3afd1939f7
commit 92f89369ae
27 changed files with 1051 additions and 41 deletions

View File

@@ -5063,6 +5063,19 @@ bool add_field_to_list(THD *thd, char *field_name, enum_field_types type,
case MYSQL_TYPE_VAR_STRING:
DBUG_ASSERT(0); // Impossible
break;
case MYSQL_TYPE_BIT:
{
if (!length)
new_field->length= 1;
if (new_field->length > MAX_BIT_FIELD_LENGTH)
{
my_error(ER_TOO_BIG_FIELDLENGTH, MYF(0), field_name,
MAX_BIT_FIELD_LENGTH);
DBUG_RETURN(1);
}
new_field->pack_length= (new_field->length + 7) / 8;
break;
}
}
if (!(new_field->flags & BLOB_FLAG) &&