Microsoft VBScript 编译器错误 错误 '800a03f6' 我在xp操作系统上没发现问题,在2000操作系统上才有的

来源:百度知道 编辑:UC知道 时间:2024/06/15 03:26:58
Microsoft VBScript 编译器错误 错误 '800a03f6'

缺少 'End'

/iisHelp/common/500-100.asp,行242

Microsoft OLE DB Provider for ODBC Drivers 错误 '80040e14'

[Microsoft][ODBC Microsoft Access Driver] 日期的语法错误 在查询表达式 'name like '%王春飚%' and date = #2007-2-3# and time > #下午 12:00:00#' 中。

/qiandao/save.asp,行43
<%
tdate=date()
ttime=#12:00:00#
Set conn = Server.CreateObject("ADODB.Connection")
DBPath = Server.MapPath("data.mdb")
conn.Open "driver={Microsoft Access Driver (*.mdb)};dbq=" & DBPath
Set rs = Server.CreateObject("ADODB.Recordset")
if time() < ttime then
shx=true
sql="select * from data where name like '%"&tname&"%' and date = #"&tdate&"# and time < #"&ttime&"# "
else
shx=flase
sql="select * from data where name like '%"&tname&

xp操作系统的时间格式是正确的 2007-2-3 12:00:00
而2000的时间就会多余的变成 2007-2-3 下午 12:00:00

所以要在代码中把“下午”两字去掉

ttime=#12:00:00#
改成
ttime="12:00:00"