Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Tue, 06 Dec 2005 @ 11:40:24 GMT


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


Subj:   Objectname as a parameter to macro
 
From:   Pandey, Vivek

Hi,

Is it a limitation that tablename can't be passed as a parameter in a macro?

The below SQL gives a syntax error

     Replace MACRO Macro_11 (TBName char(30))
     AS
     (
     Select 1 From :TBname ;
     );

However there are no problems if we pass column name as a parameter.

The below SQL succeeds.

     Replace MACRO Macro_11 (TBName char(30))
     AS
     (
     Select :TBname from tt2;
     );

     exec macro_11('a');

I could not find much info in the DDL manual too :(


Thanks, Vivek



     
  <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