All Forums Database
SAP 73 posts Joined 08/14
29 Sep 2014
PRINT in Stored Procedure

Hi ,
I need to display message when activity count is zero through a stored procedure . Please give me a sample script which will help me to rewrite for my reuirement .
But , if i use PRINT , i dont get any output .
Note :- I m using TD Studo express 15
 
Thanks
 

SAP
Raja_KT 1246 posts Joined 07/09
29 Sep 2014

I think you come from oracle background, with dbms_output.put_line :).
 
Printing messages are like
MESSAGE_TEXT ,
SELECT COUNT(*) INTO cnt FROM tab1;
IF (cnt = 0) THEN
SIGNAL SQLSTATE '02000';
 
In Teradata, as far as I see it is declaring Global temporary table trace, where we can trace the entire flow. It looks to be a better way.
http://www.info.teradata.com/HTMLPubs/DB_TTU_14_00/index.html#page/SQL_Reference/B035_1144_111A/Create_Authorization-Syntax.021.117.html
 

Raja K Thaw
My wiki: http://en.wikipedia.org/wiki/User:Kt_raj1
Street Children suffer not by their fault. We can help them if we want.

You must sign in to leave a comment.