MySQL Bugs: #34354: Feature request: EXPLAIN ALTER TABLE https://bugs.mysql.com/bug.php?id=34354

[SQL]EXPLAIN ALTER TABLE `answer` MODIFY COLUMN `content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '修改字符集为utf8mb4,兼容表情符' AFTER `qid`;
[Err] 1064 - 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 'ALTER TABLE `answer` MODIFY COLUMN `content` text CHARACTER SET utf8mb4 COLLATE' at line 1

MySQL Bugs: #80793: EXTEND EXPLAIN to cover ALTER TABLE https://bugs.mysql.com/bug.php?id=80793

Bug #34354 Feature request: EXPLAIN ALTER TABLE
Submitted: 6 Feb 2008 17:04

MySQL Bugs: #80793: EXTEND EXPLAIN to cover ALTER TABLE https://bugs.mysql.com/bug.php?id=80793

Bug #80793 EXTEND EXPLAIN to cover ALTER TABLE
Submitted: 18 Mar 2016 16:03

MySQL Bugs: #34354: Feature request: EXPLAIN ALTER TABLE https://bugs.mysql.com/bug.php?id=34354

[6 Feb 2008 17:04] Paul Dubois
Description:
In MySQL 5.1, work was done to make some ALTER TABLE operations faster, with no need for a temporary table (such as changes that affect only metadata), as described here: http://dev.mysql.com/doc/refman/5.1/en/alter-table.html However, a user cannot tell in advance whether a given operation will be fast or not, and thus must actually execute ALTER TABLE and hope that it will be fast. An EXPLAIN-style statement would be useful for ALTER TABLE. I envision that EXPLAIN ALTER TABLE would provide information to the user that would indicate the "cost" of a given alteration. How to repeat:
N/A
[6 Feb 2008 19:32] Valeriy Kravchuk
Thank you for a reasonable feature request.
[18 Oct 2016 8:51] Daniël van Eeden
A duplicate of this bug:
Bug #80793 EXTEND EXPLAIN to cover ALTER TABLE
[18 Mar 2016 16:03] Simon Mudd
Description:
ALTER TABLE now has many ways of working and that can be a bit confusing even for a seasoned MySQL DBA especially as things change all the time. How to repeat:
Run ALTER TABLE and see which behaviour happens depending on the statement you execute. There are various possible behaviours: 1. METADATA change, no change to data
2. INLINE change, no full rebuild and apps can use the table while the change is happening (e.g. new indexes being added)
3. TABLE REBUILD, traditional full rebuild of the table Suggested fix:
I'd like to see EXPLAIN EXTENDED to show what it would do with the ALTER TABLE statement. There are other subtle things that may trigger a full rebuild of the table including changes due to data type changes (e.g. the "old" and "new" timestamp or datetime formats), so having a way to see what MySQL would do without actually triggering the action would be really good.
[18 Jun 2016 21:36] Omer Barnir
Posted by developer:

Reported version value updated to reflect release name change from 5.8 to 8.0
[19 Jul 2016 8:06] Umesh Shastry
Hello Simon,

Thank you for the feature request!

Thanks,
Umesh
[16 Oct 2016 19:11] Morgan Tocker
Duplicate of BUG #34354

MySQL Bugs: #34354: Feature request: EXPLAIN ALTER TABLE https://bugs.mysql.com/bug.php?id=34354的更多相关文章

  1. alter table导致的mysql事务回滚失败

    今天做数据迁移, 发现事务有时候可以回滚, 有时候不可以回滚, 最后一点点调试发现中间有段修改表结构的语句, 最终导致回滚失败. 1.MySQL最常用的两个表类型: InnoDB和MyISAM.MyI ...

  2. SQL ALTER TABLE 命令

    SQL ALTER TABLE 命令 SQL ALTER TABLE 命令用于添加.删除或者更改现有数据表中的列. 你还可以用 ALTER TABLE 命令来添加或者删除现有数据表上的约束. 语法: ...

  3. alter table <表名 > add constraint <主键名>用法

    alter table <表名 > add constraint  <主键名>用法介绍 1.主键约束: 要对一个列加主键约束的话,这列就必须要满足的条件就是分空 因为主键约束: ...

  4. 【转】SQL 语句:Alter table

    转载自:http://www.w3school.com.cn/sql/sql_alter.asp ALTER TABLE 语句 ALTER TABLE 语句用于在已有的表中添加.修改或删除列. SQL ...

  5. alter table add constraint 用法

    1.主键约束: 要对一个列加主键约束的话,这列就必须要满足的条件就是分空 因为主键约束:就是对一个列进行了约束,约束为(非空.不重复) 以下是代码   要对一个列加主键,列名为id,表名为emp 格式 ...

  6. alter table添加表约束

    翻阅了一下网上关于alter table添加表约束的资料,学习下,然后供自己以后使用. 仅仅供自己使用... 总结alter table ### add constraint ## 使用方法 添加表约 ...

  7. alter table *** add constraint *** 用法---约束

    1.主键约束:要对一个列加主键约束的话,这列就必须要满足的条件就是分空因为主键约束:就是对一个列进行了约束,约束为(非空.不重复)以下是代码   要对一个列加主键,列名为id,表名为emp 格式为:a ...

  8. 在linux上安装MySQL数据库,并简单设置用户密码,登录MySQL

    在新装的Centos系统上安装MySQL数据库. <p><a href="http://www.cnblogs.com/tijun/">提君博客原创< ...

  9. 《MySQL必知必会》学习笔记——附录A MySQL入门

    附录A MySQL入门 如果你是MySQL的初学者,本附录是一些需要的基础知识. A.1 你需要什么 为使用MySQL和学习本书中各章的内容,你需要访问MySQL服务器和客户机应用(用来访问服务器的软 ...

随机推荐

  1. 【转】C# URL短地址压缩算法及短网址原理解析

    这篇文章主要介绍了C# URL短地址压缩算法及短网址原理解析,本文重点给出了算法代码,需要的朋友可以参考下 短网址应用已经在全国各大微博上开始流行了起来.例如QQ微博的url.cn,新郎的sinaur ...

  2. 配置 -- PHPstorm+Xdebug断点调试PHP

    运行环境: PHPSTORM版本 : 8.0.1 PHP版本 : 5.6.2 xdebug版本:php_xdebug-2.2.5-5.6-vc11-x86_64.dll ps : php版本和xdeb ...

  3. js for form

    //表单填充   表单填充        , formDataLoad: function (domId, obj) {            for (var property in obj) {  ...

  4. Oracle 12c安装详细步骤,带截图

    1,在官网上下载oracle的压缩文件,两个都要下载. 并两个同时选中解压在一个文件夹里面. 2,解压之后,如下图,点击setup.exe稍等一会儿 ,3,开始安装: 不选点击下一步,或者直接点击下一 ...

  5. php HTML安全过滤

    /*HTML安全过滤*/ function _htmtocode($content) { $content = str_replace('%','%‎',$content); $content = s ...

  6. tagVARIANT、VARIANT、_variant_t和COleVariant

    tagVARIANT是一个结构体struct:  C++ Code: tagVARIANT 123456789101112131415161718192021222324252627282930313 ...

  7. mysql中,root用户密码被遗忘,该如何进行重置?

    需求描述: 在mysql的测试环境中,有时候会遇到一段时间之后root用户的密码被遗忘的情况, 这个时候,就是需要对root密码进行重置,不过,在生产环境中,这种情况还是很少见. 环境描述: 操作系统 ...

  8. swift学习笔记之--方法

    一.说明 跟oc一样,面向对象,swift重点额方法可以分为2大类: (1)实例方法 oc中为减号方法(对象方法) (2)类型方法 oc中的加号方法(类方法) 二.实例方法 只能是对象调用的方法 代码 ...

  9. Swift-基础语法之变量&常量&元组

    使用 let来声明一个常量,用 var来声明一个变量.常量的值在编译时并不要求已知,但是你必须为其赋值一次.这意味着你可以使用常量来给一个值命名,然后一次定义多次使用 myVariable = let ...

  10. python中模块,包,库

    模块:就是.py文件,里面定义了一些函数和变量,需要的时候就可以导入这些模块. 包:在模块之上的概念,为了方便管理而将文件进行打包.包目录下第一个文件便是 __init__.py,然后是一些模块文件和 ...