Set Rs = Server.CreateObject("ADODB.Recordset")
Rs.Open "select * from 表三", conn, 2, 3
Do While Not Rs.EOF
DoCmd.RunSQL ("insert into 单子 (单号)values('" & 表三.单号 & "')")//执行句
Loop
Rs.Close
rs.open "select * from table1 where id<10" , conn,2,3
do while not rs.eof
debug.print rs.fields(0).value
loop
[/Quote]
本人新手,能说细一点吗比如我想达到以下效果
rs.open "select 字段2 from table1 " , conn,2,3
do while not rs.eof
update 表2 set 字段1='aa' where 字段2=tabel1.字段2
loop