    # Thread: Excel - counting instances of )

1. Login to Give a bone

## Excel - counting instances of )

This is a bit of an odd one, but, I need to count how many closing parentheses I've got in an excel column (and not just the number of fields in which it occurs, the total number, as there will be multiple occurrences per records).

Any excel gurus have some advice on what my formula should look like?

For the time being, I did a find/replace and replaced all ")" with ")q" as I didn't have any other q's on the page, but, using COUNTIF I only got the total number of records where the *Q* appeared (like 270), instead of the total number of Qs (which should be over 700).  Reply With Quote

2. Login to Give a bone

## Re: Excel - counting instances of )

Are you allowed to create a new analytical column?  Reply With Quote

3. Login to Give a bone

## Re: Excel - counting instances of ) Originally Posted by CADastrophe Are you allowed to create a new analytical column?
I suppose I could. With these massive reports, I like to spend as little time processing them as possible. But, I only do them once a quarter, so I guess it's no big deal. should've known I'd get you in an excel topic. lol. thanks.  Reply With Quote

4. Login to Give a bone

## Re: Excel - counting instances of ) Originally Posted by Wanderer I suppose I could. With these massive reports, I like to spend as little time processing them as possible. But, I only do them once a quarter, so I guess it's no big deal. should've known I'd get you in an excel topic. lol. thanks.
The easiest way to do this would be to create a separate column to count the characters of each line and get the total of that column. Assuming that your data resides in column A, I think that I'd fill column B with the following formula:

=LEN(INDIRECT(CONCATENATE("A",ROW())))-LEN(SUBSTITUTE(INDIRECT(CONCATENATE("A",ROW())),")",""))

This formula results in the difference of characters between the original text and the text without the specified character.  Reply With Quote

5. Login to Give a bone

## Re: Excel - counting instances of ) Originally Posted by CADastrophe The easiest way to do this would be to create a separate column to count the characters of each line and get the total of that column. Assuming that your data resides in column A, I think that I'd fill column B with the following formula:

=LEN(INDIRECT(CONCATENATE("A",ROW())))-LEN(SUBSTITUTE(INDIRECT(CONCATENATE("A",ROW())),")",""))

This formula results in the difference of characters between the original text and the text without the specified character.
Holy cannoli, you're a flippin genius. That worked a treat!

Thank you, Corey!  Reply With Quote

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•