替换数据库字段部分内容

来源:互联网 发布:淘宝达人头像 编辑:程序博客网 时间:2024/04/30 06:38

使用语句

update 表名 set 字段名=replace(字段名,'要替换的内容','替换后的内容')

例如:

update authors set state=replace(state,'C','CA')