1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

MDEV-35856 Remove error code introduced to 10.11 in MDEV-36032

Two new error codes ER_SEQUENCE_TABLE_HAS_TOO_FEW_ROWS and
ER_SEQUENCE_TABLE_HAS_TOO_MANY_ROWS were introduced in MDEV-36032 in
both 10.11 and, as part of MDEV-22491, 12.0. Here we remove them from
10.11, but they should remain in 12.0.
This commit is contained in:
Yuchen Pei
2025-06-04 15:16:54 +10:00
parent 28d6530571
commit 11d1ac7285
4 changed files with 12 additions and 16 deletions

View File

@@ -12159,9 +12159,9 @@ copy_data_between_tables(THD *thd, TABLE *from, TABLE *to, bool ignore,
from->file->stats.records != 1)
{
if (from->file->stats.records > 1)
my_error(ER_SEQUENCE_TABLE_HAS_TOO_MANY_ROWS, MYF(0));
my_error(ER_INTERNAL_ERROR, MYF(0), "More than one row in the table");
else
my_error(ER_SEQUENCE_TABLE_HAS_TOO_FEW_ROWS, MYF(0));
my_error(ER_INTERNAL_ERROR, MYF(0), "Fewer than one row in the table");
goto err;
}
for (Field **ptr=to->field ; *ptr ; ptr++)
@@ -12349,7 +12349,7 @@ copy_data_between_tables(THD *thd, TABLE *from, TABLE *to, bool ignore,
}
if (to->s->table_type == TABLE_TYPE_SEQUENCE && found_count == 1)
{
my_error(ER_SEQUENCE_TABLE_HAS_TOO_MANY_ROWS, MYF(0));
my_error(ER_INTERNAL_ERROR, MYF(0), "More than one row in the table");
error= 1;
break;
}
@@ -12374,7 +12374,7 @@ copy_data_between_tables(THD *thd, TABLE *from, TABLE *to, bool ignore,
if (to->s->table_type == TABLE_TYPE_SEQUENCE && found_count == 0)
{
my_error(ER_SEQUENCE_TABLE_HAS_TOO_FEW_ROWS, MYF(0));
my_error(ER_INTERNAL_ERROR, MYF(0), "Fewer than one row in the table");
error= 1;
}