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!Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!
Dear All,
In table down i need to count active users with no purchase at all,
when we use Dax Furmula Measue= calculate(distinctcount{"User", Filter(status="Active"&&purcahse value="0") = 3 users which is wrong
Exp: Rami & Ahmad reapeated multi times "Value =0 and Value >0, so should be excluded from our Measure
i need furmual with Answer =1 , because only user "Wassem" is active and never purchased
| User | status | Purchase value |
| Rami | Active | 0 |
| Ahmad | Active | 0 |
| fahad | Not Active | 0 |
| wassem | Active | 0 |
| Rami | Active | 22 |
| Rami | Active | 33 |
| Ahmad | Active | 50 |
Solved! Go to Solution.
@KamalMalek
Use this measure:
Never Bought =
CALCULATE(
COUNTROWS(
FILTER(
DISTINCT( Table10[User] ),
CALCULATE( SUM(Table10[Purchase value]) ) = 0
)
),
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
Hi @KamalMalek ,
Another way:
VAR StatusActiveAndPurchase0 =
DISTINCT(
SELECTCOLUMNS(
FILTER( 'Table', 'Table'[Purchase value] = 0 && 'Table'[Status] = "Active" ),
"@User", 'Table'[User]
)
)
VAR STatusActiveAndPurchaseNot0 =
DISTINCT(
SELECTCOLUMNS(
FILTER( 'Table', 'Table'[Purchase value] > 0 && 'Table'[Status] = "Active" ),
"@User", 'Table'[User]
)
)
RETURN
COUNTROWS( EXCEPT( StatusActiveAndPurchase0, STatusActiveAndPurchaseNot0 ) )
@KamalMalek
Use this measure:
Never Bought =
CALCULATE(
COUNTROWS(
FILTER(
DISTINCT( Table10[User] ),
CALCULATE( SUM(Table10[Purchase value]) ) = 0
)
),
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
Really appreciate your support thanks a lot 🙂
@KamalMalek
Kinldy accept it as solution if it works for you.
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
Hi @KamalMalek ,
Another way:
VAR StatusActiveAndPurchase0 =
DISTINCT(
SELECTCOLUMNS(
FILTER( 'Table', 'Table'[Purchase value] = 0 && 'Table'[Status] = "Active" ),
"@User", 'Table'[User]
)
)
VAR STatusActiveAndPurchaseNot0 =
DISTINCT(
SELECTCOLUMNS(
FILTER( 'Table', 'Table'[Purchase value] > 0 && 'Table'[Status] = "Active" ),
"@User", 'Table'[User]
)
)
RETURN
COUNTROWS( EXCEPT( StatusActiveAndPurchase0, STatusActiveAndPurchaseNot0 ) )
Thanks a lot 🙂
Vote for your favorite vizzies from the Power BI World Championship submissions!
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 12 | |
| 11 | |
| 7 | |
| 7 | |
| 6 |