获取字段中为空的内容[已解决,呵呵]
老师们:我想查询表中为"空"的内容,我是下面写的,但是错了,怎么改呀?谢谢!
表名:A
字段:B
<%
set rs=Server.CreateObject("ADODB.RecordSet")
sql="select * from A where X = "&trim(request("XX"))&" and B = " ""
rs.open sql,conn,1,1
%>
[[it] 本帖最后由 anjincheng 于 2008-6-11 13:12 编辑 [/it]]
[[it] 本帖最后由 anjincheng 于 2008-6-11 15:06 编辑 [/it]]
[[it] 本帖最后由 anjincheng 于 2008-6-11 15:07 编辑 [/it]]
[[it] 本帖最后由 anjincheng 于 2008-6-11 15:32 编辑 [/it]]
感谢老师! 不行呀老师们
写上去以后不管怎么查都没有数据(但是不提示错误了) X='"&trim(request("XX"))&"' and B='' 老师:我知道是这样的,但是确实不行
我只有用 B IS NULL了
感谢! B=''是用在字符串类型的字段里的
页:
[1]
