Solved

Number of Unique Entries Based on Secondary Criteria

Posted on 2014-02-03
6
167 Views
Last Modified: 2014-02-03
I have attached a helper spreadsheet to help explain what I am trying to do...

In column D of Sheet1 I am trying to count the number of unique entries in column D of Sheet2 when Sheet1!A = Sheet2!H

In English...How many different codes did a person use based on the USER_INIT with the result in column D on the row matching each change in user.
HelperFile.xlsx
0
Comment
Question by:sparker1970
  • 2
  • 2
  • 2
6 Comments
 
LVL 35

Expert Comment

by:Dan Craciun
ID: 39830460
Use, in D2
=COUNTIF(Sheet2!$H:$H, Sheet1!$A2)

then copy down.

HTH,
Dan
HelperFile-mod.xlsx
0
 
LVL 23

Accepted Solution

by:
NBVC earned 500 total points
ID: 39830483
Try:

=COUNT(1/FREQUENCY(IF(Sheet2!$H$2:$H$3283=A2,IF(Sheet2!$D$2:$D$3283<>"",MATCH(Sheet2!$D$2:$D$3283,Sheet2!$D$2:$D$3283,0))),ROW(Sheet2!$D$2:$D$3283)-ROW(Sheet2!$D$2)+1))

Open in new window


confirmed with CTRL+SHIFT+ENTER not just ENTER and copy down.
0
 

Author Comment

by:sparker1970
ID: 39830500
Sorry Dan...that gives me the total # of entries but not the total # of unique entries
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 23

Expert Comment

by:NBVC
ID: 39830524
Have you tried mine above?

An alternative with Array formula, but uses helper column...

In Sheet2!J2 enter:

=COUNTIFS($D$2:$D2,$D2,$H$2:$H2,$H2)

copied all the way down.

then in D2 of Sheet1:

=COUNTIFS(Sheet2!H:H,A2,Sheet2!J:J,1)

copied down.
0
 
LVL 35

Expert Comment

by:Dan Craciun
ID: 39830544
Yup, did not read carefully your question.

NVBC's solution works (the array formula, did not try the helper, but being from NVBC I would say that works too :)
0
 

Author Closing Comment

by:sparker1970
ID: 39830917
Worked perfectly!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
merge/join/combine multiple tables into one master table 2 41
Print Wrapped Rows 3 20
using vb script 5 48
Conditional fromatting formula 29 30
This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
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…
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

740 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