diff options
author | Oleksandr Byelkin <sanja@mariadb.com> | 2022-11-03 11:47:10 +0100 |
---|---|---|
committer | Oleksandr Byelkin <sanja@mariadb.com> | 2022-11-03 11:47:10 +0100 |
commit | f8997c68fe645cc94f6730a135aca5e530dec449 (patch) | |
tree | b3d607eb1a106a16b900d7da6af81a60332a7584 /sql/sql_table.cc | |
parent | 49a22c5897823c528d52886f6048d5b4c91e221f (diff) | |
parent | acf8dc0a577f8fed2d059c033f4efbd07dd95ac0 (diff) | |
download | mariadb-git-mariadb-10.10.2.tar.gz |
Merge branch '10.9' into 10.10mariadb-10.10.2
Diffstat (limited to 'sql/sql_table.cc')
-rw-r--r-- | sql/sql_table.cc | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/sql/sql_table.cc b/sql/sql_table.cc index e13bd60d618..25c5fc7d8bb 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -10410,6 +10410,18 @@ do_continue:; DBUG_ASSERT(create_info->default_table_charset); + /* + The ALTER related code cannot alter partitions and change column data types + at the same time. So in case of partition change statements like: + ALTER TABLE t1 DROP PARTITION p1; + we skip implicit data type upgrade (such as "MariaDB 5.3 TIME" to + "MySQL 5.6 TIME" or vice versa according to mysql56_temporal_format). + Note, one can run a separate "ALTER TABLE t1 FORCE;" statement + before or after the partition change ALTER statement to upgrade data types. + */ + if (IF_PARTITIONING(!fast_alter_partition, 1)) + Create_field::upgrade_data_types(alter_info->create_list); + if (create_info->check_fields(thd, alter_info, table_list->table_name, table_list->db) || create_info->fix_period_fields(thd, alter_info)) |