1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

SQL: truncate syntax and privilege [closes #229]

This commit is contained in:
Eugene Kosov
2017-09-08 10:22:24 +03:00
committed by GitHub
parent 904b69cd9e
commit a49239b57a
46 changed files with 378 additions and 448 deletions

View File

@ -275,15 +275,8 @@ bool mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds,
// trx_sees() in InnoDB reads sys_trx_start
if (!table->versioned_by_sql()) {
if (table_list->vers_conditions.type == FOR_SYSTEM_TIME_BETWEEN ||
table_list->vers_conditions.type == FOR_SYSTEM_TIME_FROM_TO)
{
bitmap_set_bit(table->read_set, table->vers_start_field()->field_index);
}
else if (table_list->vers_conditions.type == FOR_SYSTEM_TIME_BEFORE)
{
bitmap_set_bit(table->read_set, table->vers_end_field()->field_index);
}
DBUG_ASSERT(table_list->vers_conditions.type == FOR_SYSTEM_TIME_BEFORE);
bitmap_set_bit(table->read_set, table->vers_end_field()->field_index);
}
}