Results 1 to 7 of 7
  1. #1
    teamcooper is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2014
    Posts
    6

    Importing Record with Multiple Subform/Child Records


    Hello!

    I am working on a db that records employee reimbursable expenses. I'd like the employee to fill out either an online form or email an excel sheet (from a template), the resuts of which will be imported to populate a form which the administrator will review and add to the database.

    The problem is that each expense report can have multiple lines written to different tables. Here is very simplified example

    tblVoucher (Master)

    VoucherID EmployeeID
    22 3


    tblTravelExpenses (Child)

    DATE VoucherID REASON KM
    12/12/14 22 Education 100
    13/12/14 22 Conference 200


    tblReimbusements (Child)
    DATE VoucherID VENDOR TOTAL
    12/12/14 22 Staples 20.00
    10/12/14 22 Taxi 10

    So my question is, how do I approach preparing the data for the import and then successfully populating the form?

    Thanks!

  2. #2
    teamcooper is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2014
    Posts
    6
    Ain't that the way -- I think I got a clue right after I posted. Should I be looking at something like this (import xml)?

  3. #3
    burrina's Avatar
    burrina is offline VIP
    Windows 8 Access 2010 32bit
    Join Date
    Oct 2012
    Location
    Freeport,Texas
    Posts
    1,383
    Why not simply use an existing inside db approach for this?

  4. #4
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    ...the resuts of which will be imported to populate a form...
    Data from the outside would be imported to the tables. It is important to keep this in mind as you figure out a way to import data to your DB.

    So my question is, how do I approach preparing the data for the import and then successfully populating the form?
    If you have a way to control how the data is created, be sure to include a key value in each row created that represents a given VoucherID. If you have a VoucherID for a given row in a spreadsheet, etc., appending child tables should not be an issue. After you have appended your tables, use a query to retrieve the records and display the results in a form.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    Also, review http://office.microsoft.com/en-us/in...001103247.aspx

    Access 2007 and 2010 have a utility called Collect Data (at least I can't find any reference that indicates it is in earlier versions). However, support for that utility was partially removed in Access 2013 (can't create new setups).
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  6. #6
    teamcooper is offline Novice
    Windows XP Access 2003
    Join Date
    Jul 2014
    Posts
    6
    Thanks guys! Sometimes I don't even know where to begin. I appreciate the tips!

  7. #7
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    Another option...

    Once the spreadsheet is reviewed, it could be saved as a CSV file.
    Then VBA could be used to open/read the CSV file and append the data to the correct tables.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Filtering Master Records and Subform Child Records
    By Nerther in forum Programming
    Replies: 6
    Last Post: 10-01-2013, 05:24 PM
  2. Replies: 4
    Last Post: 09-13-2013, 05:26 PM
  3. Child Record Created, but won't display in child form
    By CementCarver in forum Programming
    Replies: 1
    Last Post: 04-10-2013, 12:42 PM
  4. Replies: 12
    Last Post: 08-30-2011, 03:36 PM
  5. Delete child records with parent record
    By jpkeller55 in forum Access
    Replies: 8
    Last Post: 09-07-2010, 08:52 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums