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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
montibellin
Helper I
Helper I

How to filter table values of column1 based on column2 value

Hi Guys,

 

I've a tableA with two columns where column1 values can occur in column2.


I need to create in DAX a new table with all rows of tableA  if the column1 has value that if present in column2
the picture below can explain my goal

montibellin_0-1667168548776.png

 

1 ACCEPTED SOLUTION
VahidDM
Super User
Super User

Hi @montibellin 

 

Create your new table with this DAX expression:

Table 2 = 
Var _C2 = VALUES('Table'[Column2])
return
CALCULATETABLE('Table','Table'[Column1] in _C2)

Output:

VahidDM_0-1667169114507.png

 

 

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

Appreciate your Kudos!! 

Badges.jpg

LinkedIn | Twitter | Blog | YouTube 

View solution in original post

1 REPLY 1
VahidDM
Super User
Super User

Hi @montibellin 

 

Create your new table with this DAX expression:

Table 2 = 
Var _C2 = VALUES('Table'[Column2])
return
CALCULATETABLE('Table','Table'[Column1] in _C2)

Output:

VahidDM_0-1667169114507.png

 

 

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

Appreciate your Kudos!! 

Badges.jpg

LinkedIn | Twitter | Blog | YouTube 

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! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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