回 帖 发 新 帖 刷新版面

主题:请问conn.execute、rs.open之间的差别有什么不同

1.<% set rs=conn.execute("select * from adv") 
if rs("xuanze15")=2 then
%>
2.<%
       set rs=server.CreateObject("adodb.recordset")
       rs.open "select * from adv",conn,1,1
     %>
 <%if rs("xuanze15")=2 then%>



这两个有什么不同,是不是都可以形成记录集

回复列表 (共3个回复)

沙发

http://www.programfan.com/club/post-237179.html这里

板凳

conn.execute返回一个记录集
rs.open打开一个记录集

3 楼

[quote]http://www.programfan.com/club/post-237179.html这里[/quote]
不是吧?这个帖子也是楼主发的。

不论采用哪种方法,使用完毕后[u][b]立即关闭连接[/b][/u]。

我来回复

您尚未登录,请登录后再回复。点此登录或注册