For example, I have 100001,100002,
stored in a NVARCHAR
column.
I want to count the number of occurrences of ,
in this column.
For example, I have 100001,100002,
stored in a NVARCHAR
column.
I want to count the number of occurrences of ,
in this column.
select len('100001,100002,') - len(replace('100001,100002,',',',''))
returns 2