Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Fri, 22 Jul 2011 @ 16:29:26 GMT


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


Subj:   Re: Primary Index Column
 
From:   John_Wight

If you want to have meta-data on index types, you can use the following in your TD systems:

     CREATE SET TABLE EDW_INDEX_TYPE ,NO FALLBACK ,
          NO BEFORE JOURNAL,
          NO AFTER JOURNAL,
          CHECKSUM = DEFAULT
          (
           IndexTypeCode CHAR(1) CHARACTER SET LATIN NOT CASESPECIFIC TITLE 'IndexTypeCode' NOT NULL,
           IndexDescription VARCHAR(40) CHARACTER SET LATIN NOT CASESPECIFIC TITLE 'IndexDescription')
     UNIQUE PRIMARY INDEX UPI_INDX_TYPE ( IndexTypeCode );

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('P', 'Nonpartitioned Primary');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('V', 'Value Ordered Secondary');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('K', 'Primary Key');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('S', 'Secondary');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('H', 'Hash Ordered All Coverin');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('U', 'Unique Constraint');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('Q', 'Partitioned Primary');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('I', 'Ordering Column Composite Secondary');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('J', 'Join');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('M', 'Multi-Column Statistics');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('1', 'Field1 Column of Join or Hash ');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('N', 'Hash');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('O', 'Value Ordered All Covering Secondary');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('D', 'Derived Column Partition Statistics');

     INSERT INTO dbadmin.EDW_INDEX_TYPE (IndexTypeCode, IndexDescription)
         VALUES ('2', 'Fild2 column of a Join or Hash');

JK



     
  <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