Mysql Query to replace colum values

Hi,

I need a mysql query to replace all values from my column idcat_bok, example, all values with 50 change them to 200.

I have been using the the following query but I don't want to use replace() since I want to change the whole value of that field and not a portion

update books_bok set idcat_bok = replace(idcat_bok,'50','200');

Thank you.
FernanditosAsked:
Who is Participating?
 
Neil RussellTechnical Development LeadCommented:
You would use

UPDATE books_bok
SET idcat_bok = 200
WHERE idcat_bok = 50
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.