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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
swheeler
Regular Visitor

dynamic filtering of a virtual table using a measure

Hello

 

I'm looking for advice on an issue (I'm new to Power BI).  I have data that is used for benchmarking.  The relevant table contains both the data to be benchmarked (dataA) and the data against which it will be benchmarked (dataB).

 

To separate the data so that dataA is not included in dataB, as it's not good practice to include the data to be benchmarked in the data that it will be benchmarked against, I have created a virtual table that is filtered by a measure [Active Org].  The measure is controlled by a slicer that selects the client allowing us to see their data (dataA) in comparison with dataB.

 

This virtual table it relatively straightforward:

 

VirtualTable1 = filter(DataTable,DataTable[OrgID] = [Active Org])
 
the table itself doesn't appear to physically filter, but measures based on the table respond to the slicer.
 
What I'd like to do it create the corresponding table containing dataB using the opposite command, such as:
 
VirtualTable2 = filter(DataTable,DataTable[OrgID] <> [Active Org])
 
but . . . I can't get this to work at all.
 
Can anybody advice here, please?
 
Kind regards
1 ACCEPTED SOLUTION
FreemanZ
Super User
Super User

calculated table is not supposed to be responsive to the slicer. I would suggest you simplify your report, upload your pbix file here and let us see how it could be solved.

View solution in original post

4 REPLIES 4
FreemanZ
Super User
Super User

calculated table is not supposed to be responsive to the slicer. I would suggest you simplify your report, upload your pbix file here and let us see how it could be solved.

thank you very much - I'm not oging to upload the pbix, but I take your point and advice.

 

 

swheeler
Regular Visitor

thank you - unfortunately that doesn't work 

djurecicK2
Super User
Super User

You could try this:

 

VirtualTable2 = filter(DataTable,NOT(DataTable[OrgID] = [Active Org]))

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors