Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
KG
 
Posts: n/a
Default Using Multiple LOOKUP tables

I have never used multiple tables, so I am hoping that you can steer me in
the right direction:

I have a list of five possible Customer names & four product classes that
apply to all of them:
Premium Products
Economy Products
Seconds
Imports

Then there would be be five lookup tables with commission rates; Table1 will
apply to Customer A, Table2 to Customer B etc. All five commission tables
would be of the same design:

Premium Products, Economy Products, Seconds and Imports will be the row
labels. The column headings would read 2005, 2006, 2007, etc. and in the
intersects there will be commission rates in percent.

So, now I want to populate a table with commission payments by product and
by year, depending on the customer name to be entered in cell B2. If the
Customer name is "A", I would want want to go to Table1, if Customer "B" to
Table2, etc.

I presume that this would require the use of MATCH and VLOOKUP, but I am not
sure if there are other steps
  #2   Report Post  
Domenic
 
Posts: n/a
Default

First, define a name for each of your tables. For this example, we'll
name the first table CustomerA, the second table, CustomerB, etc. But
don't include the column and row headers in the reference. So, for
example, if Sheet2!A1:D5 contains your first table...

Insert Name Define

Name: CustomerA

Refers to: =Sheet2!$B$2:$D$5

Click Add, and continue with the remaining tables. Notice the column
and row headers are not included.

Secondly, set up a table with the column and row headings only, let's
say B4:E8, something like this...

Product Classes..........2005.....2006.....2007
Premium Products
Economy Products
Seconds
Imports

Then, select C5:E8 (these cells should be highlighted) and enter the
following formula...

=INDEX(INDIRECT(B2),0,0)

....confirmed with CONTROL+SHIFT+ENTER, not just ENTER, and where B2
contains the customer name, such as CustomerA.

Hope this helps!

In article ,
"KG" wrote:

I have never used multiple tables, so I am hoping that you can steer me in
the right direction:

I have a list of five possible Customer names & four product classes that
apply to all of them:
Premium Products
Economy Products
Seconds
Imports

Then there would be be five lookup tables with commission rates; Table1 will
apply to Customer A, Table2 to Customer B etc. All five commission tables
would be of the same design:

Premium Products, Economy Products, Seconds and Imports will be the row
labels. The column headings would read 2005, 2006, 2007, etc. and in the
intersects there will be commission rates in percent.

So, now I want to populate a table with commission payments by product and
by year, depending on the customer name to be entered in cell B2. If the
Customer name is "A", I would want want to go to Table1, if Customer "B" to
Table2, etc.

I presume that this would require the use of MATCH and VLOOKUP, but I am not
sure if there are other steps

  #3   Report Post  
Dave Peterson
 
Posts: n/a
Default

I think I would use 5 different worksheets.
Build each table on each worksheet.
Use insert|name define to name each of the tables (table1, table2, ..., table5).

Then I'd create a formula that tells me which table to use--maybe an embedded
=if() formula or even a =vlookup() formula.

=if(custname="aa","table1",if(custname="bb","table 2",...etc)

In my case, I stuck that in A1.
Then I put the class that I wanted in B1.
(or a formula that returned one of those classes???)
Then I put the year in C1.
(or a formula that returned one of the years????)

Then to return the value from that table, I used this formula:

=INDEX(INDIRECT(A1),MATCH(B1,INDEX(INDIRECT(A1),,1 ),0),
MATCH(C1,INDEX(INDIRECT(A1),1,),0))

(One cell).

The =indirect(a1) is the pointer to the correct table.
The =index(indirect(a1),,1) points at the first column in that table--the
classes.
The =index(indirect(a1),1,) points at the first row in that table--the years.

If you want a little instruction for =vlookup() and =index(match()), you can
turn to Debra Dalgleish's site:
http://www.contextures.com/xlFunctions02.html

=============
These tables can actually be on one sheet. But I've always had better luck with
updates when I put them in different sheets--it makes inserting/deleting
rows/columns much easier.

If you think that table will grow (more rows or columns), Debra also has some
instructions on how to create a dynamic range name at:
http://www.contextures.com/xlNames01.html#Dynamic


KG wrote:

I have never used multiple tables, so I am hoping that you can steer me in
the right direction:

I have a list of five possible Customer names & four product classes that
apply to all of them:
Premium Products
Economy Products
Seconds
Imports

Then there would be be five lookup tables with commission rates; Table1 will
apply to Customer A, Table2 to Customer B etc. All five commission tables
would be of the same design:

Premium Products, Economy Products, Seconds and Imports will be the row
labels. The column headings would read 2005, 2006, 2007, etc. and in the
intersects there will be commission rates in percent.

So, now I want to populate a table with commission payments by product and
by year, depending on the customer name to be entered in cell B2. If the
Customer name is "A", I would want want to go to Table1, if Customer "B" to
Table2, etc.

I presume that this would require the use of MATCH and VLOOKUP, but I am not
sure if there are other steps


--

Dave Peterson
  #4   Report Post  
KG
 
Posts: n/a
Default

Thank you both! I think I have enough to go on...

"Domenic" wrote:

First, define a name for each of your tables. For this example, we'll
name the first table CustomerA, the second table, CustomerB, etc. But
don't include the column and row headers in the reference. So, for
example, if Sheet2!A1:D5 contains your first table...

Insert Name Define

Name: CustomerA

Refers to: =Sheet2!$B$2:$D$5

Click Add, and continue with the remaining tables. Notice the column
and row headers are not included.

Secondly, set up a table with the column and row headings only, let's
say B4:E8, something like this...

Product Classes..........2005.....2006.....2007
Premium Products
Economy Products
Seconds
Imports

Then, select C5:E8 (these cells should be highlighted) and enter the
following formula...

=INDEX(INDIRECT(B2),0,0)

....confirmed with CONTROL+SHIFT+ENTER, not just ENTER, and where B2
contains the customer name, such as CustomerA.

Hope this helps!

In article ,
"KG" wrote:

I have never used multiple tables, so I am hoping that you can steer me in
the right direction:

I have a list of five possible Customer names & four product classes that
apply to all of them:
Premium Products
Economy Products
Seconds
Imports

Then there would be be five lookup tables with commission rates; Table1 will
apply to Customer A, Table2 to Customer B etc. All five commission tables
would be of the same design:

Premium Products, Economy Products, Seconds and Imports will be the row
labels. The column headings would read 2005, 2006, 2007, etc. and in the
intersects there will be commission rates in percent.

So, now I want to populate a table with commission payments by product and
by year, depending on the customer name to be entered in cell B2. If the
Customer name is "A", I would want want to go to Table1, if Customer "B" to
Table2, etc.

I presume that this would require the use of MATCH and VLOOKUP, but I am not
sure if there are other steps


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple lookup value's rucker31 Excel Worksheet Functions 0 March 11th 05 11:17 PM
lookup tables in cells Excel Worksheet Functions 5 February 28th 05 09:47 AM
Multiple Criteria Lookup Question Gregg Riemer Excel Discussion (Misc queries) 3 February 22nd 05 01:18 AM
Return Multiple Results with Lookup Josh O. Excel Worksheet Functions 1 February 4th 05 08:07 PM
lookup multiple occurrences of a value excel ckl Excel Worksheet Functions 5 February 3rd 05 05:19 AM


All times are GMT +1. The time now is 07:24 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"