Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: One query Two Databases
Hi Trevor,
There is very old but easy way to copy table from one database to another. It's using COPY command from SQL*Plus.
It is fragment from SQL*Plus documentation:
The following command copies the entire EMP table to a table named
WESTEMP.
Note that the tables are located in two different databases. If
WESTEMP already
exists, SQL*Plus replaces the table and its contents. The columns in
WESTEMP have the same names as the columns in the source table, EMP.
SQL> COPY FROM SCOTT/TIGER_at_HQ TO JOHN/CHROME_at_WEST ->
REPLACE WESTEMP ->
USING SELECT * FROM EMP
Regards,
Michael
Brainbench MVP for Oracle Programming
http://www.brainbench.com
"Trevor Bourget" <tbourget-REMOVE-_at_racltd.com> wrote in message news:<up45e2r8n7k16f_at_corp.supernews.com>...
> Is it possible?
>
> What I am trying to do is migrate our tables from the old database (Oracle
> 7) to our testing database (Oracle 8) without doing an Export/Import because
> we have rearranged the tables to be in slightly different tablespaces.
>
> What I am hoping is possible is a
> INSERT INTO Database2.Table
> SELECT * from Database1.Table
> or something like that.
>
> Thanks in advance,
>
> Trevor
Received on Mon Sep 30 2002 - 03:11:03 CDT
![]() |
![]() |