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.
Hello,
I'm trying to calculate a column that will summarize [SUMMARY] hours by End of Week. There could be a number of PAY TYPES.
SAMPLE TABLE
EMP ID
DATE
HOURS
PAY TYPE
END OF WEEK
SUMMARY
1 | 8/22/2021 | 0 | Regular | 8/28/2021 | 40 |
1 | 8/23/2021 | 8 | Regular | 8/28/2021 | 40 |
1 | 8/24/2021 | 8 | Regular | 8/28/2021 | 40 |
1 | 8/25/2021 | 8 | Regular | 8/28/2021 | 40 |
1 | 8/26/2021 | 8 | Regular | 8/28/2021 | 40 |
1 | 8/27/2021 | 8 | Regular | 8/28/2021 | 40 |
1 | 8/28/2021 | 8 | Overtime | 8/28/2021 | 8 |
Thanks in advance!
Solved! Go to Solution.
@Anonymous
pls try to create a column
Column = CALCULATE(sum('Table'[hours]),ALLEXCEPT('Table','Table'[EMP ID],'Table'[Pay type],'Table'[end of week]))
Proud to be a Super User!
Hi,
This calculated column formula works
=CALCULATE(SUM(Data[HOURS]),FILTER(Data,Data[END OF WEEK]=EARLIER(Data[END OF WEEK])&&Data[EMP ID]=EARLIER(Data[EMP ID])&&Data[PAY TYPE]=EARLIER(Data[PAY TYPE])))
Hope this helps.
Desired output:
@Anonymous
could you pls provide some sample data?
Proud to be a Super User!
I hope this helps....
@Anonymous
I am confused about this. I have seen this in your prevous reply. Is this your sample data or expected output? If this is the sample data, could you pls provide the expected output?
Proud to be a Super User!
The expected output is the SUMMARY column.
@Anonymous
pls try to create a column
Column = CALCULATE(sum('Table'[hours]),ALLEXCEPT('Table','Table'[EMP ID],'Table'[Pay type],'Table'[end of week]))
Proud to be a Super User!
@Anonymous , the expected output is not clear
Apologies, formatting error. Screenshot below:
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
98 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
100 | |
86 | |
64 |