cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Creating a relationship with current date function "NOW()" to show the data for that day.

Hello,

 

My Goal: Make a visualization that shows todays date by creating a column using Get Date = NOW(). It should also show data for that day. Such as the Julian date, the % of the year that has passed (example: 20 Jan = 5.5%, May 29 (today) = 40.4%), and the % goal for the end of month. End result should be a visual that updates each day. A makeshift visual is below:

 

3.png

 

Issue: I have a date table that includes information that is unique to each date in columns. I created a column on this table for todays date with NOW(). Adding the column added todays date to every row, making this dificult.

 

Attempts:

- I have tried using filters, but would need to manualy change the date every day.

- I have tried putting the Get Date = NOW() column on a differnt table, the data was very messy and hard to work with.

- I have considered using Functions and measures. I am not really sure what would be best. I considered something like:

 

Today Visual =

IF(

        ('Table'[Data Date] = 'Table'[Get Date]) = True

        Return 'Table'[Data Date]

)

 

That is bad, but in short, if the Data Date is todays date (Get Date) show the rest of the data in the row. Creating this relationship isn't easy.

I also considered Date/Time functions but don't know which would be best. Also of note, I am using fiscal years. Not calander years. Additional screen captures below:

 

2.png

First.png

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Creating a relationship with current date function "NOW()" to show the data for that d

Hi @nmyre ,

 

Like this?

Today = TODAY()
Today_Visual = 
IF(
    'Table 2'[Date] = 'Table 2'[Today],
    'Table 2'[Date]
)

ff8.PNG

 

Try to use TODAY() function instead of NOW() function.

 

Best regards,
Lionel Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Highlighted
Super User IV
Super User IV

Re: Creating a relationship with current date function "NOW()" to show the data for that d

@nmyre , Not sure I got it. You can get use a relative date filter and use that

https://docs.microsoft.com/en-us/power-bi/visuals/desktop-slicer-filter-date-range

 

You can have a column like this in date calendar and filter on today

Is Today = if('Date'[Date]=TODAY(),"Today",[Date]&"")

 

Or have measure like

Calculate([Measure], Table[Date]=Today())

Calculate([Measure], Date[Date]=Today())



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
My Recent Blog -Week is not so Weak Connect on Linkedin

Proud to be a Super User!

Highlighted
Community Support
Community Support

Re: Creating a relationship with current date function "NOW()" to show the data for that d

Hi @nmyre ,

 

Like this?

Today = TODAY()
Today_Visual = 
IF(
    'Table 2'[Date] = 'Table 2'[Today],
    'Table 2'[Date]
)

ff8.PNG

 

Try to use TODAY() function instead of NOW() function.

 

Best regards,
Lionel Chen

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted
Frequent Visitor

Re: Creating a relationship with current date function "NOW()" to show the data for that d

@v-lionel-msft 

 

You crazy son of a gun, you did it! Makes so much sense now that I see it.

 

Thanks so much!

Helpful resources

Announcements
Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Using the Community

Using the Community

Need help with the Power BI Community? Our 'Using the Community' support articles are a great place to start.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Power Platform 2020 release wave 2 plan

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors