Forum Discussion
vrmntmtt
4 years agoFrequent Visitor
Problem with Calculating OEE values per production shift
Hi, I am making a dashboard to represent OEE values from online values. I need to break it down to different shifts. I dont have any problems with the morning and evening shift, but the night sh...
- 4 years ago
It's because no time is both > 22:00:00 and <= 06:00:00 because that is 6 AM the next day. You will need to split it into 2 compares.
%_good_products_Night_shift = CALCULATE ( [%_good_products], '4xCounter5'[received_at_only_time] > TIMEVALUE ( "22:00:00" ) && '4xCounter5'[received_at_only_time] <= TIMEVALUE ( "23:59:59" ) || '4xCounter5'[received_at_only_time] >= TIMEVALUE ( "00:00:00" ) && '4xCounter5'[received_at_only_time] <= TIMEVALUE ( "06:00:00" ) )
jdbuchanan71
4 years agoSuper User
It's because no time is both > 22:00:00 and <= 06:00:00 because that is 6 AM the next day. You will need to split it into 2 compares.
%_good_products_Night_shift =
CALCULATE (
[%_good_products],
'4xCounter5'[received_at_only_time] > TIMEVALUE ( "22:00:00" ) && '4xCounter5'[received_at_only_time] <= TIMEVALUE ( "23:59:59" ) ||
'4xCounter5'[received_at_only_time] >= TIMEVALUE ( "00:00:00" ) && '4xCounter5'[received_at_only_time] <= TIMEVALUE ( "06:00:00" )
)- vrmntmtt4 years agoFrequent Visitor
Thank you, that worked perfectly. I was busy with making two different measures. But this is much better.