如何update一个字段的值为null 如何update一个字段的值为null??不是空串'',也不是字符串'null'。谁知道??? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 update tblname set 字段=null where condition; 直接用常量Null就行了。mysql> select * from t5 where id=20;+------+---------------+| id | c1 |+------+---------------+| 20 | http://123123 |+------+---------------+1 row in set (0.00 sec)mysql> update t5 set c1=null where id=20;Query OK, 1 row affected (0.16 sec)Rows matched: 1 Changed: 1 Warnings: 0mysql> select * from t5 where id=20;+------+------+| id | c1 |+------+------+| 20 | NULL |+------+------+1 row in set (0.00 sec)mysql> update tt set f1=null 发表于:2009-05-19 08:35:193楼 得分:0 update tt set f1=null MySQLWorkbench.exe - . NET Framework Initialization Error MySQL菜鸟问题 我的存储过程循环不了 数据库表这样设计怎么样? 求一句SQL(去除表中只出现过一次行) MySQL 安装后无法登入怎么办? MySql ADO.NET连接 gbk不支持如何处理? mysql通过odbc连接,用vc编程。程序运行的过程中提示:无效游标。 多用户程序中为什么要每用户都开一个连接?只用一个不行吗? MySQL关于latin1存储汉字的问题 一条SQL查询结果集异常 postgresql中文增强版
+------+---------------+
| id | c1 |
+------+---------------+
| 20 | http://123123 |
+------+---------------+
1 row in set (0.00 sec)mysql> update t5 set c1=null where id=20;
Query OK, 1 row affected (0.16 sec)
Rows matched: 1 Changed: 1 Warnings: 0mysql> select * from t5 where id=20;
+------+------+
| id | c1 |
+------+------+
| 20 | NULL |
+------+------+
1 row in set (0.00 sec)mysql>
update tt set f1=null