MySQL:REPLACE函数的使用
原文链接
REPLACE函数功能
REPLACE(columnName, search_str, replace_str)
查找columnName字段中所有search_str,并替换为replace_str
举例使用
源数据表
执行下面sql语句
UPDATE `tableName` SET `text`=REPLACE(`text`, '<!--markdown-->', 'newValue');
查找
text
字段中所有<!--markdown-->
,并替换为newValue
结果
更多文章请访问我的博客https://www.yaozuopan.top