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.
Dear All,
I have a table in Power BI. Example below:
I want to build a measure showing the number of customer numbers, which for instance could end up in the following output in power BI:
3 rows do have customer number 1234
2 rows do have customer number 9876
1 rows does have customer number 1000
Name of mwasure in this example: 'Number of customer numbers'
Thanks!
Kind regards,
Solved! Go to Solution.
Hi,
You can create a measure with the definition ->
Thanks for your reply, however I dont get an unique count, but still a count of the total number of rows. Any other suggestion?
Hi @Anonymous ,
As far as I konw, Avantika_Thakur 's code should work in your data model.
Or you can try this code to create a calculated column.
CALCULATE(COUNT(Data[customer number]),FILTER(Data,Data[customer number] =EARLIER(Data[customer number])))
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks for your reply, however I dont get an unique count, but still a count of the total number of rows. Any other suggestion?
Hi @Anonymous ,
As far as I konw, Avantika_Thakur 's code should work in your data model.
Or you can try this code to create a calculated column.
CALCULATE(COUNT(Data[customer number]),FILTER(Data,Data[customer number] =EARLIER(Data[customer number])))
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
You can create a measure with the definition ->