Hola
Prueba así, usando trasiciones
Código asp:
Ver originalconn.BeginTrans
sql1 = "INSERT INTO ficha_vehicular (codfic,vehicu,gralic) VALUES (" & codfic & ","& vehiculo &"," & licencia &")"
conn.Execute(sql1)
if Err.number <> 0 Then
Response.Clear ()
conn.RollBackTrans
Err.Clear ()
Response.End ()
end if
sql2 = "INSERT INTO ficha_vivienda (codfic,tipvivi) VALUES (" & codfic & ","& vivienda &")"
conn.Execute(sql2)
if Err.number <> 0 Then
Response.Clear ()
conn.RollBackTrans
Err.Clear ()
Response.End ()
end if
conn.CommitTrans
Suerte