Dim db As New ADODB.Connectiondb.ConnectionString = "provider=microsoft.jet.oledb.4.0;" & "data source=" & App.Path & "\dev.mdb" db.Opendb.Execute "delete from tablename where index<300 "'将index小于300的记录全部删除
你把想删除的条件放到where 后就可以了Dim cnn As New ADODB.Connection cnn.open = "provider=microsoft.jet.oledb.4.0;" & "data source=" & App.Path & "\dev.mdb" & ";Persist Security Info=False" cnn.Execute "delete from tablename where 条件"
db.Opendb.Execute "delete from tablename where index<300 "'将index小于300的记录全部删除
cnn.open = "provider=microsoft.jet.oledb.4.0;" & "data source=" & App.Path & "\dev.mdb" & ";Persist Security Info=False"
cnn.Execute "delete from tablename where 条件"