查询SQL中字符串里有多少个逗号

select len(@str)-len(replace(@str,',',''))

  

原文地址:https://www.cnblogs.com/qiywtc/p/3719304.html