Think before you speak, read before you think.

mysql replace命令

by

in

将某字符串中的xz替换为yz

select replace('xxxxxzccss','xz','yz');

把Object表,字段asset_no中的XZZC替换为GDZC

update `Object` set `asset_no`=REPLACE(`asset_no`,'XZZC','GDZC');

 


Comments

Leave a Reply

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