Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Fusilier2
Advocate II
Advocate II

Trying to add a date/time card to a report

I'm trying to add a card or similar to my report that will show when a report was last refreshed.

Can anybody point me to some simple instructions?

I tried following this YouTube video from the Guy in a Cube channel:

Date/Time 

However, when I get to the stage where I'm supposed to convert the query into a table (1.12), I'm not given the option to convert to a table:

date and time.PNG

Don't know if this is beacause PBI has changed since the video was made (2021) and 

I'm using the November 2024 vdesktop version, or because I'm doing something wrong? Although I think I've followed the video step by step.

Can anybody help please?

1 ACCEPTED SOLUTION
Bibiano_Geraldo
Super User
Super User

Hi @Fusilier2 ,

Go to Advanced editor and paste this M code:

let
    Source = DateTime.LocalNow(),
    #"Converted to Table" = #table(1, {{Source}}),
    #"Changed Type" = Table.TransformColumnTypes(#"Converted to Table",{{"Column1", type datetime}}),
    #"Renamed Columns" = Table.RenameColumns(#"Changed Type",{{"Column1", "Last Refreshed Date"}})
in
    #"Renamed Columns"

This will result in this table with a sinlge column:

Bibiano_Geraldo_0-1738058216645.png

 

View solution in original post

2 REPLIES 2
Fusilier2
Advocate II
Advocate II

Thank you very much. Works like a dream!

Bibiano_Geraldo
Super User
Super User

Hi @Fusilier2 ,

Go to Advanced editor and paste this M code:

let
    Source = DateTime.LocalNow(),
    #"Converted to Table" = #table(1, {{Source}}),
    #"Changed Type" = Table.TransformColumnTypes(#"Converted to Table",{{"Column1", type datetime}}),
    #"Renamed Columns" = Table.RenameColumns(#"Changed Type",{{"Column1", "Last Refreshed Date"}})
in
    #"Renamed Columns"

This will result in this table with a sinlge column:

Bibiano_Geraldo_0-1738058216645.png

 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

Find out what's new and trending in the Fabric community.