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
Yogisha
Frequent Visitor

How to filter table based on one column in another table

Hi,

 

I have to filter table values based on a column from another table in Power Query. Since I am using direct query, I can't use of merge.

Is there any way to filter other than inner join?.

 

Thanks,

 

 

1 ACCEPTED SOLUTION
v-xuding-msft
Community Support
Community Support

Hi @Yogisha ,

When we transform data in Power Query and create calculated tables with DirectQuery mode, the report will change to storage model. You could reference the document:About using DirectQuery in Power BI  to learn more about DQ mode.

I'm not clear about your actual situation. If you need the report just with DQ mode, maybe you could try to create a relationship between the tables and then use slicers to filter it in report view.

 

Best Regards,

Xue Ding

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

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

View solution in original post

2 REPLIES 2
v-xuding-msft
Community Support
Community Support

Hi @Yogisha ,

When we transform data in Power Query and create calculated tables with DirectQuery mode, the report will change to storage model. You could reference the document:About using DirectQuery in Power BI  to learn more about DQ mode.

I'm not clear about your actual situation. If you need the report just with DQ mode, maybe you could try to create a relationship between the tables and then use slicers to filter it in report view.

 

Best Regards,

Xue Ding

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

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
niteshtrehan89
Helper III
Helper III

Hi Yogisha,

 

let us suppose we have below two tables.

t1

id    name   sal

1     test1    10
2     test2    20
3     test3    30
4     test4    40

 

t2

id    Dept

1     IT
2     IT
3     Sales
4     IT

 

We can create a calculated table with the following dax if the data is in direct query mode.

 

Table =

var t2_TREATA= TREATAS(t2,t1[id],t2[dept])
var result= NATURALLEFTOUTERJOIN(t1,t2_TREATA)
return result
 

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.