All Forums UDA
kokopelli_stew 1 post Joined 05/09
13 May 2009
Storing TD Stored Procedures

Hi, this is so silly... I've not done this in a while and must be making a very basic but not obvious mistake. I've written a stored procedure. I do understand that it has to be compiled to make it executable but my recollection is that simply CREATEing the procedure will do the syntax checks for me. I'm trying to store my procedure but continue to get the error message - "Failure 3706 Syntax error: Invalid SQL Statement." I've looked this up but apparently 3706 is a "catch-all" so that didn't help either. Trying to isolate the error, I've dumbed it down to the most basic syntax but the error remains. I'm hoping somebody can help me recall how to do this.CREATE PROCEDURE TESTIT ()beginend;THANKS!!

joedsilva 505 posts Joined 07/05
13 May 2009

put the stored procedure definition into a file ( mysp.sql )REPLACE PROCEDURE TESTIT()begindeclare o_msg varchar(10) ;end;then in bteq do a.compile file = mysp.sql;The other option is put the definition directly to sql assistant and execute it ...

umakathir 32 posts Joined 09/06
15 May 2009

I hope you would have connected to database before creating the procedure. If so, place the definition in Teradata SQL Assistant and Press F5. It will check the syntax.REPLACE PROCEDURE TEST()BEGINEND;

karthikkaja 1 post Joined 11/11
29 Nov 2011

hai all

This is siva i am new to teradata

first of all,i lik to share my problem with all

how run a bteq,fastload,mload in unix shell scripting any one can help me pleas send any scripts to me

Thank You 

sivaprasad kaja

You must sign in to leave a comment.