+ Reply to Thread
Results 1 to 4 of 4

Count number of rows that meet two conditions

  1. #1
    Registered User
    Join Date
    05-11-2013
    Location
    Portland
    MS-Off Ver
    Excel 2007
    Posts
    9

    Count number of rows that meet two conditions

    I hope my question is an easy one.

    I need a formula that will count the number of rows that meet two conditions. In Column A I have a range called "Status_Ambrosio" and in Column B I have a range called "CSR_Ambrosio". The size of these ranges will change but they will always be identical sizes of each other. I need a formula that will count the number of rows where both conditions are met: Column A (Status_Ambrosio) equals "PROJECT" and Column B (CSR_Ambrosio) contains an asterisk (*). There will be other text in column B so I need the formula to check the cell in column B and see if it contains an asterisk. For Example, it would identify if a cell contained the name " James, Jesse* " but it would not identify a name typed " James, Jesse ". Can anyone help?

    I'm lost as to whether this needs to be a count if, sumproduct, or sum function. Perhaps this needs to be an array? I'm just lost on this one, primarily on the Column B criteria. Any help would be appreciated. Thanks!

  2. #2
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: Count number of rows that meet two conditions

    hi travisg, try:
    =COUNTIFS(Status_Ambrosio,"project",CSR_Ambrosio,"*~**")

    if it doesn't work, upload a sample Excel file. highlight those cells you expect to be counted

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

  3. #3
    Registered User
    Join Date
    05-11-2013
    Location
    Portland
    MS-Off Ver
    Excel 2007
    Posts
    9

    Re: Count number of rows that meet two conditions

    Thanks for the tip benishiryo. I've tried this before and it gives me #VALUE!. I'm not sure why. Here is a sampel of the table I am trying to use this formula on. Any one of the cells in Column A could potentially say PROJECT and any one of the names in Columns B/C could have an sterisk. Feel free to add/delete these for testing. Thanks for the help!

    Excel_Forum.xlsx

  4. #4
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Count number of rows that meet two conditions

    You have defined "CSR_Ambrosio" incorrectly it should be
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Ahh .. the joys of merged cells.
    Get rid of them.

    [EDIT]
    See the Names in this workbook, they are dynamic.
    They will increase/decrease as you add/delete data from Column B
    Attached Files Attached Files
    Last edited by Marcol; 06-18-2013 at 12:46 PM. Reason: Added amended workbook
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1