<%
Dim con,rs
set con=Server.CreateObject("adodb.connection")
con.open"Provider=Microsoft.Jet.OLEDB.4.0;"& _
"Data Source=" & Server.MapPath("数据库所在路径")
set rs=Server.CreateObject("adodb.recordset")
Dim strWhere,strSQL,strKeyWord
strKeyWord=request("KeyWord")
strWhere="1=1"
strWhere=strWhere&strKeyWord
strSQL="select * from table where Telephone="&strWhere
rs.open strSQL,con,1,1
if not(rs.bof and rs.eof then
While not rs.eof
response.write("<Table>")
response.write("<tr><td>"& rs("TelePhone")& "</td></tr>")
response.write("</Table>")
rs.movenext
wend
else
response.write("没有记录")
response.end()