Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin 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.
Hey,
I cannot figure out what is wrong with this formula Column = calculate(DISTINCTCOUNT('DB'[lead_id],FILTER('DB', 'DB'[status]="accepted")))
Thnx!
Solved! Go to Solution.
Please, try the following:
Column = calculate(DISTINCTCOUNT('DB'[lead_id]),'DB'[status]="accepted")
Explanation: The second part for the CALCULATE is already the filter expression. You don't need to use FILTER in this case. In addition, DISTINCTCOUNT accepts only 1 parameter, so you need to close your parenthesis right after 'DB'[lead_id].
EXTRA TIP: If you want this expression to consider also the other filters applied on you report, you can use the following:
Column = calculate(DISTINCTCOUNT('DB'[lead_id]),KEEPFILTERS('DB'[status]="accepted"))You will need to provide more information if you want help. Eg What are you expecting and what are you getting?
sorry, I didnt think it was relevant. It just highlights me it in red. I need to count distinct lead_id from table DB where status od this lead_id is accepted
Please, try the following:
Column = calculate(DISTINCTCOUNT('DB'[lead_id]),'DB'[status]="accepted")
Explanation: The second part for the CALCULATE is already the filter expression. You don't need to use FILTER in this case. In addition, DISTINCTCOUNT accepts only 1 parameter, so you need to close your parenthesis right after 'DB'[lead_id].
EXTRA TIP: If you want this expression to consider also the other filters applied on you report, you can use the following:
Column = calculate(DISTINCTCOUNT('DB'[lead_id]),KEEPFILTERS('DB'[status]="accepted"))it worked, thnx a lot!
there is no result, just an error. so I cant understand what is wrong with the sintaxis
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 79 | |
| 38 | |
| 31 | |
| 27 | |
| 27 |