Home Page for the TeradataForum

Archives of the TeradataForum

Message Posted: Fri, 22 Nov 2002 @ 16:11:49 GMT

  <Prev Next>   <<First <Prev

Subj:   Re: Loading a table from another table
From:   Ahnell, Dave

My original plan had been to use "Create Table As Select" syntax, but for whatever reason didn't see that syntax in the TD manual. Good to know it exists. I used "Insert Select" as recommended by several others though and that worked out fine. I was concerned about the overhead of the inserts, but going into an empty table it didn't matter.

You could load a table from another table's data in two ways, without the use of any tools :

1. If you want to duplicate an existing table with all its data, or need a subset of a table or data from different tables - accompanied with the table creation : then use the 'CREATE TABLE AS {|}WITH DATA'

2. On the other hand if the table already exists then use INSERT SELECT clause.

The above is possible if the tables exists within the same database or across databases , but on the same box.Across boxes you could use the utilities like FastLoad, Bteq, FastExport.

  <Prev Next>   <<First <Prev
  Top Home Privacy Feedback  
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 28 Jun 2020