All Forums Connectivity
piotrs 10 posts Joined 08/09
07 May 2010
CREATE PROCEDURE using ODBC

I connect to Teradata using ODBC and I would like to create very simple stored procedure. When I call SQLPrepare I receive error "[Teradata][ODBC Teradata Driver][Teradata Database] Syntax error: Invalid SQL Statement.", but when I call the same CREATE PROCEDURE... statement using SQLExecDirect then it works. It also works using SQL Assistant with .NET Provider. I tried using ODBC driver 12 and 13.

Is it normal that SQLPrepare doesn't work with CREATE PROCEDURE and SPL?

vhari 111 posts Joined 12/08
10 May 2010

Yes it is expected. You cannot use SQLPrepare() for CREATE/REPLACE PROCEDURE.

You must sign in to leave a comment.