sql = "UPDATE YID SET 人员='ee' where 人员='老师'" & vbCr & "UPDATE YID SET 人员='DD' where 人员='学生'"
With cmd
.ActiveConnection = con
.CommandType = adCmdText
.CommandText = sql
.Execute
End With
CommandText="UPDATE YID SET 人员='ee' where 人员='老师';UPDATE YID SET 人员='DD' where 人员='学生'"
或者用数据库连接执行
cn.exec "UPDATE YID SET 人员='ee' where 人员='老师';UPDATE YID SET 人员='DD' where 人员='学生'"