[求助]我的ASP站发生不可理解的时间语句错误.请帮忙改正,大恩不言谢!
错误如下:
HTTP 500.100 - 內部伺服器錯誤 - ASP 錯誤
Internet Information Services
--------------------------------------------------------------------------------
技術資訊 (供技術支援人員使用)
錯誤類型:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
[Microsoft][ODBC Microsoft Access Driver] 查詢運算式 'time < #2004/9/26 下午 12:17:11#' 中的 日期語法錯誤。
/online.asp, line 10
瀏覽器類型:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0; (R1 1.5))
頁數:
GET /reg.asp
错误中所提到的ONLINE.ASP的源码如下:
<%
dim nowtime,connhs,kk,sqlhs,rsk,DBPathhs
nowtime=Now()
Set connhs = Server.CreateObject("ADODB.connection")
DBPathhs = Server.MapPath("isi/xlist.asp")
connhs.Open "driver={Microsoft Access Driver (*.mdb)};dbq=" & DBPathhs
'-----------------------------------------------------------------
sqlhs="delete from online where time < #"& DateAdd("n", -20 , nowtime) & "#"
connhs.Execute sqlhs
if isempty(session("u_id")) or session("u_id")="" or session("u_id")=1 then
kk=1
else
kk=session("u_id")
end if
if kk<>1 then
Set rsk = Server.CreateObject("ADODB.Recordset")
sqlhs="select * from online where user_id=" & kk
rsk.open sqlhs,connhs,3,2
if rsk.eof or rsk.bof then
rsk.addnew
rsk("user_id") = kk
end if
rsk("time") =nowtime
rsk.update
rsk.close
set rsk=nothing
end if
connhs.close
set connhs=nothing
%>
请好心的大侠帮忙修改吧??