眼角膜增生手术多少钱:小弟学ASP遇到点问题,请高手指点.谢谢!

来源:百度文库 编辑:查人人中国名人网 时间:2024/04/30 03:12:36
代码如下:
Dim conn,connstr
Set conn=Server.CreateObject("ADODB.Connection")
connstr= "Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&Server.MapPath("wwwlink.mdb")
conn.Open connstr
'以下添加记录:
Dim Varname,theURL,introd,submitdate,strSql
Varname=Request.Form("names")
theURL=Request.Form("address")
introd=Request.Form("introduction")
submitdate=Request.Form("date")
strSql="Insert Into link(name,URL,submit_date,intro) Vaues('"&Varname&"','"&theURL&"',#"&submitdate&"#,'"&introd&"')"
conn.Execute(strSql)
Response.Write "已经成功添加!"

错误显示:
Microsoft JET Database Engine 错误 '80040e14'

INSERT INTO 语句的语法错误。

/www/link/add.asp,行 23

strSql里的"Vaues"应该 是"Values"

你最好能把SQL先打印出来看看,如:response.write strSql
可能你得到的是一个空值,而你的数量表字段的定义又是不为空的;
谢谢!