ARRAYS_COUNTIFS SORT UNIQUE VALUES

MHD

New Member
Joined
Mar 16, 2021
Messages
49
Office Version
  1. 2019
Hello

I have a table with duplicate values, I would like to get only the unique values, and then count those values by USEING ONLY ONE ARRAY_FURMULA.
Improvement: Multiple sorting of duplicated values in ascending order.

Book1.xlsx
BCDEFGH
2
3DATANameType#
4NameTypeA51
5A5A11
6A1A21
7B1B11
8F2B21
9B2C32
10A2D32
11C3F21
12D3
13C3
14D3
15
16
17Merge all highlighted formulas in one (F4)
18Make Multi Sorting (Two levels) the name then the Type with function (SORT)
TEST
Cell Formulas
RangeFormula
F4:G11F4=SORT(UNIQUE(Table2))
H4:H11H4=COUNTIFS(Table2[Name],F4,Table2[Type],G4)
Dynamic array formulas.
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
How about
Excel Formula:
=LET(u,UNIQUE(Table2),SORT(HSTACK(u,COUNTIFS(Table2[Name],INDEX(u,,1),Table2[Type],INDEX(u,,2))),{1,2}))
 
  • Like
Reactions: MHD
Upvote 0
Solution
How about
Excel Formula:
=LET(u,UNIQUE(Table2),SORT(HSTACK(u,COUNTIFS(Table2[Name],INDEX(u,,1),Table2[Type],INDEX(u,,2))),{1,2}))
GREAT Fluff, It works better than expected!
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,215,108
Messages
6,123,132
Members
449,098
Latest member
Doanvanhieu

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top