mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Merge branch '10.1' into 10.2
This commit is contained in:
@@ -1254,6 +1254,48 @@ execute stmt1;
|
||||
deallocate prepare stmt1;
|
||||
drop table t2;
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-8960 Can't refer the same column twice in one ALTER TABLE
|
||||
--echo #
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL,
|
||||
ALTER COLUMN `consultant_id` DROP DEFAULT;
|
||||
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL,
|
||||
ALTER COLUMN `consultant_id` SET DEFAULT 2;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL DEFAULT 2,
|
||||
ALTER COLUMN `consultant_id` DROP DEFAULT;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL DEFAULT 2,
|
||||
ALTER COLUMN `consultant_id` DROP DEFAULT,
|
||||
MODIFY COLUMN `consultant_id` BIGINT;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
#
|
||||
# Test of ALTER TABLE IF [NOT] EXISTS
|
||||
#
|
||||
@@ -1766,49 +1808,7 @@ SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-8960 Can't refer the same column twice in one ALTER TABLE
|
||||
--echo #
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL,
|
||||
ALTER COLUMN `consultant_id` DROP DEFAULT;
|
||||
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL,
|
||||
ALTER COLUMN `consultant_id` SET DEFAULT 2;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL DEFAULT 2,
|
||||
ALTER COLUMN `consultant_id` DROP DEFAULT;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) DEFAULT CHARSET=utf8;
|
||||
|
||||
ALTER TABLE t1 ADD COLUMN `consultant_id` integer NOT NULL DEFAULT 2,
|
||||
ALTER COLUMN `consultant_id` DROP DEFAULT,
|
||||
MODIFY COLUMN `consultant_id` BIGINT;
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
--echo #
|
||||
--echo # Start of 10.1 tests
|
||||
--echo # End of 10.0 tests
|
||||
--echo #
|
||||
|
||||
--echo #
|
||||
@@ -1829,6 +1829,10 @@ ALTER TABLE t1 DROP INDEX i1, ADD INDEX i1(a) COMMENT 'comment2';
|
||||
SHOW CREATE TABLE t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
--echo #
|
||||
--echo # End of 10.1 tests
|
||||
--echo #
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-10421 duplicate CHECK CONSTRAINTs
|
||||
--echo #
|
||||
@@ -1877,3 +1881,7 @@ alter table t1 drop column a;
|
||||
alter table t1 drop column a, drop index a;
|
||||
show create table t1;
|
||||
drop table t1;
|
||||
|
||||
--echo #
|
||||
--echo # End of 10.2 tests
|
||||
--echo #
|
||||
|
||||
Reference in New Issue
Block a user