ADODB Command failing Execute with parameterised SQL query
问题 I have the following JScript code: var conn = new ActiveXObject ("ADODB.Connection"); conn.Open("Driver={MySQL ODBC 5.1 Driver};Server=localhost;Database=blah_blah_blah;User=foo;Password=bar;"); var cmd = new ActiveXObject("ADODB.Command"); cmd.ActiveConnection = conn; var strSQL = "SELECT id FROM tbl_info WHERE title LIKE :search ORDER BY id"; var search = "test"; try{ cmd.CommandText = strSQL; var param = cmd.CreateParameter(':search', 200, 1, 100, search); cmd.Parameters.Append(param); var