Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Wed, 14 May 2008 @ 14:15:43 GMT


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


Subj:   Re: How to Alter table a UPI column
 
From:   Michael Larkins

Hello Prem:

To answer your basic question: no, there is no alter to convert a UPI to an identiy column.

To go further: it is normally not a good idea to do this

In Teradata, you pick a PI because that is how you use the data. You use a PI that you reference in a WHERE or an ON. Using the PI is the fastest possible access to your data. If you are making a surogate key (like identity column) to gain a PK or to evenly distribute your data across the AMPs, make sure that is what you really, truly need. Otherwise, ever time you access a row it becomes a full table scan to find it or redistribution must occur in order to join these rows to other tables.

A PI should be defined based on usage as well as distribution.


Hope this helps,

Michael Larkins
Certified Teradata Master
Certified Teradata SQL Instructor



     
  <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: 27 Dec 2016