Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2007
    Posts
    14

    Unanswered: Import ODBC database to MS Access

    Hi,

    I'm trying to build a macro to import to MS Access a table from an ODBC database.

    I used the "TransferDataBase" method, and it worked well. The problem, is that I want to update periodically (let's say weekly) the data in my Access database. Each time I re-launch the macro, Access adds a number to the name of the table as it conflicts with an existing name (the name of the previous version of the table). As the imported table has relationships with several other tables, that's a big problem.

    Is there a way to force Access to replace the table? Won't the existing relationships be deleted? Is there a easier way to update my data from an ODBC db weekly? (I would prefer no to use linked tables).

    Thx

    antoine

  2. #2
    Join Date
    Jan 2007
    Location
    California, USA
    Posts
    520
    Import the data into a temporary table that you have made sure is deleted just before the import process. Then copy the data from the temporary table into your "permanent" table. Of course you will need to delete the records from your permanent table before copying the records from the temporary table.

  3. #3
    Join Date
    Sep 2007
    Posts
    14
    Thx

    It works.

    antoine

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •