+ Reply to Thread
Results 1 to 4 of 4

building data model

  1. #1
    Registered User
    Join Date
    03-26-2014
    Location
    Rotterdam
    MS-Off Ver
    Excel 2010
    Posts
    16

    building data model

    Dear all,

    I am seeking for some support on how to load raw data into a new structured workbook. I've attached two sample files for your convenience (Commerce hub export is the input file and the data model template is the output file), and basically what I want to achieve is threefold.

    1. Loading data: The first four columns of the input file go to the "Contract_Fact" worksheet of the output file, whereas the "Tech Manager" field goes to the "Dim_Tech_Manager" worksheet and the "Contract Party" goes to the "Dim_Contract_Party" worksheet in the output file.

    2. Sorting data: in the two "Dim" worksheets of the output file, keep the unique records only and give each a sequential ID

    3. Matching data: Do a v-lookup in the "Contract_Fact" worksheet, to indicate for each record, the IDs of its tech manager and contract party.

    Could you please help me out on this? Thank you very much in advance!!!

    Regards,
    Tuan
    Last edited by Tuanfeng; 08-28-2014 at 06:39 AM.

  2. #2
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: building data model

    Hi

    This Macro meets the first part of your requirement

    Please Login or Register  to view this content.
    Last edited by mehmetcik; 08-28-2014 at 06:34 PM.

  3. #3
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: building data model

    Please explain what you mean by Unique IDs for sheets 2 and 3.

  4. #4
    Registered User
    Join Date
    03-26-2014
    Location
    Rotterdam
    MS-Off Ver
    Excel 2010
    Posts
    16

    Re: building data model

    Hi Mehmetcik,

    Thanks for the reply! Although when I run the codes, an error occurred, saying "1004, application-defined or object-defined error". Can you help me solve it?

    As for my second and third point, in the original input file, the records under "Tech Manager" dimension and "Contract Party" dimension are not unique, meaning that one tech manager might be in charge of multiple contracts and therefore his/her name would appear multiple times. What I would like to achieve is basically for each dimension, find and keep all unique values, keep them in a separate sheet, and give each value an ID (starting from 1), and finally in the Contract_Fact sheet, do a v-lookup to indicate for each record, the IDs of its tech manager and contract party. (e.g. the column "Tech Manager" in the current input file will be replaced by "Tech_Manager_ID")

    I hope this clarifies the requirement a bit more. My apologies for using unique value for each field in the sample file.

    Look forward to your reply!

    Regards,

+ 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. Creating a Pyramid Hierarchy structure from a flat structure
    By thegamerulez in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-16-2014, 01:28 AM
  2. Form: Load Picture from Worksheet instead of a folder structure
    By duugg in forum Excel Programming / VBA / Macros
    Replies: 32
    Last Post: 11-18-2011, 09:03 PM
  3. "convert" data with logfile structure to spreadsheet structure
    By boarders paradise in forum Excel General
    Replies: 7
    Last Post: 01-10-2011, 02:06 AM
  4. Data structure?
    By ahartman in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-15-2008, 05:37 PM
  5. [SOLVED] data structure and my problem
    By samantha in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-11-2005, 10:06 AM

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