Home Page for the TeradataForum
 
 

 

Archives of the TeradataForum





Message Posted: Mon, 03 Mar 2008 @ 16:19:18 GMT





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




Subj:   Any function to check whether the object is present or not
 
From:   kishore



In Teradata is there any function to check whether the object(i.e. table, view, procedure, macro, function, trigger...) is present or not at login database.

Ex: In sql server Object_Id(<object Name>)

     If objectproperty(object_id('VWPRODUCT_LEAF'),'IsTable')=1
     Begin
         Drop table VWPRODUCT_LEAF
         Select @lcobjecttype='table'
     End
     Else
     If objectproperty(object_id('VWPRODUCT_LEAF'),'IsView')=1
     Begin
         Drop view VWPRODUCT_LEAF
         Select @lcobjecttype='view'
     End

Regards

Kishore KK.





     
  <Prev Next>  
<<First
<Prev
Next> Last>>  
 
 
 
 
 
 
 
 
  
 
  Top Home Join Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky 
Last Modified: 30 Jun 2008