简体   繁体   English

如何使用外键禁用InnoDB的MySQL注释?

[英]How to disable MySQL comments for InnoDB with foreign keys?

For some time I noticed that MySQL would append comments to InnoDB tables that have foreign keys defined. 有一段时间我注意到MySQL会将注释附加到定义了外键的InnoDB表中。 It looks like this: 它看起来像这样:

InnoDB free: 0 kB; ( event_id ) REFER events ( event_id ) ON U...

In order to display my table description correctly, I have to parse string and split it by semicolon. 为了正确显示我的表描述,我必须解析字符串并用分号分割它。 It is not big deal in general, however it's quite annoying to see this messages all the time in Database GUI. 一般来说这不是什么大问题,但是在Database GUI中一直看到这些消息是非常烦人的。

I went through stackoverflow and found this question which was not very handy in my case, so I'm wandering is it possible to disable this behaviour/bug? 我经历了stackoverflow,发现这个问题在我的情况下不是很方便,所以我在徘徊是否有可能禁用这个行为/ bug?

UPDATE: MySQL version installed on hosting provider servers is 5.0.77 更新:托管提供商服务器上安装的MySQL版本是5.0.77

I found this question in MySQL official forum. 我在MySQL官方论坛上发现了这个问题。 It seems that MySQL engineers know the problem but aren't fixing it. 似乎MySQL工程师知道这个问题,但没有修复它。 http://forums.mysql.com/read.php?22,49710,49710#msg-49710 http://forums.mysql.com/read.php?22,49710,49710#msg-49710

I'm not sure I'm in the position to negotiate a change in the InnoDB storage engine, however if you ask me as a user and a MySQL developer I'd say: yes, change this as soon as you can. 我不确定我是否可以协商InnoDB存储引擎的更改,但是如果你问我作为用户和MySQL开发人员我会说:是的,请尽快更改。 The free space info does not belong in the table comment. 可用空间信息不属于表注释。 .. Mike Lischke, Senior Software Engineer MySQL Developer Tools Oracle Corporation, www.oracle.com .. .. Mike Lischke,MySQL开发人员工具高级软件工程师Oracle Corporation,www.oracle.com ..

- -

some applications will break when we move the info from the comment to Data_free. 当我们将信息从评论移动到Data_free时,某些应用程序将会中断。 And users will need to learn a new way to check the free space. 用户需要学习一种检查可用空间的新方法。 Thus, the change can only take place in a new major version. 因此,更改只能在新的主要版本中进行。 Heikki Oracle Corp./Innobase Oy InnoDB - transactions, row level locking, and foreign keys for MySQL Heikki Oracle Corp./Innobase Oy InnoDB - MySQL的事务,行级锁定和外键

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM