Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now
Hello,
I am looking to create a measure to perfrom the following:
The two tables below are linked by "User Name".
User Name | Project Name | Hours |
Tim | Project 1 | 4 |
Tim | Project 2 | 10 |
Paul | Project 3 | 2 |
Paul | Project 4 | 8 |
Paul | Project 5 | 10 |
User Name | Available Hours |
Tim | 32 |
Paul | 40 |
I need to have a display that calculates as such:
User Name | Used Hours | Remaining Available Hours |
Tim | 14 | 18 |
Paul | 20 | 20 |
Essentially the sum of each persons used hours subtracted from thier available total listed in the other table. Thanks.
Solved! Go to Solution.
Hi @KLGRIZZARD
Used Hours = SUM ( Table1[Hours] )
Remaining Available Hours =
IF (
HASONEVALUE ( Table2[Available Hours] ),
VALUES ( Table2[Available Hours] ) - [Used Hours]
)
Then use a matrix visual - Table1or2[User Name] column at the rows and [Remaining Available Hours] measure at the values
Hi @KLGRIZZARD
Used Hours = SUM ( Table1[Hours] )
Remaining Available Hours =
IF (
HASONEVALUE ( Table2[Available Hours] ),
VALUES ( Table2[Available Hours] ) - [Used Hours]
)
Then use a matrix visual - Table1or2[User Name] column at the rows and [Remaining Available Hours] measure at the values
Hi @KLGRIZZARD ,
Create two measure like below:-
Used Hours = sum(user name[hours])
Remaining Available Hours = sum(table[available hours]) - sum(user name[hours])
Thanks,
Samarth
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Thanks, the first measure I can get to work, the second, not so much.
For example sake the tables are named "Project Hours" and "Available Hours" I am not sure how that relates to the second measure.
Check out the October 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
34 | |
14 | |
12 | |
12 | |
11 |