转自:https://www.yiibai.com/mysql/mysql_function_replace.html

REPLACE(str,from_str,to_str)

返回字符串 str 中所有出现的 from_str 均被字符串to_str 替换后的字符串。 REPLACE()搜索 from_str 字符串时进行区分大小写匹配。

mysql> SELECT REPLACE('www.mysql.com', 'w', 'Ww');
+---------------------------------------------------------+
| REPLACE('www.mysql.com', 'w', 'Ww')                     |
+---------------------------------------------------------+
| WwWwWw.mysql.com                                        |
+---------------------------------------------------------+
1 row in set (0.00 sec)
//原文出自【易百教程】,商业转载请联系作者获得授权,非商业转载请保留原文链接:https://www.yiibai.com/mysql/mysql_function_replace.html

相关文章:

  • 2021-08-20
  • 2022-12-23
  • 2022-02-11
  • 2022-02-24
  • 2022-12-23
  • 2021-07-22
  • 2021-09-18
  • 2021-10-28
猜你喜欢
  • 2021-11-12
  • 2021-09-09
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案