Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Wed, 22 Nov 2006 @ 13:43:37 GMT


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


Subj:   Re: Length of timestamp
 
From:   Simard Rudel

Hi Victor and Dieter,

It was my first guest, I'm not trusting ODBC for DDL. But, I did create my table with BTEQ.

     show table donne.ttable_name;

      *** Text of DDL statement returned.
      *** Total elapsed time was 1 second.

     -----------------------------------------------------------
     CREATE SET TABLE donne.ttable_name ,NO FALLBACK ,
          NO BEFORE JOURNAL,
          NO AFTER JOURNAL,
          CHECKSUM = DEFAULT
          (
           TOC_TOC_TOC INTEGER,
           DHC_OCC_DP_ACTE_MD TIMESTAMP(6) DEFAULT CURRENT_TIMESTAMP(6))
     PRIMARY INDEX ( TOC_TOC_TOC );


      BTEQ -- Enter your DBC/SQL request or BTEQ command:


     select columnname, columntype, columnlength
     from dbc.columns
     where tablename = 'ttable_name';

      *** Query completed. 2 rows found. 3 columns returned.
      *** Total elapsed time was 2 seconds.

     ColumnName                      ColumnType   ColumnLength
     ------------------------------  ----------  -------------
     TOC_TOC_TOC                     I                       4
     DHC_OCC_DP_ACTE_MD              TS                     26

To answer to Dieter, if you look in the Data Dictionnary manual, you can find the ColumnLength description. The descrition is : Returns the length of a column as the maximum number of bytes used to physically store a column value in a table row.

We are running V2R6.0.


Regards,

Rudel



     
  <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