OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Dropping Stored Procedures in dynamic SQL

From: R. Klemme (bob.newsgmx.net)
Date: Mon Jun 28 2004 - 02:46:25 CDT


Hi all,

I can't seem to get this to work:

create dbproc XXX
as
var
  str VARCHAR(100);
begin
  set str = 'FOO;';
  execute 'drop dbproc CR_ADMIN.RR_' || str;
  stop($rc, $errmsg);
end;

Calling this SP results in a syntax error:
Syntax error or access violation;-3005 POS(1) Invalid SQL statement.

MaxDB version is 7.5.0

The error disappears if I comment the "stop" line so I assume it's a message
resulting from the "execute". Anything I'm doing wrong here?

Btw: stored procedures do not show up in SYS.CAT and SYS.ALL_OBJECTS. Is
there any way to determine all stored procedures of a user programmatically?

Thanks!

Regards

robert

--
"Sie haben neue Mails!" - Die GMX Toolbar informiert Sie beim Surfen!
Jetzt aktivieren unter http://www.gmx.net/info

--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb