#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,670
Default Lookup

Formula
Jan Feb Mar Result
Part A 1 - - Jan
Part B - 1 - Feb
Part C - - 1 Mar

I need to write a formula that will return the last month a part was sold
over a three year period. In the table above the formula would return "Feb"
for part B. I can't do a nested if because I have to search through 36
columns.

Any thoughts are greatly appreciated.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Lookup

One way which might suffice ..

Assuming source table as posted is in Sheet1,
with the "month" labels (Jan, Feb,...) in B1 across,
part labels in A2 down

In another sheet,
with the same part labels listed in A2 down

Place in B2, then array-enter the formula
by pressing CTRL+SHIFT+ENTER (instead of just pressing ENTER):
=INDEX(Sheet1!$1:$1,MATCH(TRUE,ISNUMBER(Sheet1!2:2 ),0))
B2 will return the result "Jan". Copy down as far as required.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Eric" wrote:
Formula
Jan Feb Mar Result
Part A 1 - - Jan
Part B - 1 - Feb
Part C - - 1 Mar

I need to write a formula that will return the last month a part was sold
over a three year period. In the table above the formula would return "Feb"
for part B. I can't do a nested if because I have to search through 36
columns.

Any thoughts are greatly appreciated.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,670
Default Lookup

Sorry Max, I believe I over simplified the example. There will be multiple
results for each part accross 36 columns. I need to return the month from
the last instance. i.e. If the last part sold occured in Nov 2006, I need
the formula to return "Nov 2006", but there may be sales before this date.

Thanks again,
Eric

"Max" wrote:

One way which might suffice ..

Assuming source table as posted is in Sheet1,
with the "month" labels (Jan, Feb,...) in B1 across,
part labels in A2 down

In another sheet,
with the same part labels listed in A2 down

Place in B2, then array-enter the formula
by pressing CTRL+SHIFT+ENTER (instead of just pressing ENTER):
=INDEX(Sheet1!$1:$1,MATCH(TRUE,ISNUMBER(Sheet1!2:2 ),0))
B2 will return the result "Jan". Copy down as far as required.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Eric" wrote:
Formula
Jan Feb Mar Result
Part A 1 - - Jan
Part B - 1 - Feb
Part C - - 1 Mar

I need to write a formula that will return the last month a part was sold
over a three year period. In the table above the formula would return "Feb"
for part B. I can't do a nested if because I have to search through 36
columns.

Any thoughts are greatly appreciated.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Lookup

I'm out. Suggest you put in a new posting if no one else responds here.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Eric" wrote:
Sorry Max, I believe I over simplified the example. There will be multiple
results for each part accross 36 columns. I need to return the month from
the last instance. i.e. If the last part sold occured in Nov 2006, I need
the formula to return "Nov 2006", but there may be sales before this date.

Thanks again,
Eric

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
Join 2 Lists - Lookup value in 1 list & use result in 2nd lookup JBush Excel Worksheet Functions 3 January 3rd 07 11:14 PM
Sumproduct - Condition based on lookup of a Lookup Hari Excel Discussion (Misc queries) 12 May 31st 06 09:28 AM
Advanced Lookup (lookup for 2 values) 0-0 Wai Wai ^-^ Excel Worksheet Functions 2 March 30th 06 07:09 PM
Pivot table doing a lookup without using the lookup function? NGASGELI Excel Discussion (Misc queries) 0 August 2nd 05 05:08 AM
How do I lookup and return different values when the lookup value. kg Excel Discussion (Misc queries) 1 January 20th 05 12:53 AM


All times are GMT +1. The time now is 11:39 AM.

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

About Us

"It's about Microsoft Excel"