SOLVED

Return the matching value if two cells match

Copper Contributor

I am looking to create a function that checks if two cells match, then return their matching value if true. A hypothetical depiction of this function is below:

 

Does Link Work? (Reviewer 1)Does Link Work? (Reviewer 2)Hypothetical Result
YesYesYes
YesNoNOT MATCHING
YesYesYes
NoNoNo

 

I can figure out whether they match, but can't seem to get to that extra step of grabbing the value shared between cells. 

 

Previous tutorials cover entering data from a third cell, but not the values from the two cells that match. Thank you so much for any solutions or leads! 

2 Replies
best response confirmed by justinbellpsy (Copper Contributor)
Solution

@justinbellpsy 

In C2:  =IF(A2<>B2,"NOT MATCHING",A2)

HansVogelaar_0-1699304521492.png

Fill down.

Amazing! Was not aware of the capabilities of IF here. Thanks so much!