Forum Discussion
gsc-nvr
5 years agoFrequent Visitor
Modifying bi-weekly data to be weekly
Hi folks, brand new user of Power BI here with a question I can't search an answer for. I have a table of salary hours which reports by payroll period (every two weeks), while all my other data (...
- 5 years ago
Thank you lbendlin for pointing me in the direction of a date table - that helped solve part of the puzzle. Using a date table and the below measure, I was able to smooth out my salary hours across two weeks as desired.
SalaryHours Smoothed = if( ISBLANK(SUM(SalaryHours[Hours])), CALCULATE( DIVIDE(SUM(SalaryHours[Hours]),2), DATEADD('Calendar'[Date],-7,day) ), DIVIDE(SUM(SalaryHours[Hours]),2) )
v-yalanwu-msft
5 years agoCommunity Support
Hi, gsc-nvr ;
I think it is better to use DAX in PowerBI, since you are not very clear about your data and the results you want to output, can you share simple data and the results you want to output after removing sensitive information?