+ Reply to Thread
Results 1 to 4 of 4

Help with sumif formula - year to date

  1. #1
    Registered User
    Join Date
    01-04-2013
    Location
    Seattle, WA
    MS-Off Ver
    Excel 2010
    Posts
    30

    Help with sumif formula - year to date

    I'm completely stuck on this one and hoping someone can help.

    I have 2 relevant columns with about 20,000 rows. The first column (A), has data formatted as
    FY(2 digit fiscal year) - P(one or two digit period) - W(1 digit week)
    Column B has values

    I current have no problem with sumif-ing the values for a given week, period, or year. What I need to do is sum for year to date. For instance, if I want year to date for FY13, P2, then I want all values in column B where column A contains either:
    FY13 - P1 - W* -- (* indicating any), or
    FY13 - P2 - W*
    Is there a way to put a less than or equal to in the lookup criteria within the text string?

    Beers to whomsoever can solve this (new job, want to impress!)

  2. #2
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: Help with sumif formula - year to date

    See if this helps:

    Sum for FY13, P2:
    =SUMIF(A2:A50,"fy13 - P2*",B2:B50)

    YTD sum through P2 for FY13
    =SUMIF(A2:A50,"<=fy13 - P2*",B2:B50)

    Is that something you can work with?
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  3. #3
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: Help with sumif formula - year to date

    Or with an pivot table.

    You don't add an excel file, so i can't show it to you.
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

  4. #4
    Registered User
    Join Date
    01-04-2013
    Location
    Seattle, WA
    MS-Off Ver
    Excel 2010
    Posts
    30

    Re: Help with sumif formula - year to date

    I wound up going with the pivot table simply because it allowed me more flexibility. Those active x buttons and macros are nice, but elegance is divine!

    Thank you both so much for your help!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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