Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Dtrain
Helper I
Helper I

Stop distinct count blank values from multiple tables

Hi,
 
I am trying to stop counting blank from the DAX but can't work it out. I need help please.
 
 
Act ID =
COUNTROWS (
DISTINCT (
UNION (
DISTINCT ( 'table column A'[CreatedNo] ),
DISTINCT ( 'table column B'[ModifiedCreatedNo] )
)
))
 
 
 
Thanks
1 ACCEPTED SOLUTION

Try measure like below:

Act ID = 
COUNTROWS (
DISTINCT (
UNION (
DISTINCT (FILTER(VALUES('table column A'[CreatedNo]), 'table column A'[CreatedNo] <> BLANK() )),
DISTINCT ( FILTER(VALUES('table column B'[ModifiedCreatedNo]),'table column B'[ModifiedCreatedNo]<>BLANK()) )
)))

View solution in original post

5 REPLIES 5
AliceW
Power Participant
Power Participant

You could use COUNTAX

COUNTAX did not work 😞

Try measure like below:

Act ID = 
COUNTROWS (
DISTINCT (
UNION (
DISTINCT (FILTER(VALUES('table column A'[CreatedNo]), 'table column A'[CreatedNo] <> BLANK() )),
DISTINCT ( FILTER(VALUES('table column B'[ModifiedCreatedNo]),'table column B'[ModifiedCreatedNo]<>BLANK()) )
)))

Your measure has been working well but I was just wondering if a filter can be added? I would like to see the results only Males from column C. What would be the best way to write the measure to include this?

You're a lifesaver. Thank you soon much for the help.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.