views:

17

answers:

1
Dim prestaDB 
prestaDB = "DRIVER={MySQL ODBC 3.51 Driver};SERVER=mysql50-64.wc1;PORT=3306;DATABASE=example_db;USER=example_user;PASSWORD=example_password;OPTION=3;" 
set conn = Server.CreateObject("ADODB.Connection") 
conn.open prestaDB 
conn.execute("update ps_product set quantity = " & sSeg(4) & " where reference = '%" & sSeg(0) &"%'")

The rest of the code sets:

sSeg(4) = 5
sSeg(0) = "N540"

N540 is a valid reference in my db

When this is executed, it gives no errors yet the quantity does not update to be 5.

The server is running MySQL 5

Any ideas what is going wrong?

+2  A: 

change the

where reference = '%....

to where reference like '%

none
That did the trick, thank you :)
kelbyuk