15.10 - Procedure - Teradata Database

Teradata Database SQL Data Definition Language Syntax and Examples

prodname
Teradata Database
vrm_release
15.10
created_date
December 2015
category
Programming Reference
featnum
B035-1144-151K
procedure_name
The name of the SQL procedure whose most recent SQL create text is to be reported.

SHOW PROCEDURE displays procedure text as it was sent to the database. You must type line breaks in the procedure using the Enter or Return key to properly display the text.

Example: SHOW PROCEDURE

This example illustrates a SHOW PROCEDURE request.

     SHOW PROCEDURE spSample1;
      *** Text of DDL statement returned.
      *** Total elapsed time was 1 second.
     -----------------------------------------------------------------
     CREATE PROCEDURE spSample1 (IN  ip INTEGER, 
                                 OUT op INTEGER) 
     BEGIN DECLARE var_1 INTEGER;
     SELECT col1 INTO var_1
     FROM tab_1
     WHERE col_2 = ip;
     SET op = var1 * 10;
     END;