Thanks to both of you for the help.
It turns out I had 2 things screwy.
1) I had somehow saved the csv file with a ; delimiter. Apparently PHP and /or MySQL doesn't like that much. Once I changed it to , all was fine.
2) The $supplier_reference variable can also contain letters so I had to do this:
mysql_query("UPDATE stock_available, product SET stock_available.quantity = $quantity WHERE stock_available.id_product = product.id_product AND product.supplier_reference =
'$supplier_reference
'")
It updates correctly now.
Cheers.
