Forum Moderators: open
I am in trouble, My script send automatic email everyday to a user. What I want to do is to set the value of a row to 0 so that it stop sending automatic email , below is the working code. But I want to do it to all users for example to multiple id's?
UPDATE `email` SET `send` = 'o' WHERE `id` =20 LIMIT 1 ;
help plz
ps. I use phpmyadmin
UPDATE 'email'
SET sent = '0'
WHERE id IN (SELECT id FROM 'email') ;
but i get that error:
You have to choose at least one column to display
:(
let me explain more:
Table email has many fields but I want To update The Send field which has a value of 2 and when it is 2 it keep sending email.
I have 2000members in database so I need a query to make all Field sent on tabel email 0.
If you want to update all the fields than this should be enough:
UPDATE email SET sent = '0'