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
Hello,
I am trying to use the countrows function to get the unique count of records in a function. How can I use the I tried using the following function:
#Records = Countrows( Filter( Summarize ('Order Data', 'Order Data'[Order Number], 'Order Data'[Status])), [Status] = "Delivered"))
But I keep getting an incorrect syntax error saying - "The syntax for ) is incorrect". What am I doing wrong?
How can I use countrows, filter and summarize functions together?
I'd appreciate any help!
Solved! Go to Solution.
No need for summarize - better stay away from that function, it has lots of dirty secrets
Hi,
Try this
#Records = Countrows( Filter( Summarize ('Order Data', 'Order Data'[Order Number], 'Order Data'[Status]), [Status] = "Delivered"))
Thank you very much Ashish_Mathur and lbendlin for your prompt reply.
I checked your code carefully and the problem is that there is an extra ")" in the screenshot position. You can try to modify it.
The correct code should be as provided by Ashish_Mathur.
Or you can try the method provided by lbendlin which will also give you the results you want.
Regards,
Nono Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thank you very much Ashish_Mathur and lbendlin for your prompt reply.
I checked your code carefully and the problem is that there is an extra ")" in the screenshot position. You can try to modify it.
The correct code should be as provided by Ashish_Mathur.
Or you can try the method provided by lbendlin which will also give you the results you want.
Regards,
Nono Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
Try this
#Records = Countrows( Filter( Summarize ('Order Data', 'Order Data'[Order Number], 'Order Data'[Status]), [Status] = "Delivered"))
No need for summarize - better stay away from that function, it has lots of dirty secrets
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 61 | |
| 44 | |
| 41 | |
| 36 | |
| 21 |
| User | Count |
|---|---|
| 176 | |
| 120 | |
| 106 | |
| 77 | |
| 52 |