+ Reply to Thread
Results 1 to 6 of 6

Getting Top 3 based on Date Range

  1. #1
    Registered User
    Join Date
    04-02-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    97

    Getting Top 3 based on Date Range

    Please see attached.

    Tab - Error Report Data contains all detail

    Tab - Top 3 for each Month Last 12 contains the summary data, top 3 and chart

    What I am trying to achieve is the Top 3 for each of the month ranges for the last 12 months. A37:A38 (Tab "Top 3") is the formulated Month Range, Column B are the Months/YY for Charting and Column C are the Top 3 Defects from (Tab "Error Report.." Column I) and Column D are the top 3 % from (Tab "Error report.." Column N)

    The Top 3 columns, if the Dates from Column A (Tab : Error Report) are in between the range of Dates Column A (Tab: "Top 3") Then give me the Top 3 Defects and Its %

    The Difficult thing is that the values on (Tab: Error Report) are duplicated and Columns L:N are Summarized from Column I:J

    Actual Expected Results are on (Tab: Top 3). There are months where there are no data but needs to be calculated as eventually there may be data. Result would be 0 or N/A etc.

    Thanks so much.

    testv11.xlsx

  2. #2
    Forum Contributor
    Join Date
    06-21-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    191

    Re: Getting Top 3 based on Date Range

    This was fun. Note that all three are array formulas and should be entered with Control+Shift+Enter.

    For D36:
    =LARGE(IF($A$37<='Error Report Data'!$A$2:$A$390,IF($A$38>='Error Report Data'!$A$2:$A$390,'Error Report Data'!$N$2:$N$390)),1)

    D37, then copy D37 and paste into D38:
    =LARGE(IF($A$37<='Error Report Data'!$A$2:$A$390,IF($A$38>='Error Report Data'!$A$2:$A$390,IF('Error Report Data'!$N$2:$N$390<D36,'Error Report Data'!$N$2:$N$390))),1)

  3. #3
    Registered User
    Join Date
    04-02-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Getting Top 3 based on Date Range

    "This was fun" Made me laugh, Thanks so much, It works great. Do you know of a way to auto populate the C columns the Defect Codes that goes with the %?

  4. #4
    Forum Contributor
    Join Date
    06-21-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    191

    Re: Getting Top 3 based on Date Range

    in C36, also an array formula (Ctrl+Shift+Enter):
    =INDEX('Error Report Data'!$A$2:$N$390,MATCH(D36&1&1,'Error Report Data'!$N$2:$N$390&IF($A$37<='Error Report Data'!$A$2:$A$390,1)&IF($A$38>='Error Report Data'!$A$2:$A$390,1),0),9)

    Verify that it returns the right values. Not sure what it should return, really. If you look at 3rd place, with 66.7%, there are multiple Def Codes in I (the column the formula returns), and it simply snatches the first one - which isn't the result you previously had in there.

  5. #5
    Registered User
    Join Date
    04-02-2013
    Location
    Canada
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Getting Top 3 based on Date Range

    Outstanding response time! thank you so much for your time. Much Appreciated

  6. #6
    Forum Contributor
    Join Date
    06-21-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    191

    Re: Getting Top 3 based on Date Range

    Glad to be of service.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Highlight Rows Based on Date Range Using Static Date and Current Date
    By SaraStravers in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 03-23-2015, 07:38 PM
  2. Replies: 5
    Last Post: 01-05-2015, 03:57 PM
  3. VBA to enter date range based on date range in above cell
    By Pierce Quality in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-19-2013, 08:45 AM
  4. [SOLVED] find missing date on every group date list based on range and criteria
    By k1dr0ck in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-25-2013, 01:26 AM
  5. copy date based on date -refer to date range
    By mindpeace in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-03-2006, 08:35 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1