ASP Source Code:
<%Option Explicit%>
<!--#include file="ADOsetup.inc"-->
<%
DIM strSearch,strSQL
strSearch = Request.QueryString("txtSearch")
strSQL = "Select * from Customers WHERE Country = '" & strSearch & "'"
ADOrs.Open strSQL, ADOcn
%>
<H2>Search Results (Version 2)</H2><BR>
<H3>Where Country = [<%=strSearch%>]<BR><BR></H3>
<table border="1" width="80%">
<tr>
<th>Name</th>
<th>Company</th>
<th>City</th>
</tr>
<%do until ADOrs.EOF%>
<tr>
<td><%=(ADOrs.Fields("ContactName").Value)%>
<td><%=(ADOrs.Fields("CompanyName").Value)%>
<td><%=(ADOrs.Fields("City").Value)%>
<%ADOrs.MoveNext%>
</tr>
<%loop%>
</table>
<!--#include file="ADOclose.inc"-->