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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Create a Measure using a two different filtered visual

Hi All,

 

Trying to work this out for quite a while, i have two visuals with different slicers for filtering, i would like to be able to use the output from the filtered viusals in another measure which is not having filtering 

 

For example 

Visual 1 - Filted for a date range of 1 week gives sales in that 1 week 

Visual 2 - Filted for a date range of 1 Month gives sales in that 1 Month

3rd Visual - Should be able to provide a variance % based on the values in the filtered visual 1 and Visual 2

 

Thanks in Advance

1 ACCEPTED SOLUTION

Hi @Anonymous,

Now I think the results are correct. Please take a look at this new pbix.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




View solution in original post

8 REPLIES 8
_AAndrade
Super User
Super User

Hi @Anonymous,

I'm attaching a pbix file with my solution.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




Anonymous
Not applicable

Hi @_AAndrade 

 

Thanks a lot for your time taken to help on this my visualization currently looks like below, with slicers which can be changed dynamically the end result is the variance % = (407-301)/301, basically i need to be able to harvest the value in the filtered baselines measures to do this calculation.

 

thomas_1979_1-1717073865965.png

 

Please sendo me your pbix file and I Will take a look.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




Anonymous
Not applicable

Hi @_AAndrade  Thanks for your support, please find the link to pbix file not able to upload due to restrictions in place.

 

Variance Calc.pbix

Hi @Anonymous,

Take a look to the pbix file i'm attaching and see if this is what you're looking for.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




Anonymous
Not applicable

Hello @_AAndrade 

 

The variance% should come as 78%

 

thomas_1979_0-1717154069934.png

However as per the .pbix you shared this is 60%

thomas_1979_1-1717154201046.png

 

Basically if you remove the measure and use the measur Weekly Baselines you in the visual it will give you a value of all the count didvided by the Unique months. What i would need is extract 355 and 1625 and store and make the required calculations. Hope that help

 

Hi @Anonymous,

Now I think the results are correct. Please take a look at this new pbix.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




danextian
Super User
Super User

Hi @Anonymous ,

 

You will have to use two disconnected tables and three  separate measures that gets filtered based on the slicer selections from the two disconnected tables. Assuming that you'll be  filtering by date, your model would look something like below:

danextian_0-1716986506097.png

The two tables inside the red box are not connected to the fact table but which selection will be used to filter a measure referencing the fact table. Example measure:

Measure01 = 
CALCULATE (
    [Total Transactions],
    KEEPFILTERS ( Dates[Date] IN VALUES ( Dates01[Date] ) )
)

Measure02 = 
CALCULATE (
    [Total Transactions],
    KEEPFILTERS ( Dates[Date] IN VALUES ( Dates02[Date] ) )
)

Measure03 = 
[Measure02] - [Measure01]

Please see attached pbix for reference.

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

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.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.