+ Reply to Thread
Results 1 to 6 of 6

SUMIF worked great, but now data is on separate rows. Need alt. method.

  1. #1
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    SUMIF worked great, but now data is on separate rows. Need alt. method.

    I'm making a workbook in Excel 2003 that tracks store sales & profit (see pic below). I have daily reports where the employee enters all the data & then I have a "Monthly" tab that consolidates all the daily data into a monthly report.

    The monthly report uses this SUMIF formula to tabulate each category (Daily Sales, Daily Units, Daily Profit) for each line item:
    =SUMIF('Daily - Jan'!$7:$7,'Daily - Jan'!$F$7,'Daily - Jan'!23:23)

    This worked beautifully, until I realized that the line items will most likely change periodically mid-month, which will in turn mess-up my monthly SUMIF formulas because it expects the data to be all on one row.

    I've racked my brain trying to figure-out an alternative method to tabulate data on different rows and per each category, but have not been successful.

    Any thoughts?

    Many thanks.

    SUMIF Formula.jpg
    Last edited by Big.Moe; 02-12-2017 at 12:23 PM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,410

    Re: SUMIF worked great, but now data is on separate rows. Need alt. method.

    Will you please attach a sample Excel workbook? We are not able to work with or manipulate a picture of one.

    1. Make sure that your sample data are REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired solution is also shown (mock up the results manually).

    3. Make sure that all confidential data is removed or replaced with dummy data first (e.g. names, addresses, E-mails, etc.).

    4. Try to avoid using merged cells as they cause lots of problems.

    Unfortunately the attachment icon doesn't work at the moment, so to attach an Excel file you have to do the following: just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

    Please pay particular attention to point 2 (above): without an idea of your intended outcomes, it is often very difficult to offer appropriate advice.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Re: SUMIF worked great, but now data is on separate rows. Need alt. method.

    Here's a cut down version of the spreadsheet. Any ideas, even only half conceptualized is fine, or even any ideas on how to rework the structure of the workbook for this to work with changing line items is welcome. Thanks.
    Attached Files Attached Files

  4. #4
    Forum Contributor Big.Moe's Avatar
    Join Date
    03-15-2012
    Location
    Corea, Maine, USA
    MS-Off Ver
    Excel 2010
    Posts
    244

    Re: SUMIF worked great, but now data is on separate rows. Need alt. method.

    I think I found a very clunky solution and wondered if someone could suggest a more efficient formula. I came-up with the following formula to tabulate all the data across the "Daily Reports" that corresponds to each line item on the "Monthly Report":

    =INDEX('Daily - Jan'!F8:F50,MATCH(B21,'Daily - Jan'!B8:B50,0))+INDEX('Daily - Jan'!N8:N50,MATCH(B21,'Daily - Jan'!J8:J50,0))+INDEX('Daily - Jan'!V8:V50,MATCH(B21,'Daily - Jan'!R8:R50,0)).....

    Unfortunately, I will have to repeat the INDEX-MATCH calculation inside the formula ~30 times to cover each individual "Daily Report" for the month, but this will take in account the possibility that corresponding line items may be on different rows.

    Any suggestions for a simpler formula?

  5. #5
    Registered User
    Join Date
    02-25-2015
    Location
    Atlanta, GA
    MS-Off Ver
    2013
    Posts
    97

    Re: SUMIF worked great, but now data is on separate rows. Need alt. method.

    For what I use Excel for Pivot tables sums data nicely.

  6. #6
    Registered User
    Join Date
    02-25-2015
    Location
    Atlanta, GA
    MS-Off Ver
    2013
    Posts
    97

    Re: SUMIF worked great, but now data is on separate rows. Need alt. method.

    I use the insert function button to build a formulas for index match. https://docs.google.com/drawings/d/1...it?usp=sharing

+ 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. Replies: 0
    Last Post: 05-14-2012, 05:36 PM
  2. Replies: 1
    Last Post: 05-10-2012, 11:33 AM
  3. Replies: 3
    Last Post: 08-12-2010, 03:45 PM
  4. Convert rows with repeating data to separate rows
    By lancemonotone in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 03-28-2010, 05:27 PM
  5. Convert rows with repeating data to separate rows
    By lancemonotone in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 02-25-2010, 07:10 PM
  6. [SOLVED] Best Method to Remove Data Rows
    By Nigel in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 08-08-2006, 01:00 PM
  7. Best Method to Remove Data Rows
    By Nigel in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-08-2006, 10:35 AM
  8. Inserting rows:read a great deal
    By eddie in forum Excel General
    Replies: 1
    Last Post: 10-18-2005, 04:05 PM

Tags for this Thread

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