+ Reply to Thread
Results 1 to 5 of 5

Counting cells in one column based on unique values in another column

  1. #1
    Registered User
    Join Date
    08-11-2017
    Location
    England
    MS-Off Ver
    2010
    Posts
    5

    Counting cells in one column based on unique values in another column

    Hi all,

    I need a bit of a hand please. Hope I explain this correctly to you -

    Attached is a condensed version of a spreadsheet I use to schedule work. What I'd like to be able to do is calculate the amount of engineers I require on any given day.

    I need to be able to count the number of cells that have a value in it (Columns H (Engineer 1), I (Engineer 2), J (Engineer 3)& K (Engineer 4)). I don't need to know who is going, so what value is in the cell doesn't matter, only just that the cell has a value in it.

    The catch is that I only need to count them based on the unique values in column A. As a job could potentially have 5 or 6 rows associated to it in the spreadsheet, I don't want excel to think that I need six engineers when I only need one.

    I then need to be able to display the information per day.

    Thanks for your help!
    Attached Files Attached Files

  2. #2
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,737

    Re: Counting cells in one column based on unique values in another column

    take 47281
    that would be 2
    what if you had different names in row h2,h3,h4
    does tbc count
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Registered User
    Join Date
    08-11-2017
    Location
    England
    MS-Off Ver
    2010
    Posts
    5

    Re: Counting cells in one column based on unique values in another column

    Sorry for replying so late. Thanks for the reply.

    Correct, 47281 should be 2. And yes, TBC does count (I just haven't yet decided who will be assigned to that particular job).

    h2,h3 & h4 should never have different names in it. If that is the case it's a mistake on my part. (I don't need to over complicate things and have the formula flag this mistake to me)

    So, taking Monday as an example -

    47261 should count 2
    48033 - 2
    74832 - 2
    69400 - 2
    04872 - 2
    11830 - 3
    73194 - 3
    12284 - 2

    Taking h2,h3 & h4 as an example again; the main thing is I don't want the formula to count separate values in those cells (sometimes there may be a spelling mistake in the engineers name or something), it only needs to recognise an empty cell as 0, or a combined value a 1 for those 3 cells if anything is in them.

    Hope I'm explaining this correctly!

    Thanks again for your help,

    Edit:
    Thinking about it, we often filter the spreadsheet by the values in column C (Project). If the formula alters based on this that'll be incredibly useful.
    Last edited by 3SixOne; 08-15-2017 at 06:16 AM.

  4. #4
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,737

    Re: Counting cells in one column based on unique values in another column

    if you filter , i dont think a formula will allow for filtered data
    we may have to use a helper column

  5. #5
    Registered User
    Join Date
    08-11-2017
    Location
    England
    MS-Off Ver
    2010
    Posts
    5

    Re: Counting cells in one column based on unique values in another column

    Interesting, I didn't know that.

    To be honest that part of it is secondary, if the formula can't change when information is filtered then so be it.

+ 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. Counting unique values based on another column
    By tfagan1978 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-04-2017, 04:00 AM
  2. Replies: 2
    Last Post: 08-19-2015, 10:22 AM
  3. Counting unique values based on condition in a different column
    By rafuk73 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-21-2014, 02:59 PM
  4. [SOLVED] Filter rows based on unique values in one column + specific value in another column
    By Dieneces in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 07-31-2013, 09:55 AM
  5. Counting Unique text in column B based on a criteria from column a
    By clocmasta in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-18-2013, 06:40 PM
  6. [SOLVED] Counting # of specific values in one column for each unique IP in another column
    By Light C in forum Excel Formulas & Functions
    Replies: 20
    Last Post: 06-04-2013, 11:38 AM
  7. Replies: 0
    Last Post: 08-01-2012, 11:18 AM

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