March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi, I'd like to write a measure to calculate total distinct items from 1 column that not found in another column. 2 columns are from different tables.
I was able to do this my adding a calculated helper column, but just wondering if there is any way to do it without adding an extra column.
For example:
Column A from table 1
-----------
AA
AA
AA
BB
CC
CC
DD
DD
EE
Column B from table 2
-----------
AA
AA
BB
BB
FF
I want to count distinct items from Column A not found in Column B.
There are 5 items in Column A not found in Column B:
-----------
AA
AA
AA
BB
CC
CC
DD
DD
EE
And there are 3 distinct counts: CC DD and EE, so the measure should return 3.
Thanks!
Solved! Go to Solution.
@yuanye0710 , except can help
In A not in B
a new table = except(distinct(TableA[COlumn]), distinct(TableB[COlumn]) )
measure
a new table = Countrows(except(distinct(TableA[COlumn]), distinct(TableB[COlumn]) ) )
@yuanye0710 , except can help
In A not in B
a new table = except(distinct(TableA[COlumn]), distinct(TableB[COlumn]) )
measure
a new table = Countrows(except(distinct(TableA[COlumn]), distinct(TableB[COlumn]) ) )
Thanks a lot! it's working for me!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
25 | |
18 | |
15 | |
9 | |
8 |
User | Count |
---|---|
37 | |
32 | |
16 | |
16 | |
12 |