怎么办,大伙帮下忙

yousite1 2005-12-21 05:08:04
sql server数据库字段设为char(1)没填入值时显示为NULL怎么把这些NULL的语句选择出来呢?
用了select * from news where flag=NULL不成功
用select * from news where flag<>'Y'也不成功啊。。。怎么办,大伙帮下忙。
...全文
88 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
hellblazer 2005-12-22
  • 打赏
  • 举报
回复
选NULL的时候不能用=,要用is
wangyingdong 2005-12-21
  • 打赏
  • 举报
回复
最好用0和1表示,这样就不容易出错!!
wangyingdong 2005-12-21
  • 打赏
  • 举报
回复
select * from news where flag is NULL
ybfqlyq 2005-12-21
  • 打赏
  • 举报
回复
select * from news where flag is NULL
yzyun 2005-12-21
  • 打赏
  • 举报
回复

select * from news where flag is null
kgbt 2005-12-21
  • 打赏
  • 举报
回复
你把初始值设为0不就成了吗,或者直接、
update news set flag=0 然后在重新操作不就成了吗

28,391

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧