Extracting data that meets certain criteria from the lookup table

SharmaAntriksh

New Member
Joined
Nov 8, 2017
Messages
31
[TABLE="width: 600"]
<tbody>[TR]
[TD]Employee Name[/TD]
[TD]Client Name[/TD]
[TD]Assigned on[/TD]
[TD]Due Date[/TD]
[TD]Actual Delivered Date[/TD]
[/TR]
[TR]
[TD]Antriksh Sharma[/TD]
[TD]xyz[/TD]
[TD]7/2/2018[/TD]
[TD]7/4/2018[/TD]
[TD]7/5/2018[/TD]
[/TR]
[TR]
[TD]Monique[/TD]
[TD]abc[/TD]
[TD]6/7/2018[/TD]
[TD]6/22/2018[/TD]
[TD]6/19/2018[/TD]
[/TR]
[TR]
[TD]Antriksh Sharma[/TD]
[TD]edf[/TD]
[TD]6/3/2018[/TD]
[TD]6/5/2018[/TD]
[TD]6/5/2018[/TD]
[/TR]
[TR]
[TD]Monique[/TD]
[TD]mnb[/TD]
[TD]5/3/2018[/TD]
[TD]5/20/2018[/TD]
[TD]5/21/2018[/TD]
[/TR]
</tbody>[/TABLE]

I have as huge database that looks similar to the above table, and i have a lookup table where i have the client names, i am trying to create VBA code which can help me in quickly extracting data from the above table if it matches my lookup table, i tried "For Each" loop but that evaluates again and again and is really slow, can you help me with some thoughts or code on how to make this process efficient?
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Can you post a screen shot of what your lookup table looks like? Section B at this link has instructions on how to post a screen shot: https://www.mrexcel.com/forum/board-announcements/127080-guidelines-forum-use.html Alternately, you could upload a copy of your file to a free site such as www.box.com. or www.dropbox.com. Once you do that, mark it for 'Sharing' and you will be given a link to the file that you can post here. Include a detailed explanation of what you would like to do referring to specific cells and worksheets. If the workbook contains confidential information, you could replace it with generic data.
 
Upvote 0
Lookup table will only contain the unique client names only and those name are amongst the ones listed in the above table, i can't share the file due HIPPA and PHI regulation.
 
Upvote 0
Without knowing what your lookup table looks like, it will be very hard to help you. When you say
extracting data from the above table if it matches my lookup table
we don't know how it should match, what data to extract and where to place the extracted data. Can you manually create a mockup workbook with generic data that would reflect what your sheets look like?
 
Upvote 0
[TABLE="width: 500"]
<tbody>[TR]
[TD]Client Name[/TD]
[/TR]
[TR]
[TD]xyz[/TD]
[/TR]
[TR]
[TD]abc[/TD]
[/TR]
</tbody>[/TABLE]

The lookup table looks like this and i would need extract the whole row of data from my Data/Fact table, i hope this helps.
 
Upvote 0
Hello, it sounds like you are confusing the terminology and calling your list of names the lookup table and from what you have described I believe those are your lookup values and your "huge database" is actually your lookup table.

You mention you tried a loop in VBA, do you care to share what you have done - that may help everyone help you.


Also, have you tried an Advance Filter? That will do what you want quickly, or you can use that in your code versus the loop method.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,827
Messages
6,181,199
Members
453,022
Latest member
RobertV1609

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top