我这么写SQL可是提示错误耶......那里不对么??? 请多多指教.......谢谢.... sql="select bmx,count(*) from fazhan where bmd="3" and to_char('yyyymmdd',date_time)="20060323" group by bmx" 提示我说这句语句未结束............
sql="select bmx,count(*) from fazhan where bmd="3" and to_char('yyyymmdd',date_time)="20060323" group by bmx" Set rs = Server.CreateObject("ADODB.RecordSet") rs.Open sql,conn,1,1 num=cint(rs.pagecount) '读出总的条数 do while not rs.eof '如果没有到最后一条 fazhan_num=cint(count(*)) '读出每个部门的发展数 redim total(cint(rs.pagecount),2) for i=1 to num total(i,1)=fazhan_num total(i,2)=rs("bmx") next rs.movenext '记录指针向下移一条 loop