<%'将大类名称赋值给bigkind数组,从bigkind(1)开始,i为大类总数
'将第n大类的小类名称赋值给smallkind数组,从smallkind(n,1)开始,j(n)为第n大类的小类的总数
set objrst1=server.createobject("adodb.recordset")
set objrst2=server.createobject("adodb.recordset")
i=0
dim bigkind(100)
dim smallkind(100,100)
dim j(100)
for x=1 to 100
j(x)=0
next
sqlstr="select province from sell_province order by province"
if objrst1.state=1 then objrst1.close
objrst1.open sqlstr,objconn,3,4
while not objrst1.eof
i=i+1
bigkind(i)=trim(objrst1("province"))
if objrst2.state=1 then objrst2.close
sqlstr2="select distinct province,city from citys where province='"&objrst1("province")&"' order by city"
objrst2.open sqlstr2,objconn,3,4
while not objrst2.eof
j(i)=j(i)+1
smallkind(i,j(i))=trim(objrst2("city"))
objrst2.movenext
wend
objrst1.movenext
wend
set objrst1=nothing
set objrst2=nothing
%>
....
产品所在地: | | |