Importing mulitiple .txt files into Access

It is work but, now I have other question. I need to look date, if exit this date on the csv file on the Table. this do not permit to update this file?

can you help me to this issue?

this is my code

DoCmd.TransferText acImportDelim, SpecificationName:="Absences Import Specification", tablename:="ABSENCES", FileName:="E:\DB\ABSENCES.csv", HasFieldNames:=YES

Thank you, I appreciate your help.
 
Import it into a new table, then look at it and find out where the 2 tables differs.
Else make a copy of the table and add the field "F1".
 
thank you, I can Import it csv with delimited "|" to my table. my app it is working now.

I have one question. it is possible when I import this information if Can I check it the date from me csv file exists on my table if exit this information does not import into my table.

thank you
 
When I import files, I log the file name and date so that I can prevent a file from being imported multiple times. Of course if the user renames the file you're SOL.

Create a table with:
UniqueID (autonumber)
FilePath
FileName
ImportDT
RecCount

Use DCount() using the path and name to see if the file has previously been imported.
If it hasn't, add the filename to the table using DAO so you can pick up the autonumber as the row is added.
Count the number of rows imported and update the log record.
 

Users who are viewing this thread

Back
Top Bottom