当前位置:编程学习 > C#/ASP.NET >>

新手请教网上书店系统会员注册代码问题


if request.cookies(cookieName)("username")="" then
response.Redirect "reg.asp"
response.End
end if
set rs=server.CreateObject("adodb.recordset")

if NOT isempty(request("SaveSubmit")) then
dim username
username=request.cookies(cookieName)("username")
rs.open "select useremail,realname,quesion,answer from [user] where username='"&username&"'",conn,1,3
rs("useremail")=trim(request("useremail"))
rs("realname")=trim(request("realname"))
rs("quesion")=trim(request("quesion"))
if trim(request("answer"))<>""then
rs("answer")=trim(request("answer"))
end if
rs.update
rs.close
end if


rs.open "select useremail,vip,identify,quesion,realname from [user] where username='"&request.cookies(cookieName)("username")&"' ",conn,1,1
rs.open "select useremail,vip,identify,quesion,realname from [user] where username='timesshop' ",conn,1,1
Dim Rank
Rank="普通会员"
If rs("vip")=true then
Rank = "VIP会员"
End if
实现时候总显示不能把NULL值插入到‘VIP’中,INSERT失败!哪位高手给看看吧!谢谢了 --------------------编程问答-------------------- vip字段值不能为空 --------------------编程问答-------------------- 那null换成“” --------------------编程问答-------------------- Rangk=DBType.null(这指数据库的NULL值)
补充:.NET技术 ,  C#
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,