mirror of
https://github.com/MariaDB/server.git
synced 2025-02-05 21:32:18 +01:00
![Sergei Golubchik](/assets/img/avatar_default.png)
When adding a column or index that uses plugin-defined sysvar-based options with CREATE ... LIKE the server was using the current value of the sysvar, not the default one. Because parse_option_list() function was used both in create and open and it tried to guess when it's create (need to use current sysvar value and add a new name=value pair to the list) or open (need to use default, without extending the list). Let's move the list extending functionality into a separate function and call it explicitly when needed. Operations that add new objects (CREATE, ALTER ... ADD) will extend the list, other operations (ALTER, CREATE ... LIKE, open) will not.
21 lines
682 B
Text
21 lines
682 B
Text
#
|
|
# MDEV-35144 CREATE TABLE ... LIKE uses current innodb_compression_default instead of the create value
|
|
#
|
|
set innodb_compression_default= off;
|
|
create table t1 (a int, b blob) engine=innodb;
|
|
set innodb_compression_default= on;
|
|
create table s_import like t1;
|
|
show create table t1;
|
|
Table Create Table
|
|
t1 CREATE TABLE `t1` (
|
|
`a` int(11) DEFAULT NULL,
|
|
`b` blob DEFAULT NULL
|
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
|
|
show create table s_import;
|
|
Table Create Table
|
|
s_import CREATE TABLE `s_import` (
|
|
`a` int(11) DEFAULT NULL,
|
|
`b` blob DEFAULT NULL
|
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
|
|
DROP TABLE t1,s_import;
|
|
# End of 10.5 tests
|