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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Raulx_7
Helper I
Helper I

Create a new table with current date

Hi, I'm doing a dashboard, however this dashboard has a date filter (like 7 dates), and I want to display only the latest date selected.  That's why I decided to create a new table which contains the value of only the selected date, in order to use it as a filter for many graphs, is this possible? 

I have tried using Max(Dates[date]), and SELECTEDVALUE, but nothing works .

3 REPLIES 3
amitchandak
Super User
Super User

@Raulx_7 , Max from date table dependent on the calendar

 

Try like

New Table =

Var _max = maxx(Table, Table[Date])

return

calculatetable(Table, filter(Table, Table[Date] = _max ))

 

You can even try measure like

 

New measure=

Var _max = maxx(Table, Table[Date])

return

calculate([Measure], filter(Table, Table[Date] = _max ))

Thanks, I've tried this one : 

 

New Table =

Var _max = maxx(Table, Table[Date])

return

calculatetable(Table, filter(Table, Table[Date] = _max ))

 

But it says that the syntax for a table is not correct. 

Hi @Raulx_7 ,

 

Try this formula.

new table = DISTINCT(SELECTCOLUMNS('Table',"latest date",MAX('Table'[date])))

Result would be shown as below.

1.PNG

2.PNG 

 

Best Regards,

Jay

Community Support Team _ Jay
If this post helps, then please consider Accept it as the solution
to help the other members find it.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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