Solved

Excell Question

Posted on 1999-01-11
6
161 Views
Last Modified: 2011-04-14
I have 2 separate workbooks in Excell 97 format.
The first one has a list of values in the A Column.  For simplicity, let's say there are 50 different values.
In worksheet 2, I have a sub-list of about 10 values.  These 10 values can all be found in the first spreadsheet.

The small list are values that I need to delete out of the first list.  How can I compare these two lists, and find which values are present in both lists?  Is there a Union function or something that will do it?  
0
Comment
Question by:TISS
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 

Expert Comment

by:westone
ID: 1014959
One possible solution:
Run a macro w/ a nested loop that compares each value in the big list to each value in the small list. When a match is found, the current cell in the big list ="", then exit the exit the nested loop and proceed to the next value in the big list.
0
 

Author Comment

by:TISS
ID: 1014960
That's one solution I thought of too, but I counldn't figure out how to code a macro to look at the value in another workbook.  
If it were too lists on the same workbook sheet, I'd be fine.

Any ideas on this?  
0
 
LVL 3

Expert Comment

by:rosefire
ID: 1014961
Can you use the DGET() database function to extract the fields that match?  Check Excel help on this function.  DGET() extracts the single values that match fields with a pattern you name.  Really, what you want to do amounts to database manipulation and excel is not the best tool, but it sounds like you may be stuck with it.

RoseFire
0
SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

 
LVL 3

Expert Comment

by:rosefire
ID: 1014962
If you want to do this only once, you can cut and paste the small database into the larger sheet too.  This will be messy if you are trying to automate this process, however.

RoseFire
0
 

Accepted Solution

by:
Urandrial earned 40 total points
ID: 1014963
Here's what i do as a one off.

1.  In coumn B say of the small list enter a -1
2.  In column B of the large list enter a 1
3.  Copy small list to bottom of large list
4.  Highlight columns A and B.  Select Data...Sort..Column A...ascending
5.  In column C row 2 enter '=B1+B2'
6.  Drag the bottom right corner of this cell to the bottom of the combined list (thus      copying the formula for all othe other cells.
7.  Copy column C..paste special...values into column D
8.  Delete data from column C
9.  Highlight columns A and D.  Select Data...Sort...Column D...Ascending.
10.  Delete all rows with a value of 0.

This will delete all of the values in the large list that where contained in the short list.

I hope this helps.

Urandrial.
0
 

Author Comment

by:TISS
ID: 1014964
Thanks.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In this article you will get to know about pros and cons of storage drives HDD, SSD and SSHD.
This paper addresses the security of Sennheiser DECT Contact Center and Office (CC&O) headsets. It describes the DECT security chain comprised of “Pairing”, “Per Call Authentication” and “Encryption”, which are all part of the standard DECT protocol.
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question