Forum Discussion
ceetay
Jan 14, 2019Copper Contributor
Count number of specific characters within a cell
I want to count the number of commas in a cell, and use that to calculate how many separate bits of info (batch numbers) are within that cell. I have a formula (probably over-complicated) that works ...
Jan 14, 2019
Hello,
the approach is to get the length of the cell, then substitute all commas in the cell with nothing, get the length of that and then subtract one from the other. That will give you the count of commas in the cell. Add 1 to return the count of elements in the cell.
=LEN(F2)-LEN(SUBSTITUTE(F2,",",""))+1