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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Toots
Frequent Visitor

Filter Measure by different date columns

Hi All,

 

I am setting up some sales pipeline reporting where on one visual

I would like to have the only sales with the likelihood "WON" filtered by the actual close date

Then have a target of sales filtered by the exp close date

And set an over target the manager will set on a target table.

The relationship to the date table is done by the start date

 

Any thoughts on a filtered measure or any other way?

 

2020-06-19_13h44_47.png2020-06-19_13h57_19.png

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Toots , You can join both dates with date table and use userelation to switch the relation.

 

Please find the example

https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
v-alq-msft
Community Support
Community Support

Hi, @Toots 

 

I'd like to suggest you use the USERELATIONSHIP DAX function to make the inactive relationship active during the evaluation of a model calculation.

For further information, you may refer to the document .

 

Best Regards

Allan

 

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

Hi There, The userelationship function works perfect thank you. Do you know if you can also use the filter function within this so I can filter out WON and Deleted out of the likelihood column?

 

 

AU Market Sales EC $ =
CALCULATE (
SUM ( 'AU Market Map'[Sales $] ),
FILTER(ALL('AU Market Map','AU Market Map'[Likelihood]="Target","Business Case","Early Days","Possible","Strong"))
USERELATIONSHIP ( 'Calendar'[Date], 'AU Market Map'[Exp Close Date ] )
)
amitchandak
Super User
Super User

@Toots , You can join both dates with date table and use userelation to switch the relation.

 

Please find the example

https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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