+ Reply to Thread
Results 1 to 8 of 8

Indexing and summing table results even when rows get deleted

  1. #1
    Registered User
    Join Date
    09-22-2009
    Location
    Mumbai India
    MS-Off Ver
    Excel 2007 & 2010
    Posts
    77

    Question Indexing and summing table results even when rows get deleted

    Hi all. I have an internal survey that each department uses differently and this means of some 365 questions, irrelevant ones per department are deleted from the list and this messes up the lookup function. I have to make the formulas dynamic by counting what is left and identifying the category so I can calculate the score.

    Each question has 5 answers. If there are 10 questions for one category that means the maximum score possible is 50. If the answers to that category equals 24 I can calculate the score as =(24/50) or 48% for the category.

    If two questions (two rows) are removed, I need to be able to read the remaining category questions and sum the totals automatically, now with a total possible score of 40.

    I was using VLOOKUP as I am not very good with index and match functions though this has fallen apart and gets very messy over 3 lookup functions in one cell. I would value any input as the solution will save me building a separate survey for each department. This way whatever a department leaves in, we can get a score dynamically weighted.
    Attached Files Attached Files

  2. #2
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Indexing and summing table results even when rows get deleted

    try this.....

    In E2
    Please Login or Register  to view this content.
    and copy down.

    Does this help?
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  3. #3
    Registered User
    Join Date
    09-22-2009
    Location
    Mumbai India
    MS-Off Ver
    Excel 2007 & 2010
    Posts
    77

    Re: Indexing and summing table results even when rows get deleted

    Solved in one line! Thank you so very much!!

  4. #4
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Indexing and summing table results even when rows get deleted

    You're welcome. Thanks for the feedback and rep.
    If that takes care of your question, please mark your thread as Solved by selecting Thread Tools (just above your first post) --> Mark thread as solved.

  5. #5
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Indexing and summing table results even when rows get deleted

    Quote Originally Posted by sktneer View Post
    try this.....

    In E2
    =IF(A2=A1,"",SUMPRODUCT(--($A$2:$A$200=A2),$C$2:$C$200)/SUMPRODUCT(--($A$2:$A$200=A2),$D$2:$D$200))
    Looks like SUMIF can be used.

    =IF(A2=A1,"",SUMIF(A$2:A$200,A2,C$2:C$200)/SUMIF(A$2:A$200,A2,D$2:D$200))
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  6. #6
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Indexing and summing table results even when rows get deleted

    Quote Originally Posted by Tony Valko View Post
    Looks like SUMIF can be used.

    =IF(A2=A1,"",SUMIF(A$2:A$200,A2,C$2:C$200)/SUMIF(A$2:A$200,A2,D$2:D$200))
    I agree but I like Sumproduct very much even Sumif is faster than Sumproduct, it may be the case of individual liking unless it is not affecting the sheet performance.

  7. #7
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Indexing and summing table results even when rows get deleted

    I prefer to use the most efficient means to arrive at the result.

    As an added bonus, there's also less typing to do when using SUMIF!

  8. #8
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Indexing and summing table results even when rows get deleted

    @Tony Valko
    That's why, you are Excel Guru.

+ 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. Only Summing Rows in a Table which Contain Sufficient Data
    By JSmith9201 in forum Excel General
    Replies: 3
    Last Post: 06-24-2014, 05:45 PM
  2. Replies: 1
    Last Post: 02-17-2013, 10:57 AM
  3. Summing specific non-zero rows in a table
    By coldcanuck in forum Excel General
    Replies: 7
    Last Post: 08-03-2011, 11:34 PM
  4. Replies: 8
    Last Post: 02-27-2009, 07:38 AM
  5. Indexing/Matching True/False results
    By drvortex in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-28-2005, 09:09 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