验证C#里写的放string型的SQL语句是否正确.然后输送到SQLserver里去
else{Session["UserLogin"]=userModel;Stringuserid="updateTB_USERsetlastLoginIP='"+Comm...
else
{
Session["UserLogin"] = userModel;
String userid= "update TB_USER set lastLoginIP = '"+Common.HttpContextIPAddress.getIP()+"' , lastLoginDate = '"+DateTime.Now+"' where userID="+userID+"";
if()
{
}
Maticsoft.DBUtility.DbHelperSQL.ExecuteSql(userid);
this.ClientScript.RegisterStartupScript(this.GetType(), "", "<script type=\"text/javascript\">window.top.location.href='" + (string.IsNullOrEmpty(url) ? "../user/UserManager.aspx" : url) + "';</script>");
}
在上面的if里改怎么写..还有Maticsoft.DBUtility.DbHelperSQL.ExecuteSql(userid);这句要修改吗 展开
{
Session["UserLogin"] = userModel;
String userid= "update TB_USER set lastLoginIP = '"+Common.HttpContextIPAddress.getIP()+"' , lastLoginDate = '"+DateTime.Now+"' where userID="+userID+"";
if()
{
}
Maticsoft.DBUtility.DbHelperSQL.ExecuteSql(userid);
this.ClientScript.RegisterStartupScript(this.GetType(), "", "<script type=\"text/javascript\">window.top.location.href='" + (string.IsNullOrEmpty(url) ? "../user/UserManager.aspx" : url) + "';</script>");
}
在上面的if里改怎么写..还有Maticsoft.DBUtility.DbHelperSQL.ExecuteSql(userid);这句要修改吗 展开
3个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询