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

Compare the columns between two tables and return true

Hi All,

 

We have two tables 1 from direct query and other from import mode, i have to compare the columns from direct query , import mode and return output as true if they match else false .

 

Posted date is from direct query and package_recieved date is from import., 

VenkateshMGu_0-1699033071885.png

I need this logic in  direct query table for each id it  has to check IF (posted_date <= package_received_date ,"TRUE","FALSE")

 

Thanks in Advance

4 REPLIES 4
v-xinruzhu-msft
Community Support
Community Support

Hi @VenkateshMGu 

If your table have the relationship, you can consider to create a measure

e.g 

Measure =
IF (
    MAX ( Table1[posted_date] ) <= MAX ( Table2[package_received_date] ),
    TRUE (),
    FALSE ()
)

Best Regards!

Yolo Zhu

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

lbendlin
Super User
Super User

Are these tables connected to a common dimension table?

Yes , the relationship is many to 1 and 1 to many , common table has one and moreover it is like a bridge table.

Hopefully not.

 

Please provide sample data (with sensitive information removed) that covers your issue or question completely, in a usable format (not as a screenshot). Leave out anything not related to the issue.
If you are unsure how to do that please refer to https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Please show the expected outcome based on the sample data you provided.

If you want to get answers faster please refer to https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

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.