Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Thu, 07 Aug 2003 @ 07:53:17 GMT


     
  <Prev Next>   <<First <Prev Next> Last>>  


Subj:   Re: Moving Data Due to PI Restructuring
 
From:   David Wellman

Tony,

Technically correct, but...

My reason for suggesting that you may need to break the single insert/select into many was because of a lack of disk space. With a 260GB table, running a single insert/select to copy all of the data Teradata will build a spool file of 260GB. Hence if you run multiple insert/selects you can get away with a smaller spool space requirement.

If you run the multiple insert/selects as a single request (an MSR) , Teradata is going to build a single spool file of... 260GB, so you still need all that disk space. Worse, running an MSR will result in multiple Selects against the source data each of which (in this scenario) will typically be a full-table scan. So not only do you still need the full disk space, but you suffer multiple scans of the source data.

Where the MSR really works is if you've got source data coming from multiple source tables or you've got multiple complex selection criteria (in this case I'd try and combine the selects into one using a CASE statement anyway).


Cheers,

Dave



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