Home » Other » Client Tools » copying table script from one database to another in TOAD
copying table script from one database to another in TOAD [message #12962] Mon, 14 June 2004 10:57 Go to next message
CB
Messages: 17
Registered: November 2003
Junior Member
copying table from one database to another using TOAD TOOL(it's basically  altering table.)
Re: copying table script from one database to another in TOAD [message #12963 is a reply to message #12962] Mon, 14 June 2004 11:43 Go to previous messageGo to next message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
Where is the question here?
Re: copying table script from one database to another in TOAD [message #12964 is a reply to message #12962] Mon, 14 June 2004 11:55 Go to previous messageGo to next message
CB
Messages: 17
Registered: November 2003
Junior Member
How to copy table from one database to another in TOAD?
Re: copying table script from one database to another in TOAD [message #12967 is a reply to message #12964] Mon, 14 June 2004 21:25 Go to previous message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
Do you want the table layout, the data or both? Do you need triggers to be included too?

In any of the above cases
is exp and imp, Oracle's export and import utilities, the easiest path.

In Toad the Export utility wizard is available if you have the DBA option.

If you're just looking for table layout and data, you could consider a simple 'Create table as select' statement. Grant access from the destination schema, to the source schema and perform from the destination schema something like:
CREATE TABLE <I>new_table_name</I>
AS
SELECT *
FROM <I>source_user.old_table_name@source_database</I>


You could also create a script via Toad, and export the data as insert statements to another scripts. In the destination database you simply run both and there you are.

As you see, several possibilities are provided for your convinience. A lot depends on what you're looking for: one table or more? triggers too? data? all data or just a small sample? grants? only data perhaps?

And then there's the issue of the Toad version you're using. Most possibilities are basic, but some might be missing in the freeware version.

Good luck!

MHE
Previous Topic: TOAD software installation
Next Topic: WHAT IS TOAD
Goto Forum:
  


Current Time: Fri Mar 29 00:42:46 CDT 2024