Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Thu, 04 Dec 2003 @ 12:37:21 GMT


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


Subj:   Re: Primary Index
 
From:   Dennis Havez

Thanks Clay for your answer,

I would like to be sure to understand your help.

If many users have to create requests with clause = (Id1, Id2, Id3), you think it's better to create a table with 3 NUPI and 15 PK (Ex2) or rather a table with 15 UPI (Ex1) ?

That's true ?

Ex1.(100 millions rows)

CREATE TABLE test
(
      id1   INTEGER,
      id2   INTEGER,
      id3   INTEGER,
...
      id13  INTEGER,
      id14  INTEGER,
      id15  INTEGER
)
UNIQUE PRIMARY INDEX (id1, id2, id3 ..., id13, id14, id15)

Ex2. (100 millions rows)

CREATE TABLE test
(
      id1   INTEGER,
      id2   INTEGER,
      id3   INTEGER,
...
      id13  INTEGER,
      id14  INTEGER,
      id15  INTEGER,
      PRIMARY KEY(id1, id2, id3 ..., id13, id14, id15)
)
UNIQUE PRIMARY INDEX (id1, id2, id3)

Many thanks,

Denis



     
  <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