diff options
Diffstat (limited to 'storage/csv')
-rw-r--r-- | storage/csv/ha_tina.cc | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/storage/csv/ha_tina.cc b/storage/csv/ha_tina.cc index 0d9c019a19d..c9fab79a4c5 100644 --- a/storage/csv/ha_tina.cc +++ b/storage/csv/ha_tina.cc @@ -472,14 +472,6 @@ int ha_tina::encode_quote(uchar *buf) const char *ptr; const char *end_ptr; const bool was_null= (*field)->is_null(); - - /* - CSV does not support nulls. ::create() prevents creation of a table - with nullable columns so if we encounter them here, there is a bug. - This may only occur if the frm was created by an older version of - mysqld which permitted table creation with nullable columns. - */ - DBUG_ASSERT(!(*field)->maybe_null()); /* assistance for backwards compatibility in production builds. @@ -1494,7 +1486,10 @@ int ha_tina::create(const char *name, TABLE *table_arg, for (Field **field= table_arg->s->field; *field; field++) { if ((*field)->real_maybe_null()) - DBUG_RETURN(-1); + { + my_error(ER_CHECK_NOT_IMPLEMENTED, MYF(0), "nullable columns"); + DBUG_RETURN(HA_ERR_UNSUPPORTED); + } } |