All Forums Database
Nagendhran 11 posts Joined 12/06
19 Dec 2006
Transfer a table to a different database

Hi, Is there a way to transfer a table from one database to another database in teradata ?thanks,Nagendhran

aravind-3019 39 posts Joined 08/06
19 Dec 2006

Hi,You can use copy objects option from the file menu(F8 command) from the Teradata Administrator(winddi) to accomplish this task.--Regards,Aravind

Nagendhran 11 posts Joined 12/06
19 Dec 2006

Hi, Thanks for your suggestion aravind.rgds,Nagendhran

Fred 1096 posts Joined 08/04
20 Dec 2006

Note that "Copy Objects" in Teradata Administrator only copies the definition (in effect does SHOW on one system and submits the resulting DDL on the other). It does not copy the data. There are many possible ways to move the data, including via ARCHIVE and COPY with the Teradata ARC utility.

Nagendhran 11 posts Joined 12/06
20 Dec 2006

can you eloborate more on this fred ?

22 Dec 2006

If u have access to unix command prompt then....invoke arcmain.--Command-line invocation of Teradata ARC from Solaris, MPRAS,HP-UX, and AIX:arcmain outlog=arcall.out --The above command line calls the ARCMAIN executable.--The default is archive to disk if no IOMODULE or IOPARM are specified. The input file named arcall.in contains ARCMAIN commands. The “<“ redirects the input file to ARCMAIN.--The following example illustrates how a database is copied:COPY DATA TABLE (Personnel)(FROM (OldPersonnel), NO FALLBACK),FILE = ARCHIVE;--The database named Personnel is restored from an archived database named OldPersonnel with all tables defined as nonfallback after the copy operation.The above information is there in Teradata manual "Teradata Archive/Recovery Utility Reference"

Ramakrishna Vedantam, Tata consultancy services, Hyderabad

22 Dec 2006

arcmain outlog=arcall.out --The above command line calls the ARCMAIN executable.

Ramakrishna Vedantam, Tata consultancy services, Hyderabad

22 Dec 2006

arcmain outlog=arcall.out < arcall.in

Ramakrishna Vedantam, Tata consultancy services, Hyderabad

leo.issac 184 posts Joined 07/06
23 Dec 2006

If you want to transfer the table with in the same node, you can use following syntax.suppose you have db1 with t1 and you want to transfer t1 into db2, then you can create a new table t1 in db2 as followsCreate table db2.t1 as db1.t1 with data;after create table completes, you can delete db1.t1.

Ramreddy ch 1 post Joined 12/11
14 Dec 2011

Hi use following script for Teradata Archive

logon servername/dbc,dbc;DUMP DATA TABLES(Database)
(USE READ LOCK,
RELEASE LOCK,
FILE=NVDSID1;

logon servername /dbc,dbc;COPY DATA TABLES(Database)
(RELEASE LOCK,
FILE=NVDSID1;
.logoff;
.quit;

save these two scripts are different and run @ command propmt with the following syntax

ARCMAIN SESSIONS=8 CATALOG OUTLOG=ARCALL.OUT <ARCALL.IN(MENCTION HERE FIRST SCRIPT) DO SAME FOR WITH COPY SCRIPT

 

Have fun

cheers....

You must sign in to leave a comment.