Skip to content

MySQL Replace

Last updated on June 20, 2015

Replace() is one of the MySQL string function, It will search with the given string and REPLACE or UPDATE in all occurrences with given string.

Syntax

  REPLACE(str,from_str,to_str)

Example

mysql> SELECT REPLACE('www.arjunphp.com', 'w', 'Ww');
        -> 'WwWwWw.arjunph.com'

That’s it.

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments