Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Mon, 09 Feb 2004 @ 14:34:17 GMT


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


Subj:   Re: BTEQ Import, Variable Substitution Error
 
From:   Dempsey, Mike

I don't think there is a way to feed a database name into a BTEQ script but if you simply need to run DDL/SQL (no IF logic) you can do substitution of any part of a query using SQL Assistant. (Queryman)

SQL Assistant uses direct 'character string' substitution if the SQL is not Select, Insert, Update or Delete.

You can therefore enter such queries as:

Create User ? FROM DBC AS PASSWORD=? PERM=500000 ...


Where the values for ? (the user name) and ? (The initial password) will be read from the import file.

This is really intended for when you want to execute a statement multiple times, but you can also use it for one time execution if the Import file contains only one data record.

Note that starting with version 6.1 you can run SQL Assistant in batch mode - that is, it will terminate after it completes execution of the query.


Mike Dempsey
Teradata Client Tools



     
  <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