Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi there,
I have data that looks similar to this:
Purchase Order Number: Vendor Name:
001 Vendor A
002 Vendor B
003 Vendor B
004 Vendor C
005 Vendor C
006 Vendor C
Each purchase order number is a distinct value, but a vendor can have multiple purchase orders. So with this data I am trying to find the average number of purchase orders per vendor. In this case, I would be looking for a DAX formula that would return the answer of 2, since the average count of POs that a vendor has would be 2. Any help is greatly appreciated.
Solved! Go to Solution.
Hi @Anonymous
Create measures
distinctount = CALCULATE(DISTINCTCOUNT('Table'[Purchase Order Number]),ALLEXCEPT('Table','Table'[Vendor Name]))
average = AVERAGEX(DISTINCT('Table'[Vendor Name]),[distinctount])
Hi @Anonymous
Create measures
distinctount = CALCULATE(DISTINCTCOUNT('Table'[Purchase Order Number]),ALLEXCEPT('Table','Table'[Vendor Name]))
average = AVERAGEX(DISTINCT('Table'[Vendor Name]),[distinctount])
If my understanding is correct, you can use the following formula
Eric Ji | Senior Business Intelligence Consultant
www.designmind.com
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |