当前位置:Gxlcms > 数据库问题 > 关于MySQL Online DDL

关于MySQL Online DDL

时间:2021-07-01 10:21:17 帮助过:33人阅读

二、执行改表操作

mysql> ALTER TABLE employees.employees ADD COLUMN middle_name varchar(14) AFTER first_name;
Query OK, 0 rows affected (9.27 sec)
Records: 0  Duplicates: 0  Warnings: 0

三、查看改表进度

mysql> SELECT EVENT_NAME, WORK_COMPLETED, WORK_ESTIMATED FROM events_stages_current;
+------------------------------------------------------+----------------+----------------+
| EVENT_NAME                                           | WORK_COMPLETED | WORK_ESTIMATED |
+------------------------------------------------------+----------------+----------------+
| stage/innodb/alter table (read PK and internal sort) |            280 |           1245 |
+------------------------------------------------------+----------------+----------------+
1 row in set (0.01 sec)

关于MySQL Online DDL

标签:dev   show   nod   https   否则   sam   tag   创建过程   设置   

人气教程排行