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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
daxishard
New Member

Filter Table by Slicer Value

Hi all, I'm new to PowerBI and am stuck on a request that seems pretty straightforward:

 

I've created a PowerBi report that is embedded in a 3rd party application.  Upon load of the report, a single filter is passed to the report to show only 1 single 'Project' record.

I have a slicer on the report that shows all 'projectbaseline' records related to the 'Project' that is passed as a filter.  The user can select a single 'projectbaseline' record in the slicer.  Each 'projectbaseline' record has a 'Created On' date field.

I would like to create a table visual that shows all 'Project Tasks' related to the Project that have a 'Created On' date after the 'Created On' date of the 'projectbaseline' record selected in the slicer.  I would like this visual to update whenever a different 'projectbasline' record is selected in the slicer.

 

I tried creating a calculated table for this, but calculated tables don't refresh when a different projectbaseline is selected in the slicer.

I created a Calculated Measure that contains the 'Created On' date of the selected 'projectbaseline'.  This measure does update whenever a different 'projectbaseline' is selected in the slicer, but I can't figure out how to filter the Project Task table based on this measure.

 

Any guidance is greatly appreciated! Thanks!

 

 

daxishard_0-1695930521970.png

 

2 REPLIES 2
daxishard
New Member

Thank You for your reply.  I'm having trouble with this part of a the 'Filter Flag' measure:

 

Filter Flag = IF( 'ProjectTasks'[CreatedDate]

 

It seems I can't select 'ProjectTasks'[CreatedDate] as this isn't an aggregate/scalar value, maybe?  So the measure won't accept this input.  Any other ideas?

 

Thanks again for your reply.

CoreyP
Solution Sage
Solution Sage

I think you need to create a measure to act as a flag to filter your project tasks table. Something like:

Filter Flag = IF( 'ProjectTasks'[CreatedDate] > 'ProjectBaseline'[CreatedDate] , 1 , 0 ). Then apply this as a filter on the visual containing your project tasks where the value equals 1. To get this to work, you may need to set bi-directional filtering on the relationship between projectbaseline and projects. And possibly between tasks and projects. Give that a go and see what happens. 

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 MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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