Solved

Need to deliver a count of certain names by looking for a string within a string and then counting the names associated with the smaller string

Posted on 2013-01-16
2
271 Views
Last Modified: 2013-01-16
I have a file I have been working on. The formula in B3:E3 was successful in looking up 1 of the 4 objects in A3 and then returning a value associated with the object in a different tab.

Here, I have a new type of problem where I need a formula in B3 on my Formulas tab to look at column A on my Areas tab and count all of the cells that have "LA" or "Las Vegas" for the object names in A3 on the Formulas tab.  The answer should be 2.

Thank you!
Test-File.xlsx
0
Comment
Question by:Dominator1025
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 50

Accepted Solution

by:
barry houdini earned 500 total points
ID: 38784235
Hello Dom,

This formula should give you the count for "LA" or "Las Vegas" [edited]

=SUMPRODUCT(ISNUMBER(SEARCH(","&Areas!$A$2:$A$2000&",",","&$A2&","))*(Areas!$B$2:$B$2000={"LA","Las Vegas"}))

That gets the results you suggested but only matches the whole 5 character object

You can change the {"LA","Las Vegas"} part to include any number of locations, if it's a single location you don't need the brackets { and }

regards, barry
0
 

Author Closing Comment

by:Dominator1025
ID: 38784552
Awesome, thanks again!
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
When you see single cell contains number and text, and you have to get any date out of it seems like cracking our heads.
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question