Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Tue, 26 Jul 2005 @ 15:45:28 GMT


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


Subj:   Re: Error :3518 Too many column in composite Index
 
From:   Diehl, Robert

Sushant,

Please explain the following.

1) how many columns

2) reason for choice of this Primary Index (PI).


Are you trying to ensure unique rows? If the table is a 'SET' table it enforces unique rows.

Is there another column or set of columns that would make a better PI? Basic rules for choosing PI in order of precedence.

1) If table is frequently joined to other tables, choose columns used in joins as long as they are unique or nearly unique. Both tables should have same PI if possible.

2) columns used frequently in lookup of a few rows as long as they are unique or nearly unique. This is helpful for Tactical Queries and single amp lookups.

3) Column/Columns that are unique or nearly unique. Most often for small reference tables.

Always remember the PI choice must be unique or nearly unique. Also collect stats on joined columns even if not an index as a rule of thumb.


Thanks,

Bob Diehl
Travelcoity.com



     
  <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