Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
fblourido
New Member

Help building measure in DAX

Hi all!

 

I'm sorry if this is a post repetition but I couldn't find an answer and I'm going around in circles for days trying to understand why this doesn't work. My head hearts! 😄

 

I've the following model and I´m trying to find the "Total cost HR" in the "Custo HR" table, being able to filter by "Contratos" and "Recursos" and I'm not being able to as it shows on the below table. I was expecting that "Total cost HR" was affect by the "Hours" in the "Timesheet" table but I see now that there is no direct way to relate "Hours" to "Total cost HR".

 

Well I'm guessing now that perhaps the way to go is to build a measure using DAX but my skills are still very limited. I'm able to create a measure that gives me the "Cost per Hour" on a given temporal slice, but that cost is not affected by the other selections on "Contratos" and hence by "Hours" on "Timesheet" table. With that I guess I could eventually create a measure for the cost on a given "Contratos" if I could multiply the measure "Cost per Hour" by the hours on a given "Contratos" filtered "Timesheet" but I'm not being able to get those "hours" on "Timesheet" table. They appear on the table but I don't no how to get them.

 

Can you please help? Thanks in advance for your time!

 

fblourido_1-1637186819160.png

 

 

fblourido_0-1637186750671.png

 

fblourido_4-1637189482191.png

 

 

 

 

1 REPLY 1
Stachu
Community Champion
Community Champion

Can you add sample tables (in format that can be copied to PowerBI) from your model with anonymised data? Like this (just copy and paste into the post window).

Column1Column2
A1
B2.5

 



Did I answer your question? Mark my post as a solution!
Thank you for the kudos 🙂

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.