Guest User

Untitled

a guest
Nov 19th, 2017
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. Set adoCon = Server.CreateObject("ADODB.Connection")
  2. adoCon.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath(dbfile)
  3. strSQL = "SELECT * FROM Table WHERE name_field LIKE ?"
  4.  
  5. Set cmd1 = Server.CreateObject("ADODB.Command")
  6. cmd1.ActiveConnection = adoCon
  7. cmd1.CommandText = strSQL
  8. cmd1.CommandType = 1 'adCmdText
  9. cmd1.Parameters(0) = Request("odQuery") & "%"
  10. Set rs = cmd1.Execute()
Add Comment
Please, Sign In to add comment