<bdo id='EvqnC'></bdo><ul id='EvqnC'></ul>

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

    2. <legend id='EvqnC'><style id='EvqnC'><dir id='EvqnC'><q id='EvqnC'></q></dir></style></legend>

    3. <small id='EvqnC'></small><noframes id='EvqnC'>

        MySQL - 如何按字符串长度选择数据

        MySQL - How to select data by string length(MySQL - 如何按字符串长度选择数据)
        <i id='yfQhr'><tr id='yfQhr'><dt id='yfQhr'><q id='yfQhr'><span id='yfQhr'><b id='yfQhr'><form id='yfQhr'><ins id='yfQhr'></ins><ul id='yfQhr'></ul><sub id='yfQhr'></sub></form><legend id='yfQhr'></legend><bdo id='yfQhr'><pre id='yfQhr'><center id='yfQhr'></center></pre></bdo></b><th id='yfQhr'></th></span></q></dt></tr></i><div id='yfQhr'><tfoot id='yfQhr'></tfoot><dl id='yfQhr'><fieldset id='yfQhr'></fieldset></dl></div>
        1. <tfoot id='yfQhr'></tfoot>

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

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

              <tbody id='yfQhr'></tbody>
              <bdo id='yfQhr'></bdo><ul id='yfQhr'></ul>
                  本文介绍了MySQL - 如何按字符串长度选择数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  SELECT * FROM table ORDER BY string_length(column);
                  

                  是否有 MySQL 函数来执行此操作(当然而不是 string_length)?

                  Is there a MySQL function to do this (of course instead of string_length)?

                  推荐答案

                  您正在寻找 CHAR_LENGTH() 获取字符串中的字符数.

                  You are looking for CHAR_LENGTH() to get the number of characters in a string.

                  对于多字节字符集LENGTH() 将为您提供字符串占用的字节数,而 CHAR_LENGTH() 将返回字符数.

                  For multi-byte charsets LENGTH() will give you the number of bytes the string occupies, while CHAR_LENGTH() will return the number of characters.

                  这篇关于MySQL - 如何按字符串长度选择数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  Bogus foreign key constraint fail(虚假外键约束失败)
                  how to get last insert id after insert query in codeigniter active record(如何在codeigniter活动记录中插入查询后获取最后一个插入ID)
                  Force InnoDB to recheck foreign keys on a table/tables?(强制 InnoDB 重新检查表/表上的外键?)
                  How to auto generate migrations with Sequelize CLI from Sequelize models?(如何使用 Sequelize CLI 从 Sequelize 模型自动生成迁移?)
                  Clear MySQL query cache without restarting server(无需重启服务器即可清除 MySQL 查询缓存)
                  ALTER TABLE to add a composite primary key(ALTER TABLE 添加复合主键)
                1. <legend id='ZkKvl'><style id='ZkKvl'><dir id='ZkKvl'><q id='ZkKvl'></q></dir></style></legend>
                  <tfoot id='ZkKvl'></tfoot>

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

                    <bdo id='ZkKvl'></bdo><ul id='ZkKvl'></ul>
                        <tbody id='ZkKvl'></tbody>

                      1. <small id='ZkKvl'></small><noframes id='ZkKvl'>