• <tfoot id='k4r8V'></tfoot>

    <small id='k4r8V'></small><noframes id='k4r8V'>

        • <bdo id='k4r8V'></bdo><ul id='k4r8V'></ul>

      1. <i id='k4r8V'><tr id='k4r8V'><dt id='k4r8V'><q id='k4r8V'><span id='k4r8V'><b id='k4r8V'><form id='k4r8V'><ins id='k4r8V'></ins><ul id='k4r8V'></ul><sub id='k4r8V'></sub></form><legend id='k4r8V'></legend><bdo id='k4r8V'><pre id='k4r8V'><center id='k4r8V'></center></pre></bdo></b><th id='k4r8V'></th></span></q></dt></tr></i><div id='k4r8V'><tfoot id='k4r8V'></tfoot><dl id='k4r8V'><fieldset id='k4r8V'></fieldset></dl></div>
      2. <legend id='k4r8V'><style id='k4r8V'><dir id='k4r8V'><q id='k4r8V'></q></dir></style></legend>

        在 mysql 中为视图创建注释

        时间:2024-04-15

          <small id='OJHCi'></small><noframes id='OJHCi'>

            • <legend id='OJHCi'><style id='OJHCi'><dir id='OJHCi'><q id='OJHCi'></q></dir></style></legend>
                <tbody id='OJHCi'></tbody>
                <bdo id='OJHCi'></bdo><ul id='OJHCi'></ul>
                <i id='OJHCi'><tr id='OJHCi'><dt id='OJHCi'><q id='OJHCi'><span id='OJHCi'><b id='OJHCi'><form id='OJHCi'><ins id='OJHCi'></ins><ul id='OJHCi'></ul><sub id='OJHCi'></sub></form><legend id='OJHCi'></legend><bdo id='OJHCi'><pre id='OJHCi'><center id='OJHCi'></center></pre></bdo></b><th id='OJHCi'></th></span></q></dt></tr></i><div id='OJHCi'><tfoot id='OJHCi'></tfoot><dl id='OJHCi'><fieldset id='OJHCi'></fieldset></dl></div>

                <tfoot id='OJHCi'></tfoot>
                1. 本文介绍了在 mysql 中为视图创建注释的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我看到视图和常规表一样有一个注释字段,但默认情况下填充了VIEW"值.

                  I see that the views have a comment field just like the regular tables, but is by default populated with the "VIEW" value.

                  [TABLE_CATALOG] => 
                  [TABLE_SCHEMA] => xxx
                  [TABLE_NAME] => view__xxxx
                  [TABLE_TYPE] => VIEW
                  [ENGINE] => 
                  [VERSION] => 
                  [ROW_FORMAT] => 
                  [TABLE_ROWS] => 
                  [AVG_ROW_LENGTH] => 
                  [DATA_LENGTH] => 
                  [MAX_DATA_LENGTH] => 
                  [INDEX_LENGTH] => 
                  [DATA_FREE] => 
                  [AUTO_INCREMENT] => 
                  [CREATE_TIME] => 
                  [UPDATE_TIME] => 
                  [CHECK_TIME] => 
                  [TABLE_COLLATION] => 
                  [CHECKSUM] => 
                  [CREATE_OPTIONS] => 
                  [TABLE_COMMENT] => VIEW
                  

                  当我尝试创建带有评论的视图时,出现错误.

                  When I am trying to create a view with a comment I get an error.

                  CREATE OR REPLACE VIEW view__x AS
                  SELECT 
                   * 
                  FROM `some_table`  
                  COMMENT = 'some comment'
                  

                  有没有办法修改评论字段,或者该字段在内部用于其他用途并且应该保持原样?

                  Is there a way to modify the comment field or that field is used internally for something else and should stay like it is?

                  我已向 mysql 添加了功能请求.

                  I've added a feature request to mysql.

                  推荐答案

                  根据创建视图的语法,目前无法为视图添加评论:

                  According to the create view syntax there is no way currently to add comment a view:

                  • http://dev.mysql.com/doc/refman/5.7/en/create-view.html

                  此功能已被多次请求.有四张与此功能相关的有效工单:

                  This feature has been requested several times. There are four active tickets related to this functionality:

                  • http://bugs.mysql.com/bug.php?id=5159莉>
                  • http://bugs.mysql.com/bug.php?id=64045莉>
                  • http://bugs.mysql.com/bug.php?id=52429莉>
                  • http://bugs.mysql.com/bug.php?id=15344莉>

                  ...还有几个标记为重复:http://bugs.mysql.com/bug.php?id=19602 , http://bugs.mysql.com/bug.php?id=19602 , http://bugs.mysql.com/bug.php?id=13109, http://bugs.mysql.com/bug.php?id=14369 , http://bugs.mysql.com/bug.php?id=11082, http://bugs.mysql.com/bug.php?id=42870 , http://bugs.mysql.com/bug.php?id=38137, http://bugs.mysql.com/bug.php?id=38137 , http://bugs.mysql.com/bug.php?id=30729

                  ...and several marked as duplicates: http://bugs.mysql.com/bug.php?id=19602 , http://bugs.mysql.com/bug.php?id=19602 , http://bugs.mysql.com/bug.php?id=13109 , http://bugs.mysql.com/bug.php?id=14369 , http://bugs.mysql.com/bug.php?id=11082 , http://bugs.mysql.com/bug.php?id=42870 , http://bugs.mysql.com/bug.php?id=38137 , http://bugs.mysql.com/bug.php?id=38137 , http://bugs.mysql.com/bug.php?id=30729

                  如果您对此问题感兴趣,请前往四个活动的工单,单击影响我"按钮,并添加评论,询问是否有人正在研究此功能.

                  If you are interested in this issue, go to the four active tickets, click the "affects me" button, and also add a comment, asking if anyone is working on this feature.

                  这将增加可见性,并增加实施的可能性.

                  This will add visibility, and increase the likelyhood of it being implemented.

                  这篇关于在 mysql 中为视图创建注释的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:使用自动递增的 id 列创建 MySQL 视图 下一篇:使用 UNION 运算符在 SQL 视图上创建索引?它真的会提高性能吗?

                  相关文章

                2. <small id='iMbvd'></small><noframes id='iMbvd'>

                      • <bdo id='iMbvd'></bdo><ul id='iMbvd'></ul>

                    1. <i id='iMbvd'><tr id='iMbvd'><dt id='iMbvd'><q id='iMbvd'><span id='iMbvd'><b id='iMbvd'><form id='iMbvd'><ins id='iMbvd'></ins><ul id='iMbvd'></ul><sub id='iMbvd'></sub></form><legend id='iMbvd'></legend><bdo id='iMbvd'><pre id='iMbvd'><center id='iMbvd'></center></pre></bdo></b><th id='iMbvd'></th></span></q></dt></tr></i><div id='iMbvd'><tfoot id='iMbvd'></tfoot><dl id='iMbvd'><fieldset id='iMbvd'></fieldset></dl></div>

                      <legend id='iMbvd'><style id='iMbvd'><dir id='iMbvd'><q id='iMbvd'></q></dir></style></legend>

                      <tfoot id='iMbvd'></tfoot>