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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Sankhadeep
Frequent Visitor

filter dashboard for last input number of days

Hello All,

 

Please provide me the solution for the mentioned scenario :

 

I have created a custom parameter where user can input for LAST ___#___ DAYS(min 1 increment by 1 max 1000)

I have a AllotedDate column which have duplicate days.

 

When the user input for the last # of days, the whole page will filter till max of allotedDate from user input # of days. The dax should respond to any user input and filter the full page.

 

Relative date filter / any other visualization is not neeeded.

 

 

Capture.PNG

 

1 ACCEPTED SOLUTION
v-cherch-msft
Employee
Employee

Hi @Sankhadeep

 

You may add below measures and use Filter measure in visual level filter.Attached the sample file for your reference.

LastNDay =
CALCULATE ( MAX ( Table2[AllotedDate] ), ALL ( Table2 ) ) - Parameter[Parameter Value]
Filter = IF(MAX(Table2[AllotedDate])>=[LastNDay],1)

1.png

Regards,

Cherie

Community Support Team _ Cherie 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

2 REPLIES 2
v-cherch-msft
Employee
Employee

Hi @Sankhadeep

 

You may add below measures and use Filter measure in visual level filter.Attached the sample file for your reference.

LastNDay =
CALCULATE ( MAX ( Table2[AllotedDate] ), ALL ( Table2 ) ) - Parameter[Parameter Value]
Filter = IF(MAX(Table2[AllotedDate])>=[LastNDay],1)

1.png

Regards,

Cherie

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

Hi @v-cherch-msft,

 

I tried your soultion it didn't worked for me. Sorry for the late responce as I was out of station. 

It will be very much helpful if u can provide some other solutions/measures regarding this problem.

 

Note : I have some dropdown filters and other data card visuals as well which doesn't take visual level /report level filter for your soltuion.

 

Regards,

Sankhadeep

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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