ayue222,好奇怪,我明明看你不在线的图标,可是你又能回答问题?哦,我明白了,你是隐身登录,(*^__^*)
<%
do while Not rsChamber.EOF
Set rsBooking = Server.CreateObject("ADODB.Recordset")
SqlBooking="SELECT IIf(cint((csng(startdate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295>295,cint((csng(startdate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295,295) AS start, IIf(cint((csng(enddate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295<967,cint((csng(enddate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295,967) AS [end], * FROM AllBooking WHERE (enddate>=left(cdate('"&nowdate&"'),10) And startdate<left(cdate('"&nowdate&"')+7,10)) and ID='"&rsChamber("ID")&"' ORDER BY StartDate"
response.write(SqlBooking)'运行程序输出SqlBooking,将SqlBooking拷贝到查询分析器运行,看看你的SqlBooking语句是不是有错误,还是哪个参数没有值
response.end()'不是说运行错误吗,在此处终止程序的运行,看看上面到底有什么错误,测试完毕在屏蔽此语句
%>
如果你还不明白,我也不知道该怎么办了
<%
do while Not rsChamber.EOF
Set rsBooking = Server.CreateObject("ADODB.Recordset")
SqlBooking="SELECT IIf(cint((csng(startdate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295>295,cint((csng(startdate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295,295) AS start, IIf(cint((csng(enddate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295<967,cint((csng(enddate)-csng(cdate(left(cdate('"&nowdate&"'),10))))*24)*4+295,967) AS [end], * FROM AllBooking WHERE (enddate>=left(cdate('"&nowdate&"'),10) And startdate<left(cdate('"&nowdate&"')+7,10)) and ID='"&rsChamber("ID")&"' ORDER BY StartDate"
response.write(SqlBooking)'运行程序输出SqlBooking,将SqlBooking拷贝到查询分析器运行,看看你的SqlBooking语句是不是有错误,还是哪个参数没有值
response.end()'不是说运行错误吗,在此处终止程序的运行,看看上面到底有什么错误,测试完毕在屏蔽此语句
%>
如果你还不明白,我也不知道该怎么办了