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!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi there,
i am pretty new to dax and hope for your help with the following measure:
Test =
VAR no1 =
CALCULATETABLE ( VALUES (Orders_Facts[Customer No. ] ) )
VAR no2 =
FILTER ( no1, [Filter] <> 0 )
RETURN
COUNTROWS ( no2 )
The base for the first measure is the following:
Filter =
CALCULATE (
SUM ( Sales_SCA[Calc. net-net turnover] ),
Sales_SCA[AC_PL] = "Ist",
TREATAS ( VALUES ( Orders_Facts[Item No.] ), Sales_SCA[Item No] ),
TREATAS ( VALUES ( Orders_Facts[Customer No.] ), Sales_SCA[Customer No] )
)
the problem is the filter i assume, but i havent found an other way to write it which delivers the correct result.
Thank you in advance for your efforts and KR,
KO
Solved! Go to Solution.
Hi @trying ,
Please try:
Test =
COUNTROWS (FILTER(VALUES(Orders_Facts[Customer No. ] ),ABS([Filter])>0))
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks for the help guys!
Hi @trying ,
Please try:
Test =
COUNTROWS (FILTER(VALUES(Orders_Facts[Customer No. ] ),ABS([Filter])>0))
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
You can simplify Test with:
test =
VAR no2 =
FILTER ( VALUES ( Orders_Facts[Customer No. ] ), [Filter] <> 0 )
RETURN
COUNTROWS ( no2 )
How is the model set up?
Proud to be a Super User!
Paul on Linkedin.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 59 | |
| 46 | |
| 42 | |
| 23 | |
| 18 |
| User | Count |
|---|---|
| 193 | |
| 123 | |
| 99 | |
| 67 | |
| 49 |