Forum Discussion
Filter +/- 24 hours
- Anonymous5 years ago
Hi rmcmun ,
You could use the following formula to create a new measure :
Measure = IF ( MAX ( 'Table'[Production output time] ) >= NOW () - 1 && MAX ( 'Table'[Production output time] ) <= NOW () + 1, 1, 0 )And apply it to filter pane(set as "is 1") like this:
Please take a look at the pbix file here.
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
can you give more details. do you want this on the slicer, what type of visual are you using. providing the right amount of detail helps to get the right response.
screen shots and sample data help too.
- rmcmun5 years agoFrequent Visitor
Thanks vanessafvg,
I'm using a line chart and trying to plot expected vs. actual outputs on a production line (see screenshot).
The fact table I'm plotting from (simplifying) has the following fields:
- Production output time (datetime)
- Production output volume (decimal)
- Type (text = actual or expected)
So I need to filter the chart so that it is only displaying the actual vs. expected outputs for -24 hours and +24 hours from now.
Does that make sense?