Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi,
I am a new to Power BI and I want to convert this calculation in Tableau to Power BI using DAX. Appreciate if someone can explain what this means and how can this be done.
IF First()=0 THEN WINDOW_SUM(COUNTD(ID)) END
Thank you! 🙂
Solved! Go to Solution.
IF First()=0 THEN WINDOW_SUM(COUNTD(ID)) END
Here's a step-by-step approach to translating it into DAX:
Please try this below:
This DAX formula will return the distinct count of ID only for the first row and will show blank for other rows, similar to how the Tableau calculation works.
Measure =
IF (
RANKX(ALLSELECTED(Table), [ID],, ASC, Dense) = 1,
CALCULATE(DISTINCTCOUNT(Table[ID]), ALLSELECTED(Table))
)
💌 If this helped, a Kudos 👍 or Solution mark would be great! 🎉
Cheers,
Kedar
Connect on LinkedIn
IF First()=0 THEN WINDOW_SUM(COUNTD(ID)) END
Here's a step-by-step approach to translating it into DAX:
Please try this below:
This DAX formula will return the distinct count of ID only for the first row and will show blank for other rows, similar to how the Tableau calculation works.
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.
User | Count |
---|---|
14 | |
13 | |
11 | |
10 | |
10 |