Having a brain fart on what I believe is a no brainer.
I'm trying to read the contents of a DBF and write it to an ACCDB table; this is to be a daily event and the DBF has between 500-1200 records each day.
I have successfully connected to and read the contents of a DBF table and filled my dataset [ da.Fill(ds, "Data") ] along with a DataGridView. All is good so far.
Now I want to write the entire table to my ACCDB Table and both structures are the same. I've done this before with no problems but this time it's a little different because I have no arguments or parameters. I just want to add all fields of every record. I see a ton of samples & examples WITH parameters, but no cmd.command INSERT examples to insert/copy everything.
Basically I want to: INSERT INTO [MyDBTable] SELECT * FROM ds.tables("data") .... or something like that.
Everything related to the connection string, data source, etc is fine; I've been using it for other procedures with no problems.
What I can't seem to get is:
- the INSERT statement
- whether I loop through the datatable row by row, or can copy the whole thing in one blast
Appreciate someone's guidance and patience
I'm trying to read the contents of a DBF and write it to an ACCDB table; this is to be a daily event and the DBF has between 500-1200 records each day.
I have successfully connected to and read the contents of a DBF table and filled my dataset [ da.Fill(ds, "Data") ] along with a DataGridView. All is good so far.
Now I want to write the entire table to my ACCDB Table and both structures are the same. I've done this before with no problems but this time it's a little different because I have no arguments or parameters. I just want to add all fields of every record. I see a ton of samples & examples WITH parameters, but no cmd.command INSERT examples to insert/copy everything.
Basically I want to: INSERT INTO [MyDBTable] SELECT * FROM ds.tables("data") .... or something like that.
Everything related to the connection string, data source, etc is fine; I've been using it for other procedures with no problems.
What I can't seem to get is:
- the INSERT statement
- whether I loop through the datatable row by row, or can copy the whole thing in one blast
Appreciate someone's guidance and patience