#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Compare two lists

I have two lists list1 and list2

List 1 List 2
a b
b d
c e
d
e

Is there a way I can get the items in List2 that already exist in List 1
(b,d,e). It looks simple for the lists above but when I have lists with 100
or so items, it is not so easy.

thinking about it, will a vlookup do the job?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default Compare two lists

One way:

Assuming your lists are in columns A and B. Enter this formula in column C
and copy down to the end of the list in column B:

=IF(ISNUMBER(MATCH(B2,A$2:A$6,0)),"x","")

X = exists in column A

Biff

"ExcelInExcel" wrote in message
...
I have two lists list1 and list2

List 1 List 2
a b
b d
c e
d
e

Is there a way I can get the items in List2 that already exist in List 1
(b,d,e). It looks simple for the lists above but when I have lists with
100
or so items, it is not so easy.

thinking about it, will a vlookup do the job?



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 281
Default Compare two lists

Hi,

use a helper column in list 2 and enter this formula:
=VLOOKUP(list2!A1,list1!$A$1:$A$100,1,false)
copy drag down the formula to where ever you need

Thanks,
--
Farhad Hodjat


"ExcelInExcel" wrote:

I have two lists list1 and list2

List 1 List 2
a b
b d
c e
d
e

Is there a way I can get the items in List2 that already exist in List 1
(b,d,e). It looks simple for the lists above but when I have lists with 100
or so items, it is not so easy.

thinking about it, will a vlookup do the job?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
compare lists teejay Excel Worksheet Functions 6 September 20th 07 09:14 PM
Compare two lists Vicki Needs Help New Users to Excel 1 May 11th 07 03:46 AM
Compare Lists Lemmesee Excel Discussion (Misc queries) 5 January 9th 07 03:15 AM
Compare Two Lists steve_g Excel Worksheet Functions 1 June 12th 06 05:16 PM
compare two lists rob p Excel Worksheet Functions 3 October 10th 05 07:01 PM


All times are GMT +1. The time now is 09:15 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"