Teradata Stored Procedure GOTO

Database
Enthusiast

Teradata Stored Procedure GOTO

Hi

I am using TD 14.0 and writing a stored procedure where using GOTO I am trying to move to another Label.

But surprisingly it is showing me error as below.

SPL1027:E(L34), Missing/Invalid SQL statement'E(3703):'GOTO' is a Teradata SQL keyword reserved for future use.'.

Any  suggestion on this. How could I move from one label to another if GOTO is not working?

Thanks

Santanu

2 REPLIES
Teradata Employee

Re: Teradata Stored Procedure GOTO

Use structured programming constructs to control the program flow instead

BEGIN ... END

IF ... THEN ... ELSE ... ENDIF

LOOP / WHILE / REPEAT with ITERATE / LEAVE

Enthusiast

Re: Teradata Stored Procedure GOTO

Hi Fred,

Sorry for the delay in response. Thanks a lot for your help. I finally managed it using While loop and If Then Else option.

Thanking You

Santanu