<%
Response.Write "二次检索条件:" & Trim(Request("f")) & "<br/>"
Response.Write "----------------------------------<br/><br/>"
Session("rs").Filter = ""
Session("rs").Filter = Trim(Request("f"))
If not(Session("rs").Eof and Session("rs").Bof) Then Session("rs").MoveFirst
do while not Session("rs").Eof
Response.Write Session("rs")("id") & ":" & Session("rs")("name") & "<br/>"
Session("rs").MoveNext
loop
Response.Write "总计:" & Session("rs").RecordCount & "<br/>"
Response.Write "----------------------------------<br/>"
%>
结果:
参考文章:1.ado多次按条件使用一个记录集中的数据的方法:
http://www.webjx.com/htmldata/2005-08-05/1123195121.html2.ado 记录集对象的filter属性使用中需注意的地方:
http://www.webjx.com/htmldata/2005-12-17/1134812771.html