Originally Posted by
cristaltech
[update zen_sc_customer set amount = amount - where customer_id=28]
I'm trying to find anything in Zen Cart that runs such a query, but can't find any.
1. zen_sc_customer is the table name it's attempting to update.
Zen Cart has a table named "customers" and "coupon_gv_customer", but nothing called "customer" or "sc_customer".
This tells me whatever is causing your error is from an addon you've installed.
2. The actual problem is that it appears to be attempting to set "amount" to zero, but likely is using an uninitialized variable that's set to '' instead of '0', and thus is inserting a blank string for the new "amount" value.
It would be prudent to insert (int) before the variable name ... whenever you can find out which line of code in the contribution is causing this. That'll force the '' value to be converted to '0', thus getting around the error.
ie:
Code:
... set amount = amount - #### where ...
(with #### being the value to reduce "amount" by.)
Bookmarks