Burkhard wrote : >I've a simple dbproce like
>CREATE DBPROC P_TEST AS >IF EXISTS (SELECT * FROM T_TEST) THEN STOP(9999); >when i call the dbproc with >CALL TEST >the follwing error occurs : >S1000[SAP AG][LIBSQLOD SO][SAP DB]General error;-9210 POS(1) System >error: KB Stack op illegal. >SAPDB 7.4.3.7 runs under Linux 2.4.18 >It seems as if this is a bug. This is a known bug. The exists predicate is not supported by the IF-statement, but unfortunately the compiler doesn't notice that and produces wrong byte code. This bug will be fixed soon. Please see the following example how to avoid the problem : CREATE DBPROC P_TEST AS VAR CNT INTEGER; SELECT COUNT(*) INTO :CNT FROM T_TEST WHERE ROWNO <= 1; IF CNT > 0 THEN STOP(9999); Regards, Thomas -- Thomas Anhaus SAP DB, SAP Labs Berlin [EMAIL PROTECTED] http://www.sapdb.org/ _______________________________________________ sapdb.general mailing list [EMAIL PROTECTED] http://listserv.sap.com/mailman/listinfo/sapdb.general _______________________________________________ sapdb.general mailing list [EMAIL PROTECTED] http://listserv.sap.com/mailman/listinfo/sapdb.general
