Solved

Pull data based on a column in EXCEL 2007

Posted on 2011-09-28
3
214 Views
Last Modified: 2012-05-12
Hi all.

I want to create an EXCEL 2007 template that when the user pastes data into column A in the 3rd row it will pull data from tableA based on the contents of each field (left outer join from EXCEL column A to tableA on the ItemField).

I know how to create a data connection to my TableA but how do I tell it to be a left outer join on columnA. Also, sometimes the end user will paste 3 rows, other times 30, basically the amount of data that is pasted in the spreadsheet will vary.

Any ideas? Thank you in advance!
0
Comment
Question by:printmedia
  • 2
3 Comments
 
LVL 9

Expert Comment

by:experts1
ID: 36718573
Use VLOOKUP in another column, say column B for 30 rows or more if necessary and reference column A of the said row to compare data fromTableA.
0
 

Author Comment

by:printmedia
ID: 36718863
Hi experts1.

So when the end user opens the excel template they will paste their records in the first column under the column header in the 3rd row. Then they will press a command button that will VLOOKUP?

Can I use VLOOKUP in vba in order to tap into the SQL table?
0
 
LVL 9

Accepted Solution

by:
experts1 earned 500 total points
ID: 36719159
In "ThisWorkbook" VBA module use Workbook_SheetSelectionChange() subroutine to tap into the SQL table and generate an updated  DATA range in the workbook, for use as the range lookup source for VLOOKUP function.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

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

How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
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…

831 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