The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have summarized table that I created through DAX from direct query table. It look like:
Name | Effort in days | Team |
XYX | 5 | 1 |
XYX | 3 | 2 |
ABC | 3 | 1 |
ABC | 2 | 2 |
I need to create another column that tells me how much % of effort(of the total effort spent) a person spent in the team. So the output would look like:
Name | Effort in days | Team | Percent |
XYX | 5 | 1 | 63% |
XYX | 3 | 2 | 38% |
ABC | 3 | 1 | 60% |
ABC | 2 | 2 | 40% |
I am fairly new to Power BI, please help.
Thanks
Anuj
Solved! Go to Solution.
Hi,
=
DIVIDE(
[Effort in days],
CALCULATE(
SUM( [Effort in days] ),
ALLEXCEPT(
Table1,
Table1[Name]
)
)
)
Regards
Hi,
=
DIVIDE(
[Effort in days],
CALCULATE(
SUM( [Effort in days] ),
ALLEXCEPT(
Table1,
Table1[Name]
)
)
)
Regards
Percent =
DIVIDE(
SUM('Table'[Effort in days]),
CALCULATE(
SUM('Table'[Effort in days]),
ALLEXCEPT(
'Table',
'Table'[Name]
)
)
)
This is a Calculated Column, not a Measure, so it's not necessary to apply an aggregation to the Effort in days column in this case.
Regards
Oh okay, so that is why. You made a calculated column while I was making a calculated measure. Sorry for the unnecessary reply. I would delete it if I had the option to.
Regards,
Aditya
Hi Aditya,
"Fix" seems a touch strong! 🙂
From what I understand, the use of fully qualified references to columns within the same table is only "recommended" practice, not obligatory. As such, I would have to disagree that your version constitutes a 'fix' of mine.
Regards
Thanks a lot for quick solution
User | Count |
---|---|
78 | |
73 | |
38 | |
30 | |
28 |
User | Count |
---|---|
107 | |
100 | |
55 | |
49 | |
45 |