% response.buffer=true g=request("g") SET RS = SERVER.CREATEOBJECT("ADODB.RECORDSET") SET RS1 = SERVER.CREATEOBJECT("ADODB.RECORDSET") sql = "select id from Discuss where Discuss_Show=1 order by S_Date" RS.OPEN sql,Conn,3,3 i=1 while not rs.eof if i=1 then id=rs(0) else id=cstr(id) + "," + cstr(rs(0)) end if rs.movenext i=i+1 wend date1=date() sql1 = "select id from Discuss where S_Date<='"& date1 &"'and E_Date>='"& date1 &"'and Discuss_Show=0 order by S_Date" RS1.OPEN sql1,Conn,3,3 while not rs1.eof if i=1 then id=rs1(0) else id=cstr(id) + ","+ cstr(rs1(0)) end if rs1.movenext i=i+1 wend no1=rs.recordcount+rs1.recordcount if (rs.recordcount+rs1.recordcount)>1 then url="talk1.asp?id="& id &"&no1="& cstr(no1) else url="talk2.asp?gg=1&id="& id &"&no1="& cstr(no1) end if %>