Results 1 to 4 of 4
  1. #1
    Ben is offline Novice
    Windows XP Access 2007
    Join Date
    Aug 2009
    Posts
    4

    Import and overwrite?

    Hi, I want to be able to import data from excel into a table from which a report is generated. However, quite often, the attributes within each record will change (obviously excluding the primary key). What I really want to be able to do is import the data and have any duplicates overwrite what is currently in the table as I am always interested in the most recent data. Is there any way to do this?

    If not, one way I'm thinking I could possibly get around it is to change my primary key to an Autonumber field (currently I don't use any autonumbers in the table) and then run a find duplicates query on the field I am currently using as my primary key. Firstly, would this work? Secondly, having done this, how could I get the least recently acquired part of the duplicate to be ignored in the final report?

    Sorry but I really am new to Access so haven't learned to much of the functionality yet, any help is greatly appreciated.

    Thanks

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Couldn't you just delete all of the current records in Access and just use all of the new import data?

  3. #3
    Ben is offline Novice
    Windows XP Access 2007
    Join Date
    Aug 2009
    Posts
    4
    No, because I want the reords which do not chnage to stay in the database. Not all of them will change, those that do I want to be overwritten, those that don't I want to stay as they are.

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    So the only data being imported is data that has changed? In any event, it sounds like you need to import into a separate table and then update where appropriate.

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

Similar Threads

  1. How would I import something like this?
    By Insyderznf in forum Import/Export Data
    Replies: 13
    Last Post: 08-10-2009, 05:18 PM
  2. Import a .sql file?
    By Alan in forum Import/Export Data
    Replies: 1
    Last Post: 06-03-2009, 07:52 PM
  3. Import from MS Works
    By jerald in forum Import/Export Data
    Replies: 0
    Last Post: 03-17-2009, 08:00 AM
  4. Validation on import
    By andy_42 in forum Import/Export Data
    Replies: 1
    Last Post: 10-23-2006, 03:52 PM
  5. CSV File Import
    By compasst in forum Import/Export Data
    Replies: 3
    Last Post: 03-31-2006, 09:37 AM

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