cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
gabrielvigo Regular Visitor
Regular Visitor

Last 30 days, according to date selection.

Hello everyone.

 

I need make the line chart with the last 30 days, acording to date selection.

My calendar is linked to my sales table.

 

Depending on the filter date selection, I need a line chart with the last 30 days.

EJ: DateSales <= "DateSelection" && DateSales >= "DateSelection - 30".

 

It's not the last 30 days from today. It's from the date selected in the filter.

 

 

1 REPLY 1
Community Support Team
Community Support Team

Re: Last 30 days, according to date selection.

hi, @gabrielvigo

After my test, you may try to this way as below:

Add a last 30 day column for date table

last 30 date = DATEADD('Date'[Date],-30,DAY )

then use this column for the line chart  and basic date column for slicer

for example:

when I select date from 2018-03-09 to 2018-03-23 it returns from 2018-02-07 to 2018-02-21

14.JPG

Best Regards,

Lin

 

 

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

Helpful resources

Announcements
Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Power BI Helps Homeless and Trouble Youth

Power BI Helps Homeless and Trouble Youth

We spoke with Power BI Super User, Greg Deckler, about his charity work

MBAS Gallery

Watch Sessions On Demand!

Continue your learning in our online communities.

Users Online
Currently online: 43 members 950 guests
Please welcome our newest community members: