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 have a table loaded into PowerBI called 'Worklogs'. To make a complicated issue a bit simpler, the table looks something similar to this:
| Logged Time (Hours) | Project Key | Project Code |
| 0.5 | EQ-1 | EQ |
| 0.75 | EQ-1 | EQ |
| 1 | EQ-91 | EQ |
| 5 | EQ-418 | EQ |
| 5 | EQ-418 | EQ |
I want to create two more columns - one is a sum of all time logged against the Project Code EQ (as I do have other PCs in the table), and another would be a sum of all time logged against the Project Code EQ but excluding the Time Logged against Project Key EQ-418.
Is this possible? Should I be using the FILTER function or something else?
Thank you for any help in advance!
Solved! Go to Solution.
@FJH2024 for calculated columns
sum of all time logged against the Project Code EQ = CALCULATE(SUM('Table 1'[Logged Time (Hours)]),FILTER('Table 1','Table 1'[Project Code]="EQ"))
sum of all time logged against the Project Code EQ but excluding the Time Logged against Project Key EQ_418 = 'Table 1'[sum of all time logged against the Project Code EQ]-CALCULATE(SUM('Table 1'[Logged Time (Hours)]),FILTER('Table 1','Table 1'[Project Code]="EQ"&&'Table 1'[Project Key]="EQ-418"))
@FJH2024 for calculated columns
sum of all time logged against the Project Code EQ = CALCULATE(SUM('Table 1'[Logged Time (Hours)]),FILTER('Table 1','Table 1'[Project Code]="EQ"))
sum of all time logged against the Project Code EQ but excluding the Time Logged against Project Key EQ_418 = 'Table 1'[sum of all time logged against the Project Code EQ]-CALCULATE(SUM('Table 1'[Logged Time (Hours)]),FILTER('Table 1','Table 1'[Project Code]="EQ"&&'Table 1'[Project Key]="EQ-418"))
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 35 | |
| 34 | |
| 31 | |
| 28 |
| User | Count |
|---|---|
| 137 | |
| 102 | |
| 68 | |
| 66 | |
| 64 |