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

    <tfoot id='L2G6m'></tfoot>
    <legend id='L2G6m'><style id='L2G6m'><dir id='L2G6m'><q id='L2G6m'></q></dir></style></legend>

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

        在 MySQL 中将值设置为 NULL

        Set value to NULL in MySQL(在 MySQL 中将值设置为 NULL)
      1. <tfoot id='ENRpX'></tfoot>

          <tbody id='ENRpX'></tbody>
      2. <small id='ENRpX'></small><noframes id='ENRpX'>

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

                  本文介绍了在 MySQL 中将值设置为 NULL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  如果我提交的表单的文本框中没有放入任何内容,我希望将一个值设置为 NULL.我怎样才能做到这一点?我试过插入 'NULL' 但这只是将 NULL 这个词添加到字段中.

                  I want a value to be set to NULL if nothing is put into the text box in the form I'm submitting. How can I make this happen? I've tried inserting 'NULL' but this just adds the word NULL into the field.

                  我不确定我应该为此提供什么代码,我只是在写一个 UPDATE 查询.

                  I'm not sure what code I should provide for this, I'm just writing an UPDATE query.

                  推荐答案

                  不要将 NULL 放在更新语句中的引号内.这应该有效:

                  Don't put NULL inside quotes in your update statement. This should work:

                  UPDATE table SET field = NULL WHERE something = something
                  

                  这篇关于在 MySQL 中将值设置为 NULL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

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

                  相关文档推荐

                  ibtmp1是非压缩的innodb临时表的独立表空间,通过innodb_temp_data_file_path参数指定文件的路径,文件名和大小,默认配置为ibtmp1:12M:autoextend,也就是说在文件系统磁盘足够的情况下,这个文件大小是可以无限增长的。 为了避免ibtmp1文件无止境的暴涨导致
                  SQL query to group by day(按天分组的 SQL 查询)
                  What does SQL clause quot;GROUP BY 1quot; mean?(SQL 子句“GROUP BY 1是什么意思?意思是?)
                  MySQL groupwise MAX() returns unexpected results(MySQL groupwise MAX() 返回意外结果)
                  MySQL SELECT most frequent by group(MySQL SELECT 按组最频繁)
                  Include missing months in Group By query(在 Group By 查询中包含缺失的月份)
                1. <i id='9DbR6'><tr id='9DbR6'><dt id='9DbR6'><q id='9DbR6'><span id='9DbR6'><b id='9DbR6'><form id='9DbR6'><ins id='9DbR6'></ins><ul id='9DbR6'></ul><sub id='9DbR6'></sub></form><legend id='9DbR6'></legend><bdo id='9DbR6'><pre id='9DbR6'><center id='9DbR6'></center></pre></bdo></b><th id='9DbR6'></th></span></q></dt></tr></i><div id='9DbR6'><tfoot id='9DbR6'></tfoot><dl id='9DbR6'><fieldset id='9DbR6'></fieldset></dl></div>
                      • <bdo id='9DbR6'></bdo><ul id='9DbR6'></ul>

                        <small id='9DbR6'></small><noframes id='9DbR6'>

                        <tfoot id='9DbR6'></tfoot>

                        <legend id='9DbR6'><style id='9DbR6'><dir id='9DbR6'><q id='9DbR6'></q></dir></style></legend>

                            <tbody id='9DbR6'></tbody>