MySQL 姓名两个字中间加两个空格

SELECT * FROM `mytable` WHERE CHARACTER_LENGTH(xingming)=2
SELECT CONCAT(LEFT(xingming,1),'  ',RIGHT(xingming,1))  FROM `mytable` WHERE CHARACTER_LENGTH(xingming)=2
UPDATE`mytable` SET xingming=CONCAT(LEFT(xingming,1),'  ',RIGHT(xingming,1)) WHERE CHARACTER_LENGTH(xingming)=2


posted @ 2022-06-11 07:39  emanlee  阅读(463)  评论(0编辑  收藏  举报