asp查询sql 问题
打开这个页面就显示了所有的数据,查询按钮都还没按呢,是哪里出错了?求大神帮忙<!--#include file="cncc.asp"-->
<body>
<a href="pjcjg1.asp">商品名称查询</a>
<a href="pjcjg2.asp">商家编码查询</a>
</body>
<form method="post">
<tr><td align=center>商品名称:</td><td colspan=2><input type=text name="name1" size=10></td>
<td colspan=3 align=center>☆<input type=submit value="查询">☆</td></tr>
<table style="width:100%;" bordercolor="#000000" cellspacing="0" cellpadding="2" border="1">
<tr>
<td>货号</td><td>条码</td><td>名称</td><td>编码</td><td>进价</td><td>售价</td><td>禁止</td><td>库存</td><td>最少</td>
</tr>
<%
set chs=conn.Execute("SET NAMES 'gb2312'")
str = request.form("name1")
'sql="select * from item where sup_no='"&str&"' order by item_no desc"
sql="select * from item where item_name LIKE '%"&str&"%' order by item_no desc"
set rs=conn.execute(sql)
if not(rs.bof and rs.eof) then
end if
%>
<%
rs.movefirst
while not rs.Eof
response.write("<tr>")
for i=0 to rs.fields.count-1
if i=0 or i=1 or i=2 or i=12 or i=13 or i=15 or i=32 or i=58 or i=65 then
response.write("<td>"&rs(i)&"</td>")
end if
next
response.write("</tr>")
rs.movenext
wend
%>
</table>