Home Page for the TeradataForum

Archives of the TeradataForum

Message Posted: Thu, 21 May 2009 @ 10:00:50 GMT

  <Prev Next>  
Next> Last>>  

Subj:   Read only first line of input file
From:   Anomy Anom

<-- Anonymously Posted: Thursday, May 21, 2009 02:41 -->


What is the syntax for reading only the first lilne of a an input file? I need to read in the header record (the very first record in the file which has different layout from the detail records) of a file, then use the processing date within the header record to insert a record into a table.

      apply insert where rec_id  = '0';

       rec_id              (CHAR(01))
      ,file_date           (CHAR(14))
      ,process_yy          (CHAR(4))
      ,process_mm          (CHAR(2))
      ,process_dd          (CHAR(2))

     INSERT INTO table_name

The above inserts nothing into the table (although the job ran succesfully)

  <Prev Next>  
Next> Last>>  
  Top Home Privacy Feedback  
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 15 Jun 2023