开发者

Replacing a value in all rows

开发者 https://www.devze.com 2023-02-18 04:16 出处:网络
I have about 50 or so records in a table, I need a 开发者_如何学Gosql statement that will update all the referral column ids that are 5 to 9. How would I apply this to every record that applies?UPDATE

I have about 50 or so records in a table, I need a 开发者_如何学Gosql statement that will update all the referral column ids that are 5 to 9. How would I apply this to every record that applies?


UPDATE YourTable
SET referral_column_id = 9
WHERE referral_column_id = 5;


UPDATE `table_name` SET `column_id` = 9 WHERE `column_id` = 5;


UPDATE col SET referral = 9 WHERE referral =5
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号