Connecting Tech Pros Worldwide Forums | Help | Site Map

Transfer table records from one to another

pwh777
Guest
 
Posts: n/a
#1: Nov 13 '05
I have read many of the topics on importing tables from one database to
another. However, I don't want to use the TransferDatabase command
because I want to copy all the records (not the object) from one table
in an external database into my current database. My current database
already has the table and I want that table to keep its records.

Any ideas?


David Lloyd
Guest
 
Posts: n/a
#2: Nov 13 '05

re: Transfer table records from one to another


One approach is to use the IN statement. For example

INSERT INTO MyLocalTable
SELECT *
FROM MyRemoteTable
IN 'C:\MyRemoteDatabase.mdb'

--
David Lloyd
MCSD .NET
http://LemingtonConsulting.com

This response is supplied "as is" without any representations or warranties.


"pwh777" <pwh777@hotmail.com> wrote in message
news:1119457380.848144.229550@g49g2000cwa.googlegr oups.com...
I have read many of the topics on importing tables from one database to
another. However, I don't want to use the TransferDatabase command
because I want to copy all the records (not the object) from one table
in an external database into my current database. My current database
already has the table and I want that table to keep its records.

Any ideas?


Bas Cost Budde
Guest
 
Posts: n/a
#3: Nov 13 '05

re: Transfer table records from one to another


pwh777 wrote:
[color=blue]
> I have read many of the topics on importing tables from one database to
> another. However, I don't want to use the TransferDatabase command
> because I want to copy all the records (not the object) from one table
> in an external database into my current database. My current database
> already has the table and I want that table to keep its records.[/color]

Do the TransferDatabase anyway, but name the external table differently.
Then, use an Append query to copy your records. You can delete the
linked table afterwards.

--
Bas Cost Budde, Holland
http://www.heuveltop.nl/BasCB/msac_index.html

pwh777
Guest
 
Posts: n/a
#4: Nov 13 '05

re: Transfer table records from one to another


It's working. Thanks so much David! That was awesome.

Closed Thread