Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi! I am new to DAX and Power Bi. I have a problem with measure when I use literal numerical constants like #3 in figure below. Calculation is correct, but column is filled for dates not existing in data table. Same problem when measure consists in one number (#4). I guess that the problem somewhere in context, but cant find a desicion. How can I correctly do this calculation in DAX? Thanks!
Solved! Go to Solution.
the problem is with measures #3 and #4
for #3 you have
1-DIVIDE(A,B+C+D,0)
which evalueates to 1-0 =1 when B+C+D are = 0 (basically a constant regardless of A,B,C,D)
you need to do it like this:
DIVIDE(B+C+D-A,B+C+D,BLANK())
which evaluates to BLANK() for B+C+D=0
now for #4 I assume you only want to show 1 whenever there is data, so I would do something like this:
IF(ISBLANK([reaches_ratio]),BLANK(),1)
the problem is with measures #3 and #4
for #3 you have
1-DIVIDE(A,B+C+D,0)
which evalueates to 1-0 =1 when B+C+D are = 0 (basically a constant regardless of A,B,C,D)
you need to do it like this:
DIVIDE(B+C+D-A,B+C+D,BLANK())
which evaluates to BLANK() for B+C+D=0
now for #4 I assume you only want to show 1 whenever there is data, so I would do something like this:
IF(ISBLANK([reaches_ratio]),BLANK(),1)
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
20 | |
7 | |
6 | |
5 | |
5 |
User | Count |
---|---|
26 | |
10 | |
10 | |
9 | |
6 |