Need help with a formula, Please

Copper Contributor

I have two columns of data on sheet2 (column F and column G) that i would like to compare against one columns on sheet1(column A) and place "matched" in a column on sheet 1. I found a formula but only able to compare one column. =IF(COUNTIF(Sheet1!A:A, $F4)=0, "", "Matched") 

Thank you in advance

Rob

6 Replies

Hi Rob,

 

Could you please clarify a bit how you'd like to compare, e.g.

- value in A matches to value(s) in column F AND column G

- value in A matches to value(s) in column F OR column G

or

- values in same row in F AND/OR G match to values in A

 

The data in columns F and G are compared against column A and "matched" is placed in column K.

So, both F and G shall be met in A or only any one of them?

if data in A is in F or G.
Thank you

For both

=IF(COUNTIFS(A:A,$F4,A:A,$G4),"Matched","")

for any one

=IF(COUNTIF(A:A,$F4)+COUNTIF(A:A,$G4),"Matched","")