+ Reply to Thread
Results 1 to 4 of 4

Pulling Data from worksheets in multiple workbooks to creat a pivot table.

  1. #1
    Registered User
    Join Date
    12-13-2011
    Location
    South Carolina
    MS-Off Ver
    Office 2007
    Posts
    16

    Pulling Data from worksheets in multiple workbooks to creat a pivot table.

    We have a trucking company that daily we input multiple driver's payroll. Part of the data we input is the miles driven, gallons of fuel purchased, and cost of that purchase for the driver for that day. We collect this information per driver per week and then name the workbook by the date of the week ending (i.e. 12-5-13) The last worksheet of that workbook is "mileage report" where I use a vlookup to store all the raw data of mileage, gallons, and cost. (see attachment "dataworkbook112-5-13.xlsx").
    At the end of the month we take the "mileage report" worksheet from each week's workbook. Copy all the data and paste it to a new workbook. One week under the other so the data of each header column lines up. Then I make a pivot table of the data and then add calculations to find the MPG and the cost per gallon. (see attachment "Mileage Recap.xlsx"). Each month I delete the raw data page and cut and paste all over again and then refresh the pivot table.
    I have read, googled, and youtubed till Im blue in the face. I want to be able to leave the mileage report worksheet in the original workbooks and have the pivot table go and pull the information to create the table.
    Just to note. The worksheet name, headers, column and rows are the constant. The only thing that changes from week to week is the data's workbook name. (12-5-13, 12-19-13, etc.)

    Thank you in advance for any help.
    Attached Files Attached Files

  2. #2
    Forum Expert Tinbendr's Avatar
    Join Date
    06-26-2012
    Location
    USA
    MS-Off Ver
    Office 2010
    Posts
    2,138

    Re: Pulling Data from worksheets in multiple workbooks to creat a pivot table.

    Have you tried Microsoft Query? It will pull in data from another workbook.

    Data->From Other Source->From Microsoft Query->Excel files...
    David
    (*) Reputation points appreciated.

  3. #3
    Registered User
    Join Date
    12-13-2011
    Location
    South Carolina
    MS-Off Ver
    Office 2007
    Posts
    16

    Re: Pulling Data from worksheets in multiple workbooks to creat a pivot table.

    It is a step in the right direction but its only giving me the first worksheet.

  4. #4
    Forum Expert Tinbendr's Avatar
    Join Date
    06-26-2012
    Location
    USA
    MS-Off Ver
    Office 2010
    Posts
    2,138

    Re: Pulling Data from worksheets in multiple workbooks to creat a pivot table.

    And can you not create another query underneath the first one. (And I'm just guessing at this point. I've only used query a time or two.)

    A macro could be written to pull the data in, but that will take a little time. (I'm already on two projects. )

    You might give Ron DeBruin's site a check to see if his merge page will fill your requirement.

+ 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. [SOLVED] pulling data from multiple workbooks
    By rlowe in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-07-2014, 06:18 PM
  2. Replies: 0
    Last Post: 06-14-2013, 07:05 AM
  3. Excel 2007 : Pivot table data from multiple worksheets
    By SueWithQuestion in forum Excel General
    Replies: 0
    Last Post: 10-10-2011, 07:45 AM
  4. Pulling data multiple workbooks
    By hwtcrl in forum Excel General
    Replies: 0
    Last Post: 08-21-2011, 09:29 PM
  5. pulling data from multiple workbooks
    By Leal72 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-11-2008, 03:40 PM

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