Welcome to the Excel Forum

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed.

Please Register to Remove these Ads

Please Register to Remove these Ads



Reply
  #1  
Old 07-04-2009, 10:32 AM
prabodh1234 prabodh1234 is offline
Registered User
 
Join Date: 04 Jul 2009
Location: New Delhi
MS Office Version:Excel 2007
Posts: 10
prabodh1234 is becoming part of the community
Lookup in a table

Please Register to Remove these Ads

I have a table of this format:
d e f
a 1 2 3
b 4 5 6
c 7 8 9

Now i want to find the column title for a particular value in the table. For ex, corresponding to row 'b' and value '5', how to get 'e'?? I am a beginner. Please help.

TIA

Last edited by prabodh1234; 07-06-2009 at 03:52 AM.
Reply With Quote
  #2  
Old 07-04-2009, 11:53 AM
windknife windknife is offline
Valued Forum Contributor
 
Join Date: 14 Apr 2009
Location: Taiwan
MS Office Version:Excel 2003
Posts: 234
windknife has an addiction to Excel
Re: Lookup in a table

how about ?

=INDEX(A1:D1,1,SUM(TRANSPOSE((A2:D4=5))*ROW(1:4)))

Committed with Ctrl+Shift+Enter

HTH,
windknife
Reply With Quote
  #3  
Old 07-04-2009, 12:11 PM
Ancalagon12321 Ancalagon12321 is offline
Registered User
 
Join Date: 03 Jul 2009
Location: London, England
MS Office Version:Excel 2003
Posts: 17
Ancalagon12321 is becoming part of the community
Re: Lookup in a table

I will assume that your 'd', 'e' and 'f' are in cells B1, C1 and D1, and that 'a', 'b' and 'c' are in A2, A3 and A4.

Then to get the name the header corresponding to the 5 in row "b" you need to write:

=INDEX(B1:D1, 1, MATCH(5, OFFSET(B1:D1, MATCH("b", A2:A4, 0), 0), 0))

Alternatively, if you need to find the name of the header above the number 5 without knowing which row it's in, and are sure that there is only one number 5 in the table, then use windknife's method.
Reply With Quote
  #4  
Old 07-05-2009, 11:24 AM
prabodh1234 prabodh1234 is offline
Registered User
 
Join Date: 04 Jul 2009
Location: New Delhi
MS Office Version:Excel 2007
Posts: 10
prabodh1234 is becoming part of the community
Re: Lookup in a table

Thanks guys...yes it worked
Reply With Quote


Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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

Forum Jump