Dim sPath As String
 sPath = Text1.Text
 Dim db As New ADODB.Connection
 Dim rs As New ADODB.RecordsetIf Text1 = "" Then
MsgBox "请选择文件路径", 48, "终检管理系统"
Exit Sub
 End If db.Open "Provider=Microsoft.ace.OLEDB.12.0;Data Source=" & App.Path & "\storage.accdb" & ";Persist Security Info=False"
 Call db.Execute("INSERT into 临时表 SELECT * From [Sheet1$] In '" & sPath & "' 'excel 8.0;'")
 db.Close
  Set db = Nothing
  Adodc1.ConnectionString = "Provider=Microsoft.ace.OLEDB.12.0;Data Source=" & App.Path & "\storage.accdb" & ";Persist Security Info=False"
  Adodc1.RecordSource = "select * from 终检档案 inner join 临时表 on  终检档案.管号= 临时表.管号 and  终检档案.批号= 临时表.批号"
  Adodc1.Refresh
  
  If Adodc1.Recordset.RecordCount > 0 Then
  MsgBox "数据重复", 48, "终检管理系统 "
  cnn.Execute ("delete from 临时表")
 
  Else
 db.Open "Provider=Microsoft.ace.OLEDB.12.0;Data Source=" & App.Path & "\storage.accdb" & ";Persist Security Info=False"
 Call db.Execute("INSERT into 终检档案 SELECT * From [Sheet1$] In '" & sPath & "' 'excel 8.0;'")
 MsgBox "导入成功", vbOKOnly, "提示"
 db.Close
 Set db = Nothing
 cnn.Execute ("delete from 临时表")
 End If
 
 Text1 = ""
以上代码是 excel导入ACCESS中,同样导SQL代码怎样更改sql