You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
执行日志:
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' drop partition p3,p6' at line 1
环境
数据库: mysql
版本: 5.7.24
inception
版本:v1.3.0
The text was updated successfully, but these errors were encountered:
CREATE TABLE t_partition_drop ( id int(11) NOT NULL, p int(11) NOT NULL DEFAULT '0', a int(11) DEFAULT '0',
PRIMARY KEY (id,p),
KEY idx_a (a)
) ENGINE=InnoDB DEFAULT CHARSET=utf8
/*!50500 PARTITION BY RANGE COLUMNS(p)
(PARTITION p3 VALUES LESS THAN (4) ENGINE = InnoDB,
PARTITION p6 VALUES LESS THAN (7) ENGINE = InnoDB) */
描述
一条SQL中先新增分区,后删除分区,语法校验通过,但是执行失败
重现
SQL:
alter table t_partition_drop add partition (partition p9 VALUES LESS THAN (10)), drop partition p3,p6;
语法校验结果:
[{'id': 1, 'stage': 'CHECKED', 'errlevel': 0, 'stagestatus': 'Audit Completed', 'errormessage': '', 'sql': 'USE
cctest
', 'affected_rows': 0, 'sequence': '0_0_00000000', 'backup_dbname': '', 'execute_time': '0', 'sqlsha1': '', 'backup_time': '0', 'actual_affected_rows': ''}, {'id': 2, 'stage': 'CHECKED', 'errlevel': 0, 'stagestatus': 'Audit Completed', 'errormessage': '', 'sql': 'alter table t_partition_drop add partition (partition p9 VALUES LESS THAN (10)), drop partition p3,p6', 'affected_rows': 0, 'sequence': '0_0_00000001', 'backup_dbname': '', 'execute_time': '0', 'sqlsha1': '', 'backup_time': '0', 'actual_affected_rows': ''}]执行日志:
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' drop partition p3,p6' at line 1
环境
The text was updated successfully, but these errors were encountered: