想查一下ID是否存在,应该如何实现?
adron 2001-07-13 01:22:11 flag="1"
<%
sql="select id from renlit"
rs.open sql,cn,1,1
do while not rs.eof
if id=rs("id")and flag="1" then
%>
<center>
您的输入出现相同的编号,该操作非法!<p>
<a href="../renli/renin.asp">返回</a>
</center>
<%
flag="0"
end if
rs.movenext
loop
%>
大侠,帮小弟看看,?