+ Reply to Thread
Results 1 to 4 of 4

Counting Customers Based on One Table & Inputs

  1. #1
    Registered User
    Join Date
    04-26-2021
    Location
    California
    MS-Off Ver
    Office 365
    Posts
    7

    Question Counting Customers Based on One Table & Inputs

    Hello,

    I am having a hard time figuring out how to derive the correct value based on multiple inputs and two data sources.

    There is Data Sheet 1 which contains hours that an event occurs for particular resources, Data Sheet 2 which has all the relevant data associated with a resource, and lastly the inputs to ascertain the applicable customers.

    I am attempting to determine if a resource has an event hour greater than 0 then it will find all the resources on Data Sheet 2, if the count type has an input of yes then it will find all the count types associated with "count of enrolled", and if the date of 4/11/2021 for example then it will select the month of April and all of these inputs will then be summed in one cell.

    Here is the formula that I had written, but it was not keeping the solution into one cell and it was spilling down. It was also giving me a number of customers when it should have been zero.

    I'm totally stumped, so any help would be greatly appreciated.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,831

    Re: Counting Customers Based on One Table & Inputs

    if YES, means, "Count of enrolled", then your formula has it backwards - it says if it's "yes", the look for "Count of program only"

    =XLOOKUP(B4:B6&(TEXT(C25,"mmmm"))&(IF(C24="yes","count of program Only","Count of Enrolled")),F4:F21&H4:H21&G4:G21,I4:I21)

    Anyway, try this in C28:

    =SUM(XLOOKUP(FILTER($B$4:$B$6,$C$4:$C$6<>0)&IF($C$24="yes","Count of Enrolled","count of program Only")&TEXT($C$25,"mmmm"),$F$4:$F$21&$G$4:$G$21&$H$4:$H$21,$I$4:$I$21,,0))

  3. #3
    Registered User
    Join Date
    04-26-2021
    Location
    California
    MS-Off Ver
    Office 365
    Posts
    7

    Re: Counting Customers Based on One Table & Inputs

    Thank you! This is exactly what I was looking for you are a godsend! I will have to study up on that filter formula, I am not as familiar with it.

  4. #4
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,831

    Re: Counting Customers Based on One Table & Inputs

    You're welcome, and thanks for the rep.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Calculate a grade based on inputs that are pulling from a table
    By kloesch6950 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 10-28-2018, 03:21 AM
  2. Replies: 7
    Last Post: 04-15-2018, 10:19 AM
  3. [SOLVED] Pivot Table Refresh Based On Inputs From Cell A2
    By NeedForExcel in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-10-2015, 06:45 AM
  4. Determine repeat customers vs. new customers based on purchase date
    By mktgdude in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-02-2013, 04:10 AM
  5. completing ship to dates based on customers name and table of values
    By butterfly123 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 06-06-2011, 02:13 PM
  6. Populate table based on 3 inputs
    By Senthilerp in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-19-2009, 04:16 AM
  7. [SOLVED] Find value in table based on two inputs
    By AMDRIT in forum Excel General
    Replies: 3
    Last Post: 12-30-2005, 12:50 PM

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