Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Wed, 15 Jun 2011 @ 09:59:02 GMT


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


Subj:   Mload failing: Access out of range input data
 
From:   madhu.priya

Hi,

We are trying to loa a file where the code is some what like

     .FIELD fhead_col1       *  CHAR(14);
     .FIELD fhead_col2       *  CHAR(02);
     .FIELD fhead_cl3        *  CHAR(04);
     .FIELD fhead_col4       *  CHAR(01);

     .FIELD fdetl_col10      1  CHAR(08);
     .FIELD fdetl_ col6      9  CHAR(05);
     .FIELD fdetl_col11      14 CHAR(05);
     .FIELD col12            19 CHAR(10);
     .FIELD fdetl_col7       29 CHAR(08);
     .FIELD fdetl_col8       *  CHAR(13) NULLIF fdetl_col8=' ';
     .FIELD fdetl_col9       *  CHAR(21) NULLIF fdetl_col9   =' ';


     .DML   LABEL      INSERT_FDETL;
     INSERT INTO  xyz
             (
               loc_nbr
               ,itm_nbr
               ,soh_qty
               ,tot_rtl_amt
               ,perd_to_dt
             )
             VALUES
             (
               :fdetl_col6
               ,:fdetl_col7
               ,:fdetl_col8     (DECIMAL(9,0), FORMAT '999999999V9999')
               ,:fdetl_col9     (DECIMAL(9,2), FORMAT '99999999999999999V9999')
               ,:fdetl_col10
             );

     .IMPORT INFILE abc
          FORMAT TEXT
          LAYOUT FILE_LAYOUT
          APPLY  INSERT_FDETL WHERE fdetl_col11 = 'FDETL';

This file throwing the error was

     01255FHEAD0000000001SHCP20110611235900ST1255Y
     2011061101255FDETL000000000200095635+000000000000
     2011061101255FDETL000000000300100382+000000000000

Giving error:

     attempted to access out of range input data
     in field 'FDETL_col8', file 'abc ,record number '1'.

We removed the 1st record and it worked fine .Ideally this should have not been the case.

The 1st record should not have been taken into consideration by mload. Could any one explain what might have been the cause.


Regrads,

Madhu



     
  <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: 27 Dec 2016