View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default I need a Formula for a Database

You could use the VLOOKUP function.

You would have a 2 column table with tracking codes and descriptions on another
sheet in A1:B100

In Sheet1 B1 enter this formula

=VLOOKUP(A1,Sheet2!$A$1:$B$100,2,FALSE)

Enter a tracking code in A1 of Sheet1

You could also use a Data Validation drop-down list in Sheet1 A1 for selecting
the tracking code.

Visit Debra Dalgleish's site for info on VLOOKUP function to pull data based on
value. Note the downloadable sample workbooks.

http://www.contextures.on.ca/xlFunctions02.html

Also see Debra's site for info on Data Validation selection lists for inputting
the data if need be.

http://www.contextures.on.ca/xlDataVal01.html


Gord Dibben MS Excel MVP

On Tue, 10 Jun 2008 10:56:03 -0700, JonWardellBuilders
wrote:

Here is what i need.

I have a list of of one hundred (or More) 4 digit tracking codes that have a
label (description) for each; for example 0234 is Hauling, 0142 is General
Labor etc. I think what i want is a Database so when i input my 4 digit
tracking code into cell 'A1', cell 'B1' will fill in the correct description
and i won't have to type it anymore.

I am guessing that i create a 'worksheet1' that has all the 4 digit tracking
codes in Column 'A' and all their descriptions in Column 'B'

On 'worksheet2' i would need a formula in the cells for Column 'B' that
basically says (i think) - If 'Worksheet1' cell in column 'A' equals the
tracking code entered in 'Worksheet2' cell 'A1' then insert 'worksheet1's
appropriate Column 'B' description into 'Worksheet1' cell 'B1'.

Please Help me!!!