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 have this little problem that with my knowledge i cant solve (very noob), the thing is i have this table where on some days i got 2 columns with hours, when this is true, the values on the second column should set the day after for example, on 02-02-2020 got 5 hours in total, 3 in the first column and 2 on the second, the 2 hours should set on 02-03-2020, soo, i was trying with some measures, because i need to show the total per day
For example on the 13-07-2019 my total hours is 17, on 14-07-2019 is 27 (6+2+6+1+7+2+3) and soo on...
Solved! Go to Solution.
Hi,
Not sure if i understand entirely but if you're asking for a measure that adds the hours from the first column with hours from the previous day in the second column then something like below could possibly work
TotalHours =
VAR PreviousDayDate = MAX('Table'[Date]) -1
RETURN
SUM('Table'[Hours1]) +
CALCULATE(
SUM('Table'[Hours2]),
'Table'[Date] = PreviousDayDate
)
@FranciscoJVV I am little confused about what you asking and also your calculations dont add up.
can you explain from a business perspective what is going on here?
also can you demonstrate what you want the value to say
for example for the 13/07 your total should be 22? if not please explain the rule clearly.
Proud to be a Super User!
the thing is I work with day and night shifts, and i need to get the total working hours of a person per day, so when in night shifts sometimes they start at 23:00 and end on 02:00, so there is 3 hours, 1 hour and then 2 hours the day after, the problem is i got the day when they start working, so in the image the first column shows the hours made THAT day, and the second column shows the hours made the day AFTER, and i need to show all the hours made for day
Hi,
Not sure if i understand entirely but if you're asking for a measure that adds the hours from the first column with hours from the previous day in the second column then something like below could possibly work
TotalHours =
VAR PreviousDayDate = MAX('Table'[Date]) -1
RETURN
SUM('Table'[Hours1]) +
CALCULATE(
SUM('Table'[Hours2]),
'Table'[Date] = PreviousDayDate
)
this works!! thanks, looking to your solution I think i would never get that, thank you
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 |
---|---|
110 | |
94 | |
80 | |
67 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |