Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Tue, 28 Sep 2010 @ 14:39:06 GMT


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


Subj:   Second pair of eyes needed!
 
From:   John_Wight

Trying to extract rows from Production and inserting them into Dev table with BTEQ script. Script logs onto the prod system, deletes the 'file' then does export on that same file. SELECT is run OK and rows are produced and dumped into the file OK. Then log-off and then logon to the Dev system. do Import of 'file' which it says does NOT exist - but it does - AND - it's driving me nuts. So, I thought that some more eyes on the 'problem' would probably come up with the simple 'dumb' answer - i.e. should have done this, etc. Any help would be appreciated.

I've done this dozens of times - but right now ???

     .logon tdprod/xyz,

      *** Logon successfully completed.
      *** Teradata Database Release is V2R.06.02.02.93
      *** Teradata Database Version is 06.02.02.93
      *** Transaction Semantics are BTET.
      *** Character Set Name is 'ASCII'.

     .OS DEL c:\Data\ProdLoads.dat
     +---------+---------+---------+---------+---------+---------+---------+-

     .EXPORT DATA FILE=c:\Data\ProdLoads.dat;
      *** To reset export, type .EXPORT RESET
     +---------+---------+---------+---------+---------+---------+---------+-


     SELECT
      . . . . (code)
      1,2,3,4,5,6
     ;

      *** Success, Stmt# 1 ActivityCount = 27285
      *** Query completed. 27285 rows found. 17 columns returned.
      *** Total elapsed time was 3 seconds.


     +---------+---------+---------+---------+---------+---------+---------+-

     .EXPORT RESET;
      *** Output returned to console.
     +---------+---------+---------+---------+---------+---------+---------+-

     .LOGOFF
      *** You are now logged off from the DBC.
     +---------+---------+---------+---------+---------+---------+---------+-

     .logon tddev/xwy,

      *** Logon successfully completed.
      *** Teradata Database Release is V2R.06.02.02.93
      *** Teradata Database Version is 06.02.02.93
      *** Transaction Semantics are BTET.
      *** Character Set Name is 'ASCII'.

      *** Total elapsed time was 7 seconds.

     +---------+---------+---------+---------+---------+---------+---------+-

     .SET WIDTH 256
     +---------+---------+---------+---------+---------+---------+---------+-

     /* Specify import file */
     .IMPORT data FILE=c:\Data\ProdLoads.dat SKIP 1;
      *** Error: Open failed because: No such file or directory
     +---------+---------+---------+---------+---------+---------+---------+-

     /* Repeat next Teradata SQL statement */
     .REPEAT *;
     +---------+---------+---------+---------+---------+---------+---------+-

     USING (
       . . . (correct code for inserting data)
     );
      *** Error: Use IMPORT to open a file first before
                trying to read from it.
      *** Failure 3593 No DATA parcel sent and request uses a USING clause.
                     Statement# 1, Info =0
      *** Total elapsed time was 1 second.

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