# I would like to compare 2 columns.

Solved/Closed
dsrice Posts 2 Registration date Wednesday March 20, 2013 Status Member Last seen March 20, 2013 - Mar 20, 2013 at 06:18 PM
Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 - Mar 22, 2013 at 07:09 PM
Hello,

I would like to compare 2 columns A to F, if the value is the same I would like to populate the value of column C with the value from Column G. Does anyone know the best way to to this.

Here is the data:
A B C D E F G
BID Pictures Errors Percentage BID Errors
0 3 #N/A 10 5
1 203 #N/A 12 42
2 5676 #N/A 14 5
3 1302 #N/A 15 278
5 2 #N/A 19 124
8 651 #N/A 21 62
9 6191 #N/A 35 97
10 7063 #REF! 44 25
11 323 #N/A 606 2
12 56800 #REF! 830 12
14 2608 #REF! 1287 1
15 654022 #REF! 2532 1
16 5125 #N/A 2838 1
19 89541 #REF! 2877 33

So what I would like to see if Column A = Column F then I would like to put the value in from Column G

Thanks,

David
Related:

## 10 responses

dsrice Posts 2 Registration date Wednesday March 20, 2013 Status Member Last seen March 20, 2013
Mar 20, 2013 at 06:19 PM
So it did not keep the formatting, if you have any questions let me know.
Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 69
Mar 20, 2013 at 09:03 PM
Hi David,

Use this formula in column C:

=IF(A1=F1,G1,"")

Use the Microsoft Excel's fill handle to fill the formula for the rest of the cells in the column.

Thanks & Regards
Zohaib R
#iworkfordell
Zohaib,

However the values in G are not in the same rows as A, so they don't match up.

Could you use this IF(A2=\$F\$:\$F,I don't know how to get this value correct,"") because the rows don't match or would it be easier to do a VLOOKUP?
Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 69
Mar 21, 2013 at 01:54 PM
Hi David,

Data you have posted is little confusing. A little clarification will be helpful here. I copied the data and treated the spaces as tabs and put it in an excel sheet. It appears as:

Column A: BID
Column B: Pictures
Column C: Errors
Column D: Percentage
Column E: BID
Column F: Errors
Column G: ?

There is no header for "Column G", "Column C: Errors" is all "#N/A" or "#REF!" as if there is some formula in Column C. It is a little difficult to work with this data. Kindly update the sample-file to the below mentioned location:

https://authentification.site

I will try to update the formulas in the sample sheet and will upload to a similar location which you could download later.

Please do write back to us.
Everything is right except Column E that is blank.

Thanks

David
Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 69
Mar 21, 2013 at 04:56 PM
Hi David,

Please put this formula in column C of your sheet and use excel's fill handle and drag till the last value of the column, check if it returns what you want:

=IF(ISNA(VLOOKUP(A2,\$F\$2:\$F\$1048575,1,FALSE)),"",F2)

Didn't find the answer you are looking for?

Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 69
Mar 22, 2013 at 01:27 PM
Hi David,

http://speedy.sh/N3XKr/Picture-errors.xlsx

Hope this helps.
Thank you for your help, it has been awesome!

David
Wait it does not look like it is populating the correct values into column C. For Example it should be 5 for errors for Bid 10.

Thanks,

David
Wouldn't the last part of the formula need to reference Column G?
Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 69
Mar 22, 2013 at 05:21 PM
Hi David,

http://speedy.sh/2aVjY/Picture-errors.xlsx

Thanks & Regards
Zohaib R
#iworkfordell
Zohaib,

That is perfect,

Thanks,

David
Zohaib R Posts 2368 Registration date Sunday September 23, 2012 Status Member Last seen December 13, 2018 69
Mar 22, 2013 at 07:09 PM
Hi David,

I am glad to know this finally worked for you. Please feel free to get back to us if you have any further queries.