Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Command to check stored procedures.

Status
Not open for further replies.

CapsuleCorpJX

IS-IT--Management
Jun 23, 2004
70
US
We had a problem where a stored procedure was referencing a column in a table that no longer existed, and it crashed the database.

Anyway, a Teradata patch fixed the problem. But is there some sql command that will either recompile a procedure or check if a procedure is well formed (all the columns and tables it is referencing exists).
 
In V2R5 there's a "ALTER PROCEDURE ... COMPILE", just watch for warnings about missing objects.
Before that you'll have to create a script (using BTEQ) with "REPLACE PROCEDURE ..." and submit it and wait for errors.

Of course this will fail if the SP was created "WITH NO SPL".

Dieter
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top