Results 1 to 3 of 3
  1. #1
    Zdz16 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2014
    Posts
    16

    Import text file with mapping to data table

    Hi to all;



    The question was asked more than once , and there were several answers. However I can not find a solution to my 'little' following question :
    I would like to import data from a text file with a separator ";" whose first line gives the names of the fields in the destination table . And with the following options that are available to the user :
    1 - The imported data will replace all data in the destination table . (remove all / Import all)
    2 - Only new data is added
    3 - Only the new ones are added , and if the data ( The key enregistremen ) Similar exist, they will be updated by the imported data
    4 - update only the existing data in the table.

    Import report should be generated

    The concern I have
    I can not do the mapping between the columns in the import file and the table and use it.
    I do not know how to match data types Import / Table ( Knowing that the import is in text format ?)
    Find the primary key and the load to achieve the 'find' in the destination table to apply the options ( below desssus )

    So, if you have suggestions , ideas I'm interested.

    Thank you to all of you cordially

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    A few comments/questions:

    1- research Import Specifications
    2- where is the input data coming from ?how is it created?
    3- how many tables do you use this data input technique for?
    4- have you considered bring the data into a tempTable and using a form to get user parameters, then based on selection execute the appropriate action query
    5- have you considered other options for inputting data?

  3. #3
    Zdz16 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2014
    Posts
    16
    Thinks for your replay;

    1-2 The data come from filing a separate application files on a server. On this side, I have no worries. However, the fact that these applications are independent, the order of columns may be changed. That is why I want make a mapping between the structure of these files and the table.
    3 - The table number is not a problem, since import is on a table at a time by the user.
    4 - Yes, I thought of this solution. But this step can be avoided if we can do the mapping procedures.
    5 - Not for the data processing, because the number of records are many and the user should not spend his time doing data entry

    What I want is to find an example of VBA code that performs the import data with mapping.

    Best regard

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

Similar Threads

  1. Replies: 2
    Last Post: 11-05-2013, 04:14 PM
  2. Replies: 7
    Last Post: 11-20-2012, 05:08 PM
  3. Replies: 5
    Last Post: 12-01-2011, 05:38 PM
  4. HELP! how to send data from table to text file
    By daveofgv in forum Import/Export Data
    Replies: 11
    Last Post: 02-14-2011, 01:22 AM
  5. copy data from text file into table in access
    By miziri in forum Programming
    Replies: 3
    Last Post: 08-12-2009, 03:02 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