[AccessD] Curious Import Problem

Gustav Brock gustav at cactus.dk
Wed Jul 13 09:27:21 CDT 2016


Hi Lambert

Scary, though the link and query method is the one I normally use.
Thanks for the warning.

/gustav

-----Oprindelig meddelelse-----
Fra: AccessD [mailto:accessd-bounces at databaseadvisors.com] På vegne af Heenan, Lambert
Sendt: 13. juli 2016 16:22
Til: 'ACCESS-L Email (ACCESS-L at PEACH.EASE.LSOFT.COM)' <ACCESS-L at PEACH.EASE.LSOFT.COM>; 'Access-D Email (accessd at databaseadvisors.com)' <accessd at databaseadvisors.com>
Emne: [AccessD] Curious Import Problem

X-Posted to Access-L and Access-D

I'm posting this just as an FYI. Not seeking an explanation (though if anyone has one please post it).

Here is the story.

I'm loading a large (130,000+ row) CSV file into a staging table, where some pre-processing is done on the data, and then the whole lot is copied to the final table.

Recently the users notice some rows of data were missing.  I confirmed that they were indeed present in the original source table, but on investigating I found that they simply never made it into the staging table.

Importing was done by using

DoCmd.TransferText acImportDelim, "Name Of Import Spec", "Name of Destination Table", "Full path to CSV file", True

No error were thrown, and no Import Error tables were generated to explain the missing data.

After pondering this for a while I changed the initial import process. Instead of using DoCmd.TransferText I simply *linked* to the CVS text file, using the same import spec as I used for DoCmd.TransferText. Then I created a straightforward Append query based on the linked text file to append all the data to the staging table.  That did the trick. All rows were loaded.

Very odd.

Lambert 



More information about the AccessD mailing list