# Solved Compare Column A to Column D

November 29, 2011 at 04:57:49
Specs: Linux i686
 Ok so I've been racking my brain over this and cannot for the life of me figure it out. I am trying to achieve the following;Lets say I have the following values.A:1 Blue D:1 BlueA:2 Green D:2 GreenA:3 Purple D:3 WhiteA:4 Pink D:4 YellowA:5 Yellow D:5 BlackA:6 Orange D:6 IndigoA:7 Green A:8 Pink A:9 Yellow A:10 Indigo A:11 Green A:12 Black A:13 White What formula would I use If was trying to determine if the Values in column A MATCHED ANY of the Values in Column D. Further to this, if Column A did match any value in Column D then a Yes or No would appear in the cell next to the corresponding value in Column A (i.e. Column B)Not sure if I am getting across what I'm trying to do...Thanks guys - appreciate any help

See More: Compare Column A to Column D

#1
November 29, 2011 at 06:38:20
✔ Best Answer
 A posting tip:In the future, try to use a subject line that is relevant to the contents of your post. If everyone used a generic subject line such as "Excel Formula Help!", we wouldn't be able to tell one question from another. Browse through the other threads in this forum and look at the types of subject lines that others have used.I have edited the subject line of this thread.DerbyDad03Office Forum ModeratorClick Here Before Posting Data or VBA Code ---> How To Post Data or Code.

Report •

#2
November 29, 2011 at 06:47:57
 You could try the COUNTIF function as follows:Enter this in B1 and drag it down:=IF(COUNTIF(\$D\$1:\$D\$6,A1)>0,"Yes","No")You could also use ISNA and VLOOKUP:=IF(ISNA(VLOOKUP(A1,\$D\$1:\$D\$6,1,0)),"No","Yes")If VLOOKUP returns a #N/A error, then the value wasn't found. The ISNA function checks for that error.Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

Report •

#3
November 29, 2011 at 06:59:24
 Hi DerbyDad03Thanks for the solution and the Subject Tip!Will keep that in mind when posting in the future.I'll let you know whether or not the solution worked.Cheers

Report •

Related Solutions

#4
November 29, 2011 at 21:28:37
 Thanks DerbyDad03 - it worked like a charm. I can now manipulate the data using datapilot as well.Thanks again

Report •