Adding data to an existing table at the next empty row.

nuno1340

New member
Local time
Today, 14:18
Joined
Oct 16, 2007
Messages
7
Hi all (first post)

I need help with the start of my Access database project, if possible.

I am looking to populate a table called "data file" with information from CSV files produced everyday.

My aim is to browse every day to a directory containing a CSV file and import it into my Access "data file" table. I need the information from the CSV file imported into the next empty row in the table, enabling me to build up history in one file.

The only problem with the CSV file is the table headers (which i want to import) begin on row 3. I could go in and delete the top 2 rows but it would be great if I didn't have to do this.

Anyway, at this point the most important thing is adding the data at the next available line. How easy is it to achieve this?

Any help would be greatly appreciated.

Thanks

Nuno
 
Now i do understand that this requires an append query, but i need this to be userfriendly and scaleable...

So someone without any sql experience can append the "data file"
 
Two options:

1.a Use the TransferText command. Can set options so you can miss NULL values.
1.b. Append data (WHERE NOT NULL)

2.a Open file
2.b Loop through until EOF and insert records in table (WHERE NOT NULL)

There should be lots of info on the above in these forums.
 

Users who are viewing this thread

Back
Top Bottom