+ Reply to Thread
Results 1 to 21 of 21

Summarise data from multiple task types to single task types

  1. #1
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Summarise data from multiple task types to single task types

    Attached is an example of a raw data report which produces data on time spent on various tasks each week by a group or people.

    The report is produced each month - so there are 4 weeks of data represented on each report for each person.

    There are standard tasks, which may appear on the report 4 times (once for each week), and there are general tasks which may appear one or more times in a given week, for one or more people, or not at all for anyone.
    New tasks may also get added during a period.

    Each task also shows the amount of time spent on it.

    What I need is to consolidate all this data into a summary report which will show for each person:

    - each task type they were involved with - but only ONCE i.e. 4 x "Administration" showing only as 1 x "Administration"

    - show only the TOTAL amount of time associated with the multiple instances of that same task e.g. total of all "Administration" (Admin x 4 hrs plus Admin x 7 hrs, plus etc)

    The sample sheet attached shows the original raw data report sheet, and a simplified (summary) report sheet reflecting what it should look like (i.e. with only unique entries per person along with their accumulated totals for each), once it has been processed.

    I normally have a shot at this myself but with this one I have no idea even how to approach it let alone start it. All help appreciated.
    Attached Files Attached Files

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,601

    Re: Summarise data from multiple task types to single task types

    Not looked at the workbook but what you describe sounds like a Pivot Table would be perfect.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Summarise data from multiple task types to single task types

    Thanks TMS. Have played with the pivot table solution and to be frank, it is useless for this exercise. As a one off it could be ok but the process is protracted, is unreliable, not automated, and doesn't allow additional data to be added without having to rerun the entire convoluted process to have it included. Have searched on the web for solution to the inclusion of additional data problem but all seem to agree it is like I have said. Would be good if VBA could extract this data better to allow for much easier management.

  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,601

    Re: Summarise data from multiple task types to single task types

    Are you still using Excel 2010?

  5. #5
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Cool Re: Summarise data from multiple task types to single task types

    with Pivot or Power Query (XL2010/2013 require PQ add-in)

  6. #6
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: Summarise data from multiple task types to single task types

    Hello Rabbitoh.
    I show you a way to do it with VBA:

    Please Login or Register  to view this content.
    Attached Files Attached Files
    You are always very welcome if you add reputation by clicking the * (bottom left) of each message that has helped you.

  7. #7
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Summarise data from multiple task types to single task types

    Hi, I have been playing with this as time has permitted and of course it work brilliantly. As my source column has changed from Column B (Name) to Column F (Task), which entries in the code do I need to change so it references F instead of B please. All other remain as before.

  8. #8
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: Summarise data from multiple task types to single task types

    Hello.
    As always: let's avoid misinterpretations. In other words: prepare and upload to the forum a workbook that contains a small sample of your data as it originally is and your data as you want it to be, okay?...

  9. #9
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Summarise data from multiple task types to single task types

    Thanks. I now have included how I want it to be. New Sample file posted with the desired outcome as you request. Yes, I see now that it is more that a simple change of a column reference.
    On the attached, there are two sheets, one the raw data and the other my desired outcome. The references are to columns E (Group) and column H (Time Spent). thanks again for doing this.
    Attached Files Attached Files

  10. #10
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Question Re: Summarise data from multiple task types to single task types


    Hi,

    according to your last attachment do the source cells color formatting must be copied to the result worksheet (slower)
    or this result worksheet can be without any color (easier & faster) ?

  11. #11
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: Summarise data from multiple task types to single task types

    Hello, Rabbitoh. The truth is that there is a gigantic difference between your first need and this second need:

    a) If what you want is to obtain what we see in the sheet 'SIMPLIFIED SUMMARY REPORT', then a mere dynamic table solves the problem (without macros to achieve it).

    b) But if you hope to get more information, you need to upload a new workbook to the Forum where we can clearly see what you want to summarize.

  12. #12
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Arrow Re: Summarise data from multiple task types to single task types


    Post #9 attachment as it is seems enough on my side, just my post #10 requires an answer …

  13. #13
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,288

    Re: Summarise data from multiple task types to single task types

    Please Login or Register  to view this content.
    Last edited by sintek; 03-25-2023 at 12:26 PM.
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  14. #14
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Summarise data from multiple task types to single task types

    no colour. needed i was just highlighting the affected columns to emphasise. bad idea huh
    And, it doesn't matter what residual data appears in columns a, b, c, d, f or g. As long as i can get the data in e and h.
    Last edited by Rabbitoh; 03-25-2023 at 06:44 PM.

  15. #15
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Re: Summarise data from multiple task types to single task types


    Does sintek's proposal is what you are expecting for ?

  16. #16
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: Summarise data from multiple task types to single task types

    Quote Originally Posted by Rabbitoh View Post
    And, it doesn't matter what residual data appears in columns a, b, c, d, f or g. As long as i can get the data in e and h.
    That's the answer I was waiting for...
    The VBA code is simple:

    PHP Code: 
    Sub Macro9()
    With Sheets("Raw Data")
      
    ActiveSheet.PivotTables(1).SourceData _
        
    .Range("A2", .Cells(Rows.Count"H").End(xlUp)).Address(, , xlR1C1True)
    End With
    End Sub 
    Attached Files Attached Files
    Last edited by beyond Excel; 03-25-2023 at 09:22 PM.

  17. #17
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Summarise data from multiple task types to single task types

    Thanks heaps sintek. Your code is easy and produces the correct result repeatedly following changes to the source data. I don't have to modify anything for each run or do anything different. It copy-pastes into my project workbook as is and works straight off.

  18. #18
    Registered User
    Join Date
    07-24-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    97

    Re: Summarise data from multiple task types to single task types

    beyond Excel your sample sheet produces exactly the result I want, and nice table presentation as well. Attempting to run it again after changes to the source data though doesn't update the output result and I can't seem to clear the entries in order to reset it. If I paste the code, "Option Explicit" included, into a module in my project workbook it errors out "Unable to get the PivotTables property of the worksheet class". There may be a simply reason for this or I need to reset something each time I want to use it, but I don't know what that is. I still use the first code you provided me from the initial posting and that is of course brilliant work. Thanks so much for your input.

  19. #19
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: Summarise data from multiple task types to single task types

    Quote Originally Posted by Rabbitoh View Post
    ... There may be a simply reason for this or I need to reset something each time I want to use it, but I don't know what that is.
    It is -almost- certain that what you have not copied to your own workbook is the pivot table: did you do it?...

  20. #20
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,288

    Re: Summarise data from multiple task types to single task types

    Quote Originally Posted by Rabbitoh View Post
    Thanks heaps sintek.
    Glad to have assisted...Tx for rep +

  21. #21
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: Summarise data from multiple task types to single task types

    Quote Originally Posted by Rabbitoh View Post
    beyond Excel your sample sheet produces exactly the result I want, and nice table presentation as well.
    OK, thanks for the +Rep and we're seeing each other.

+ 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. Does Excel VBA suppoprt the use of variant record types (not variant data types)
    By tfurnivall in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-25-2022, 12:10 PM
  2. Gantt chart with multiple time frame on single task
    By coxtel in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 03-03-2020, 04:40 AM
  3. Issues attaching multiple documents types to a single cell
    By dawwgsfan55 in forum Excel - New Users/Basics
    Replies: 3
    Last Post: 12-30-2019, 03:00 AM
  4. Multiple data validation types
    By Bieke1111 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 08-29-2014, 12:12 PM
  5. Multiple data validation types
    By Bieke1111 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-26-2014, 12:31 PM
  6. Replies: 4
    Last Post: 02-22-2013, 02:35 AM
  7. Find Single Name Among Multiple Task Owners
    By mycon73 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 06-20-2011, 03:31 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