Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Fri, 26 Oct 2007 @ 19:56:29 GMT


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


Subj:   Multiload error 3857 from BTEQ export file
 
From:   Millar, Timothy

I'm trying to multiload a file that was created from a BTEQ export as follows:

     EXPORT DATA FILE1.TXT;

     SELECT
     CAST (TheDate AS DATE FORMAT 'YYYY/MM/DD') AS RUNDATE
     ,CAST (TheTime AS VARCHAR(15)) AS RUNTIME
     ,'TMNGR' (VARCHAR(30)) AS SOURCE
     ....

     MULTILOAD:

     INSERT INTO EDW_CAP_MGMT.HEARTBEAT_HISTORY
       (TheDate
        ,TheTime
        ,Source
        ,other columns....
     )
     VALUES
       (
         CAST(:RUNDATE AS DATE FORMAT 'YYYY/MM/DD')
        ,CAST(:RUNTIME AS CHAR(15))
        ,CAST(:Source AS CHAR(30))
     ...
     );

My problem comes in with the fact that the first column is still exported in TEXT format "YYYY/MM/DD" but multiload is looking for a DATE format. When I try to CAST the incoming data to DATE format, I get the 3857 error: "Cannot use value (or macro parameter :RUNDATE)

Any suggestions?


Thanks,

Tim Millar



     
  <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