>> sql="UPDATE product_attribute SET index_column = "+str(index)+" WHERE id = >> "+str(record2[0]) >> .. >> cursor.execute(sql)
To allow the DB-API adaptor to correctly take care of value conversion and SQL escaping for you, this should be written as: cursor.execute("UPDATE product_attribute SET col1 = %s WHERE id = %s", (index, record2[0])) As for why the UPDATE has no effect, which version of MySQL are you using? David. -- http://mail.python.org/mailman/listinfo/python-list