Obtaining information from a database for a worksheet

  • Thread starter Michelle Dean via OfficeKB.com
  • Start date
M

Michelle Dean via OfficeKB.com

I have a seperate datebase set up. What I need to do is ... in a seperate
worksheet obtain information for a certain cell and the row that corralates
to be able to feed into a seperate worksheet.


Example:

From Database

Need information that corrolates with column A Row 2 which would be a
registration number. I need the information from ColumnB row 2 (last Name),
Column C row 2 (first name), ColumnG Row 2, (street address) Column H row 2
(city), Colum I row 2 ( State), Column J row 2 (zip Code) , to be
automatically linked to another file so that we do not have to do a copy
paste. I do know of Vlookup but dosen't that only work for picking up info
in the column left of the one you are looking for.

Thanks,
Michelle
 
M

Michelle Dean via OfficeKB.com

Okay - if I understand this correctly - I can only get the value of the cell
at the right. I am needing the other cells information. Can you help w/ the
formula. I am not really following the index or match.

Database
EX.
Column Column Column Column Column
A B C D E
USAS # Last Name First Name Street Address City
34 Garcia Nicholas Marylou 1500 Oak Drive Lake Clarke
394 Suswal Tom PO Box 2372 Acworth
718 Barnhart Shane 523 Lee Road 412 Phenix City
749 Gray Hank 7031 Bill St Ft Benning
848 Litz Stephanie 5958 Dearborn Ave. Columbus


Seperate file Worksheet
Column
A B C D E
Last First USAS # Address City


I am needing all the information corlated with the USAS# to automatically
update. Again, can you please help me with a formula for that? What would
be for formula for column a, column b, column D and column e for the seperate
file worksheet?

Michelle
 
F

Fred

Michelle,

Sort your database file by USAS# then

In A1 (lookup Last Name) =VLOOKUP(C1,Database!$A$2:$E$999,2,False)
In B1 (lookup First Name) =VLOOKUP(C1,Database!$A$2:$E$999,3,False)
In D1 (lookup Address) =VLOOKUP(C1,Database!$A$2:$E$999,4,False)
In E1 (lookup City) =VLOOKUP(C1,Database!$A$2:$E$999,5,False)

where 'Database!$A$2:$E$999' will be the range of cells that contains the
database values.

Copy down all rows in 'separate workfile' - job done. If USAS# is present
in database, values will be returned otherwise an error condition will be
returned.

HTH
 
M

Michelle Dean via OfficeKB.com

Thanks Fred

It worked for me. This will help a bunch!!!

Michelle
 

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