Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个名为users填充列的表。有一个名为daily_points我想为表中的每一列更改为 3 的列。我该怎么做呢?替换不起作用,因为它会影响数据。
users
daily_points
我认为您只需要为表的每一行UPDATE设置一个查询,所以daily_points = 3users
UPDATE
daily_points = 3
UPDATE `users` SET `daily_points` = '3';
如果要为表中的所有设置值,column daily_points则可以3使用以下语句。rowsusers
column
3
rows
UPDATE users SET daily_points = 3;