[SPCONV-ERR(<NN>)]:('Raiserror ( num') Manual Conversion Might be Required num gives ID in SQL Server SYSCOMMENTS table

When the 'Raiserror( number' code is executed in T-SQL, error text is retrieved from the SYSCOMMENTS table. This T-SQL code is currently converted to the following in PL/SQL:

raise_application_error(-20999, 'id  <STRING');

Conversion to PL/SQL with the correct error/warning text requires manual conversion.

The following example illustrates how the T-SQL to PL/SQL parser in the Migration Workbench could produce this error:

/* a comment*/
CREATE PROC myerror
AS
BEGIN
raiserror(50324,12,5)
END

The following PL/SQL code is produced by the parser:

CREATE OR REPLACE PROCEDURE myerror
AS
StoO_selcnt INTEGER;
StoO_error  INTEGER;
StoO_rowcnt INTEGER;
StoO_errmsg VARCHAR2(255);
StoO_sqlstatus INTEGER;
/* a comment*/

BEGIN
 raise_application_error(-20999, 'id 50324');
 /*[SPCONV-ERR(5)]:('Raiserror ( num') MANUAL CONVERSION MIGHT BE REQUIRED
num gives id in MS SQL Server SYSCOMMENTS table*/

END;

This problem can be avoided by adding the text from the SQL Server SYSMESSAGES data dictionary table as follows:

CREATE OR REPLACE PROCEDURE myerror
AS
StoO_selcnt INTEGER;
StoO_error  INTEGER;
StoO_rowcnt INTEGER;
StoO_errmsg VARCHAR2(255);
StoO_sqlstatus INTEGER;
/* a comment*/

BEGIN
 raise_application_error(-20999, 'text from sysmessages');

END;