How to Find & Replace String in MySQL

To find a string in a certain field and replace it with another string:

update [table_name] set [field_name] = replace([field_name],'[string_to_find]’,'[string_to_replace]’);

like update user set name = replace(name,’Dr.’,’Mr.’);

If you like the post & want to get more then Subscribe our blog posts. Subscribe SunwareTech.net RSS Feed Facebook Twitter Email

Both comments and pings are currently closed.

3 Responses to “How to Find & Replace String in MySQL”

  1. vikash says:

    good , please keep It

  2. Wonderful blog! I found it while surfing around on Yahoo News. Do you have any tips on how to get listed in Yahoo News? I’ve been trying for a while but I never seem to get there! Thanks

  3. Ramesh says:

    Very Good function. Keep it up.

Copyright © Sunware Technologies - Your web partner