I have created a C# project using MS Access Database and I want to copy data from one table in to another.Is there a simple way to copy all records from one table to another?
Asked
Active
Viewed 1,650 times
2 Answers
3
If the columns are in the right order, you can do
insert into table2
select * from table1
If the order of the columns are different between the two tables, you can do
insert into table2 (column1, column2, column3)
select column1, column2, column3 from table1

Guilherme
- 5,143
- 5
- 39
- 60
1
How does this sound?
INSERT INTO Table2( Field1, Field2, FieldN )
SELECT Field1, Field2, FieldN
FROM Table1;

Dextere
- 281
- 1
- 3
- 13