Need mySQL Query help

Status
Not open for further replies.

guerilla

All we do is win
Aug 18, 2007
11,424
428
0
No
I have a table with a column that is text.

Let's assume

db name: database
table name: table
text column: column

Now I need to replace particular instance of the word monkey with donkey in this text field, but the field is loaded with a lot of text data.

What query would I use?
 


Code:
update [COLOR=Yellow]table_name [/COLOR]set [COLOR=Yellow]field_name[/COLOR] = replace([COLOR=Yellow]field_name[/COLOR],'[COLOR=Orange]monkey[/COLOR]','[COLOR=Orange]donke[/COLOR][COLOR=Orange]y[/COLOR]');
 
  • Like
Reactions: guerilla
Status
Not open for further replies.