在asp中,我想将两个表合并因该怎么做啊?例:table1 name riqi table2 name didian生成 table3 name riqi didian 应该怎么做啊希望高手帮帮忙啊,在asp中怎么实现?
參考答案:str="select a.name,a.riqi,b.didian from table1 a inner join table2 b on where a.id=b.id"
rs.open str,conn,1,3,1
rs2.open "table3",conn,1,2,2
for i=1 to rs.recordcount
if not rs.bof and not rs.eof then
rs2.addnew
rs2("name")=rs("name")
rs2("riqi")=rs("riqi")
rs2("didian")=rs("didian")
rs2.update
rs.movenext
else
exit for
end if
next