+ Reply to Thread
Results 1 to 5 of 5

Add columns within monthly date ranges

  1. #1
    Registered User
    Join Date
    09-17-2012
    Location
    South Wales, UK
    MS-Off Ver
    Excel 2003
    Posts
    51

    Add columns within monthly date ranges

    Hi guys,

    I would very much appreciate some help with adding up columns relating to a specific month range.

    My spread sheet lists dates in column A and a number of columns, say 6, with numerical data (see example attached).

    I want to be able to select on another sheet the month and add up the data and display it on one row of 6 columns.

    (I realise I can just select the cells, but I want to copy across a date formula to many other spreadsheets, and I don't want to have to worry about the month length (30th/31st)

    Many thanks,
    David.
    Attached Files Attached Files
    Last edited by essee; 11-01-2012 at 10:35 AM.

  2. #2
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: Add columns within monthly date ranges

    hi David, could you standardise the way months are input in "Summary". i would suggest it in a proper date format like 1-Aug-2012. you can then format cells to show as Aug-12 by Custom format "mmm-yy". but if you want just the text, maybe standardise it as 3 letters or full text. for 3 letters, you can use:
    =SUMPRODUCT((TEXT(Data!$A$2:$A$92,"mmm")=$A2)*(Data!B$2:B$92))

    for full spelling of months, try:
    =SUMPRODUCT((TEXT(Data!$A$2:$A$92,"mmmm")=$A2)*(Data!B$2:B$92))

    the reason why i suggested a proper date format is because the above formulas wont recognise the years. this formula's for a proper date format:
    =SUMPRODUCT((TEXT(Data!$A$2:$A$92,"mmm-yy")=TEXT($A2,"Mmm-yy"))*(Data!B$2:B$92))

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

  3. #3
    Registered User
    Join Date
    09-17-2012
    Location
    South Wales, UK
    MS-Off Ver
    Excel 2003
    Posts
    51

    Re: Add columns within monthly date ranges

    Hello again!

    Hmm.. the date format on the Summary sheet is not too important, so your suggestions are fine, but I can't seem to get this working.

    Are you adding up the dates?

  4. #4
    Registered User
    Join Date
    09-17-2012
    Location
    South Wales, UK
    MS-Off Ver
    Excel 2003
    Posts
    51

    Re: Add columns within monthly date ranges

    Actually, ignore this. I've gone a different way now! Thanks for you time and help again, benishiryo, but I may return to this at a different date.

    Do I mark this as resolved or just delete it or anything? Thanks.

  5. #5
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: Add columns within monthly date ranges

    always glad to help. i was actually saying you should change to either of the 3 for it to work. but if you insist on it, at least 3 of the 1st letters would work too for this formula:
    =SUMPRODUCT((TEXT(Data!$A$2:$A$92,"mmm")=LEFT($A3,3))*(Data!B$2:B$92))

    do mark this resolved if there are no further questions on this scenario. thanks

+ 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