» Counting the Number of Times a Substring Appears Within a String
CATEGORY - Excel Counting
VERSION - All Microsoft Excel Versions
Problem:Counting the number of times each of the substrings listed in column B appears within the corresponding string in column A.
Solution:
Use the LEN and SUBSTITUTE functions as shown in the following formula:
=(LEN(A2)-LEN(SUBSTITUTE(A2,B2,"")))/LEN(B2)
Book Store:
Recommended Books:
- East of Eden (Oprah's Book Club)
- Yes, You Can Time the Market!
- F1 Get the Most out of Excel! The Ultimate Excel tip Help Guide
- Marketing Plans That Work, Targeting Growth and Profitability
- The Intelligent Investor: The Definitive Book On Value Investing, Revised Edition
- Analyzing Markets, Products, and Marketing Plans
No comments have been submitted.

