MySQL REPLACE() function

REPLACE() function

MySQL REPLACE() replaces all the occurrences of a substring within a string.

Syntax:

REPLACE(str, find_string, replace_with)

Arguments

NameDescription
strA string.
find_stringA string which is present one or more times within the string str.
replace_withA string which will replace every time it finds find_string within str.

REPLACE(str,old_string,new_string);

About Author

Leave a Reply

Your email address will not be published. Required fields are marked *

PAGE TOP
error

Enjoy this blog? Please spread the word :)

RSS
Follow by Email