Jump to content

How to perform a LOOKUP when dependent on 2 values?


David Jacobs
 Share

This topic is 5785 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

I have a database of paint colors that I purchase. Each color has 3 purchase costs depending on the size of container I buy. For Example, my code for containers is K3, DM, and TT. An example price for Green is $5.97, $5.28, and $4.85 (for K3, DM, TT purchases). For Blue, I have $5.86, $5.23, and $4.75. I have a master table of colors (rows) and prices (columns). What I want is when my purchasing agent enters the color (from a dropdown list) and the container type (K3, DM or TT), I want a field to return me the correct purchase price. I am confused on how to define the unit price. I know I need to tell it to look up the color and then look in the proper container-type column, but it seems I need to have a double look-up function. Can I inbed a lookup within another lookup function?

Link to comment
Share on other sites

You can't do a look up based on two values...but you can combine two values into one.

Create a text calc field in each of your two tables (Invoice and Prices) named PriceLookup = Size & " " & Color.

Relatet the two tables by PriceLookup and you'll have the structure you need to build your lookup.

BTW, this is the wrong subcategory for this question.

Link to comment
Share on other sites

This topic is 5785 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.