I need help with what I believe will be a nested lookup of some sort. Essentially I want to be able to match 2 existing criteria to a reference table of values and pull the corresponding heading for the value from that reference table. For example (cells delimited by commas):
TABLE 1 (my data)
-----------------------
NAME, SPECIALTY, SALARY, *WHAT I NEED*
Dr. smith, oncology, $200000, X1
Dr. jones, pediatrics, $100000, X2
REFERENCE TABLE (national data)
----------------------------------
SPECIALTY, 10th%, 25th%, 50th%,... etc
Oncology, $100000, $200000, etc, etc
Pediatrics, $50000, $75000, $100000, etc
The goal is to input a formula that references oncology and $200000 for Dr. Smith, goes to the reference table, and returns the corresponding % heading. In Dr. Smith's case the cell would display "25th%" and in Dr. Jone's case, "50th%."
I could be way off, but this is what I have so far:
INDEX(reference!$A$1:$C$3, MATCH(mydata!E5, reference!$A$2:$A$3, 0), MATCH(mydata!F5, reference!$A$1:$C$3, ????))))
This works if i hardcode the column number where ???? is. Problem is how do I get that to match my data, specialty, etc? I'm not a coder or an excel wiz, so I might be way off base. Help!!
TABLE 1 (my data)
-----------------------
NAME, SPECIALTY, SALARY, *WHAT I NEED*
Dr. smith, oncology, $200000, X1
Dr. jones, pediatrics, $100000, X2
REFERENCE TABLE (national data)
----------------------------------
SPECIALTY, 10th%, 25th%, 50th%,... etc
Oncology, $100000, $200000, etc, etc
Pediatrics, $50000, $75000, $100000, etc
The goal is to input a formula that references oncology and $200000 for Dr. Smith, goes to the reference table, and returns the corresponding % heading. In Dr. Smith's case the cell would display "25th%" and in Dr. Jone's case, "50th%."
I could be way off, but this is what I have so far:
INDEX(reference!$A$1:$C$3, MATCH(mydata!E5, reference!$A$2:$A$3, 0), MATCH(mydata!F5, reference!$A$1:$C$3, ????))))
This works if i hardcode the column number where ???? is. Problem is how do I get that to match my data, specialty, etc? I'm not a coder or an excel wiz, so I might be way off base. Help!!