Excel and Access linkage

G

Glyn

I have a problem .. i have some data in excel and other data in access.
This is related to hours people work for a customer project

Soi have a ms access database with a table called ACTUALS that has data
such as this:

LASTNAME SERIAL CUSTOMER DATE HOURS
----------------- ------------ --------------------
------------------------- ---------------
JONES 123345 ACME 1/26/2007 27
JONES 123345 ACME 1/19/2007 25
SMITH 654321 ACME 1/26/2007 12
SMITH 654321 AA INC 1/19/2007 22
etc

LASTNAME, SERIAL, CUSTOMER and DATE form a unique key.

I have an excel spreadsheet with this format:

A B C D
E
1 LASTNAME SERIAL COMPANY 1/19/2007 1/26/2007
2 JONES 123345 ACME
3 SMITH 654321 ACME
4 SMITH 654321 AA INC
....
x ENDOFLIST


I'd like to populate columns D and E with the data from the excel
spreadsheet for the corresponding date in row 1 ...

I kind of wish i could enter a query in each cell that is like this:

SELECT HOURS FROM ACTUALS WHERE (LASTNAME=$An AND SERIAL=$Bn and
COMPANY=$Cn AND DATE= m$1 )

n being the row number and m being the column letter.

Is this possible? Either through an external data source or through a
VBA macro?

thanks
Glyn
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top