Extracting data that meets certain criteria from the lookup table

SharmaAntriksh

New Member
Joined
Nov 8, 2017
Messages
31
Employee NameClient NameAssigned onDue DateActual Delivered Date
Antriksh Sharmaxyz7/2/20187/4/20187/5/2018
Moniqueabc6/7/20186/22/20186/19/2018
Antriksh Sharmaedf6/3/20186/5/20186/5/2018
Moniquemnb5/3/20185/20/20185/21/2018

<tbody>
</tbody>

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

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
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
Client Name
xyz
abc

<tbody>
</tbody>

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,215,465
Messages
6,124,980
Members
449,201
Latest member
Lunzwe73

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