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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
TomLU123
Helper III
Helper III

Validate the Data between two tables

Dear experts, 

 

I am currently building a report to validate the Location ID stored in a Participant Table. I wish to add a custom column "Location Validation Result" by comparing the location ID stored in Participant Table with Location Table. If it is a value stored in the Location Table, the result in that custom coumn will show Valid. If not found, the value will be Invalid. 

 

Participant Table:

PTSS2.png

 

 

Location Table:

LL T SS.png

 

Is it possible to use the express to do that?

Many thanks for your great help!

1 ACCEPTED SOLUTION

If you have a relationship between your Location ID columns, then you could do this:

 

Column = IF(NOT(ISBLANK(CALCULATE(COUNTROWS('Locations')))),"Valid","Invalid")

Also, next time, please post text instead of screen shots of your data. Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

4 REPLIES 4
Greg_Deckler
Super User
Super User

Why us US2222 invalid?


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Hi Greg! Sorry, that is a typo. US2222 is valid. 

If you have a relationship between your Location ID columns, then you could do this:

 

Column = IF(NOT(ISBLANK(CALCULATE(COUNTROWS('Locations')))),"Valid","Invalid")

Also, next time, please post text instead of screen shots of your data. Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Hi Greg, thank you so much for your help! I will post text next time. Thank you again for your help and advise!

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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