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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
ezequiel
Microsoft Employee
Microsoft Employee

Join tables (not in)

Hi

 

I have table A with emails and table B with emails and status. I need to show in PBI the emails from table B with Status='Active'  that are not in Table A. Is there a simple way to do it?

 

Thanks!

 

Ezequiel

3 REPLIES 3
v-chuncz-msft
Community Support
Community Support

@ezequiel 

 

You may refer to the following post.

https://community.powerbi.com/t5/Desktop/Need-help-to-implement-sql-query-to-dax/m-p/794177#M382301

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Nathaniel_C
Community Champion
Community Champion

@ezequiel ,

Try EXCEPT()  

 

If this solves your issues, please mark it as the solution, so that others can find it easily. Kudos are nice too.
Nathaniel

Syntax
DAX

Copy
EXCEPT(<table_expression1>, <table_expression2>  
Parameters
Term	Definition
Table_expression	Any DAX expression that returns a table.
Return value
A table that contains the rows of one table minus all the rows of another table.

Remarks
If a row appears at all in both tables, it and its duplicates are not present in the result set. If a row appears in only table_expression1, it and its duplicates will appear in the result set.

The column names will match the column names in table_expression1.

The returned table has lineage based on the columns in table_expression1 , regardless of the lineage of the columns in the second table. For example, if the first column of first table_expression has lineage to the base column C1 in the model, the Except will reduce the rows based on the availability of values in the first column of second table_expression and keep the lineage on base column C1 intact.

The two tables must have the same number of columns.

Columns are compared based on positioning, and data comparison with no type coercion.

The set of rows returned depends on the order of the two expressions.

The returned table does not include columns from tables related to table_expression1.




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

Proud to be a Super User!




Is it possible to apply the EXCEPT adding an additional filter? The reason is that I need to get the results only when the status of the email is 'Active' and this value is on other field.

 

Thanks,

 

Ezequiel


@Nathaniel_C wrote:

@ezequiel ,

Try EXCEPT()  

 

If this solves your issues, please mark it as the solution, so that others can find it easily. Kudos are nice too.
Nathaniel

Syntax
DAX

Copy
EXCEPT(<table_expression1>, <table_expression2>  
Parameters
Term	Definition
Table_expression	Any DAX expression that returns a table.
Return value
A table that contains the rows of one table minus all the rows of another table.

Remarks
If a row appears at all in both tables, it and its duplicates are not present in the result set. If a row appears in only table_expression1, it and its duplicates will appear in the result set.

The column names will match the column names in table_expression1.

The returned table has lineage based on the columns in table_expression1 , regardless of the lineage of the columns in the second table. For example, if the first column of first table_expression has lineage to the base column C1 in the model, the Except will reduce the rows based on the availability of values in the first column of second table_expression and keep the lineage on base column C1 intact.

The two tables must have the same number of columns.

Columns are compared based on positioning, and data comparison with no type coercion.

The set of rows returned depends on the order of the two expressions.

The returned table does not include columns from tables related to table_expression1.


@Nathaniel_C wrote:

@ezequiel ,

Try EXCEPT()  

 

If this solves your issues, please mark it as the solution, so that others can find it easily. Kudos are nice too.
Nathaniel

Syntax
DAX

Copy
EXCEPT(<table_expression1>, <table_expression2>  
Parameters
Term	Definition
Table_expression	Any DAX expression that returns a table.
Return value
A table that contains the rows of one table minus all the rows of another table.

Remarks
If a row appears at all in both tables, it and its duplicates are not present in the result set. If a row appears in only table_expression1, it and its duplicates will appear in the result set.

The column names will match the column names in table_expression1.

The returned table has lineage based on the columns in table_expression1 , regardless of the lineage of the columns in the second table. For example, if the first column of first table_expression has lineage to the base column C1 in the model, the Except will reduce the rows based on the availability of values in the first column of second table_expression and keep the lineage on base column C1 intact.

The two tables must have the same number of columns.

Columns are compared based on positioning, and data comparison with no type coercion.

The set of rows returned depends on the order of the two expressions.

The returned table does not include columns from tables related to table_expression1.

 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors