计算字符串中逗号最多的有多少个

SELECT id, LENGTH(path) - LENGTH(REPLACE(path, ',', ''))  FROM tongfu_user where LENGTH(path) - LENGTH(REPLACE(path, ',', '')) = ( select max(LENGTH(path) - LENGTH(REPLACE(path, ',', ''))) from tongfu_user )
posted @ 2022-08-04 16:33  垖垏尐  阅读(15)  评论(0编辑  收藏  举报