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
Hi all,
I'm new with Power BI and queries. The situation is as folllowed:
I'm using the following measurement to calculate the cost per hire over a year.
CPH = SUM(Recruitmentchannel[cost])/Countrows(NewEmployees)
That works great, but if a click a month in the visualization. The calculation is wrong. So when i select a month i want the measurement to be like this:
CPH = SUM(Recruitmentchannel[cost])/12/Countrows(NewEmployees)
Does anyone know how to fix this problem? It would be much appreciated, cause it's for my final paper.
Cheers,
Kjell
Solved! Go to Solution.
CPH = IF(HASONEVALUE('Table'[Month]),SUM(Recruitmentchannel[cost])/12/Countrows(NewEmployees),SUM(Recruitmentchannel[cost])/Countrows(NewEmployees))
CPH = IF(HASONEVALUE('Table'[Month]),SUM(Recruitmentchannel[cost])/12/Countrows(NewEmployees),SUM(Recruitmentchannel[cost])/Countrows(NewEmployees))
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 19 | |
| 10 | |
| 9 | |
| 8 | |
| 7 |