急救:这样在ASP中取得存储过程的结果集正确否?
写法如下:
------------------------------
dim rs,sql
sql="sp_index " & id
set rs=conn.Execute(sql) ------取得执行存储过程的结果集
if (rs.bof and rs.eof) then ------判断结果集是否为空
response.write "error!"
else
response.write id
end if
------------------------------
但结果是错误的,为什么?