Forum Discussion
Time Intelligence not working
- 2 years ago
Hi samoberoi - Can you try the below measure:
TotalHoursWithinDateRange =
CALCULATE(
SUM('Table_Eng'[Column A]),
USERELATIONSHIP('Table_Comm'[Id], 'Table_Eng'[Id]),
DATESBETWEEN(
'Dates'[Date],
DATE(YEAR(TODAY()), MONTH(TODAY()), 1), -- Start of current month
EOMONTH(TODAY(), 0) -- End of current month
)
) / 7.5 -- Convert hours to daysHere , i have highlighted the changes. Pleas use the above and let know.
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!! - Anonymous2 years ago
Hi,
Thanks fot the solution rajendraongole1 privided and i want to offer some more information for user to refer to.
hello samoberoi , you can try the following measure
Measure = VAR a = CALCULATE ( SUM ( Table_Eng[Column A] ), USERELATIONSHIP ( Table_Comm[Id], Table_Eng[Id] ), DATESBETWEEN ( Dates[Date], EOMONTH ( TODAY (), -1 ) + 1, EOMONTH ( TODAY (), 0 ) ) ) RETURN DIVIDE ( a, 7.5 )Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi samoberoi - Can you try the below measure:
TotalHoursWithinDateRange =
CALCULATE(
SUM('Table_Eng'[Column A]),
USERELATIONSHIP('Table_Comm'[Id], 'Table_Eng'[Id]),
DATESBETWEEN(
'Dates'[Date],
DATE(YEAR(TODAY()), MONTH(TODAY()), 1), -- Start of current month
EOMONTH(TODAY(), 0) -- End of current month
)
) / 7.5 -- Convert hours to days
Here , i have highlighted the changes. Pleas use the above and let know.
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!
- samoberoi2 years ago
Helper III
Hi,
Is it possible to make it a bit more dynamic? For example it should calculate the sum for each month of the year January, Feb, March, etc individually by itself rather than by creating different measures for each separate month?
Thanks a lot for your help. Your solution as well as Yolo Zhu's solution for the last query worked perfectly fine for the last query.
Regards