Simpatie.ro - matrimoniale
Mrrrr's Forum (VIEW ONLY)
Un forum care ofera solutii pentru unele probleme legate in general de PC. Pe langa solutii, aici puteti gasi si alte lucruri interesante // A forum that offers solutions to some PC related issues. Besides these, here you can find more interesting stuff.
Nou pe simpatie:
Ioanacatalina
Femeie
25 ani
Salaj
cauta Barbat
25 - 61 ani
Mrrrr's Forum (VIEW ONLY)ReguliInregistrareLoginPozeNu sunteti logat. Lista Forumurilor Pe Tematici
Mrrrr's Forum (VIEW ONLY) / Tutoriale si Ghiduri Utile // Tutorials and useful guides /

[EXCEL] Count the number of unique values in a column / two columns

Pagini: 1 Moderat de TRaP, TonyTzu
#1
Mrrrr
AdMiN
Postari: 2388
You will have to use the next formulas to:

Count the number of unique number values in cells A2:A10, but do not count blank cells or text values
=SUM(IF(FREQUENCY(A2:A10;A2:A10)>0;1))

Count the number of unique text and number values in cells B2:B10 (which must not contain blank cells)
=SUM(IF(FREQUENCY(MATCH(B2:B10;B2:B10;0);MATCH(B2:B10;B2:B10;0))>0;1))

Count the number of unique text and number values in cells A2:A10, but do not count blank cells
=SUM(IF(FREQUENCY(IF(LEN(A2:A10)>0;MATCH(A2:A10;A2:A10;0);""); IF(LEN(A2:A10)>0;MATCH(A2:A10;A2:A10;0);""))>0;1))

Note:
If you receive some sort of error, replace all ; (semicolons) with , (commas).


_______________________________________


 
   
#2
Mrrrr
AdMiN
Postari: 2388
corrected

_______________________________________


 
   
#3
TRaP
Moderator
Postari: 960
Count for unique values in 2 columns:

=IF(IF(COUNTIFS($C$2:$C$1001;C2;$B$2:$B$1001;B2)/COUNTIF($C$2:$C$1001;C2)<1;0;1);IF(COUNTIF($C2:C$1001;C2)>1;0;1);0)

The above formula checks whether a sales rep name occurs in one region only or in more than one region. It does that by counting the number of occurrence of a name in a region and dividing it by the total number of occurrences of the name. If the value is less than 1, it indicates that the name occurs in two or more than two regions.

In case the name occurs in more than one region, it returns a 0 else it returns a one.

The formula also checks whether the name is repeated in the same region or not. If the name is repeated, only the first instance of the name returns the value 1, and all other instances return 0.

I use it in a Table for a different purpose, so mine looks like:

=IF(IF(COUNTIFS([DM];[@[DM]];[CA];[@[CA]])/COUNTIF([DM];[@[DM]])<1;"";1);IF(COUNTIF([DM];[@[DM]])>1;"";1);"")


Source:
https://trumpexcel.com/count-distinct-p ... ivot-Table


 
   
Pagini: 1  
Mergi la