diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2020-10-30 11:15:30 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2020-10-30 11:15:30 +0200 |
commit | 898521e2dd8a4a6706cba01b6ef0a7cea4114fd0 (patch) | |
tree | 4ef9a6ddc4298574bb75db673c2412f83c107c5b /sql/sql_update.cc | |
parent | 571bcf9aaaf59b84e24bbfb809738dea25495d78 (diff) | |
parent | 199863d72b7cccaa4c75641c50c45a83b568ab8c (diff) | |
download | mariadb-git-898521e2dd8a4a6706cba01b6ef0a7cea4114fd0.tar.gz |
Merge 10.4 into 10.5
Diffstat (limited to 'sql/sql_update.cc')
-rw-r--r-- | sql/sql_update.cc | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/sql/sql_update.cc b/sql/sql_update.cc index 2d360849928..9e6a1cd3bb4 100644 --- a/sql/sql_update.cc +++ b/sql/sql_update.cc @@ -189,6 +189,13 @@ static bool check_fields(THD *thd, TABLE_LIST *table, List<Item> &items, my_error(ER_IT_IS_A_VIEW, MYF(0), table->table_name.str); return TRUE; } + if (thd->lex->sql_command == SQLCOM_UPDATE_MULTI) + { + my_error(ER_NOT_SUPPORTED_YET, MYF(0), + "updating and querying the same temporal periods table"); + + return true; + } DBUG_ASSERT(thd->lex->sql_command == SQLCOM_UPDATE); for (List_iterator_fast<Item> it(items); (item=it++);) { @@ -419,6 +426,14 @@ int mysql_update(THD *thd, DBUG_PRINT("info", ("Switch to multi-update")); /* pass counter value */ thd->lex->table_count= table_count; + if (thd->lex->period_conditions.is_set()) + { + my_error(ER_NOT_SUPPORTED_YET, MYF(0), + "updating and querying the same temporal periods table"); + + DBUG_RETURN(1); + } + /* convert to multiupdate */ DBUG_RETURN(2); } |