Reputation: 2035
I'm struggling with a very basic query. I can not see what I'm doing wrong.
Here is the first query I tried:
UPDATE `qrm_logs` SET `billable` = '0' AND `invoice_id` = NULL WHERE `id` = '842'
And the second:
UPDATE `qrm_logs` SET `billable` = 0 AND `invoice_id` IS NULL WHERE `id` = '842'
Column billable
has type enum
. Column invoice_id
is an int
type. Also, invoice_id can be nullable.
What causes this problem?
Upvotes: 0
Views: 49
Reputation: 6684
Should be:
UPDATE `qrm_logs` SET `billable` = 0, `invoice_id` = NULL WHERE `id` = 842
note the comma instead of the AND.
Upvotes: 2