Forum Discussion

Akes's avatar
Akes
Regular Visitor
3 years ago

Page Filter for Current LOCAL Dat

I apologize for being relatively new to PowerBI.  I am trying to learn as I go, quickly.  

 

We are in the midwest of the United States.  So UTC-5 currently, with DST.

 

I have created a rich report of Operations Data.  And am importing 10 days of underlying data.  I then copied the raw report page, and have made several sub-versions.  Each page has a different page filter.  So we have data for "overnight," for "yesterday," for "last week."  And these all work.

 

But I am having a difficult time with filtering out data for "Today."  Because Today() seems to be useless as a dynamic filter, once you upload to the PBI service.  Specifcally, as we get into evening, our "Today" rolls over to tomorrow's date.  This is frustrating to me.

 

I DO have a single column table that imports a "local time and date" value, which we use to tag the latest refresh on the report.  But how can I use that to filter my page?

 

  • Could I use this value as a page level filter.  Something like:  where "LocalTime"[LocalTime] = OrderTime ?
  • Or could I create a helper column in my dataset, using the same kind of logic?  Something like: ?

 

 

if DateTime.Date([DueTime])=DateTime.Date('LocalTime'[LocalTime]) then "YES" else "NO"​

 

 

It does not like that formula, but I am hoping my syntax is the issue

 

  • Is there another better answer that I am not finding

PS - Why oh why does MS not create a "Local Time Zone" setting for cloud reports?

1 Reply

  • Akes , Try like

     

    if DateTime.Date([DueTime])=Date.From(DateTime.FixedLocalNow()) then "YES" else "NO"​