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.
I have a calculated column that looks at a cost type column and if the value in that colum is Labor or non-engineering labor, it will divide the actual costs for the month by the number of completed days and then multiply that number by the total number of working days in the month to determine a full month factored cost if spending continues at the same rate. Factored Labor = IF(OR('EOC DATA'[EOC_TYPE_CD] = "LABOR",'EOC DATA'[EOC_TYPE_CD] = "NONENGR"), (('EOC DATA'[Jan EOC ACT]/9)*19)) Currently, I have to change this formula each week manually. Is there a better way? Can I somehow enter the two numbers in a table and have the formula look at that table?
Solved! Go to Solution.
Probably. I can imagine a date table that has the number of working days per week and per month like:
WeekNum,WorkingDaysWeek,WorkingDaysMonth
1,5,19
2,9,19
3,15,19
4,19,19
5,5,17
6,9,17
7,15,17
So, 19 working days total in Jan, 17 in Feb let's say. Then you could use things like WEEKNUM(TODAY()) and look up the right values essentially.
Probably. I can imagine a date table that has the number of working days per week and per month like:
WeekNum,WorkingDaysWeek,WorkingDaysMonth
1,5,19
2,9,19
3,15,19
4,19,19
5,5,17
6,9,17
7,15,17
So, 19 working days total in Jan, 17 in Feb let's say. Then you could use things like WEEKNUM(TODAY()) and look up the right values essentially.
Thanks I got this to work by adding the table you suggested. My final formula replaces the /9)*19) portion with: Calculate(SUM('Factoring Table'[WorkingDaysWeekCM]),(WEEKNUM(TODAY())='Factoring Table'[WeekNum]))*Calculate(SUM('Factoring Table'[WorkingDaysMonthCM]),(WEEKNUM(TODAY())='Factoring Table'[WeekNum])))))
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 |
---|---|
111 | |
96 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |