TOAD 11.6.1.6
Oracle 11g client
With a package body definition where there are multiple space characters between the keyword PACKAGE and BODY, and with the ‘Schema name’ option checked under Script Options, the generated code corrupts the package body name.
e.g.
CREATE OR REPLACE PACKAGE testpkg IS
PROCEDURE testproc;
END;
/
CREATE OR REPLACE PACKAGE BODY testpkg IS <-- 2+ spaces between PACKAGE and BODY
PROCEDURE testproc AS
BEGIN
NULL;
END;
END;
/
Now, from the Schema Browser, if you right click on the package name and select Create Script, check the ‘Schema name’ option, and then click OK, the output for the package body will be corrupted.
e.g.
Prompt Package TESTPKG;
CREATE OR REPLACE PACKAGE MYSCHEMA.testpkg IS
PROCEDURE testproc;
END;
/
SHOW ERRORS;
Prompt Package Body TESTPKG;
CREATE OR REPLACE PACKAGE BODY MYSCHEMA.Y testpkg IS <-- corrupted; this varies according to length of schema name and number of spaces
PROCEDURE testproc AS
BEGIN
NULL;
END;
END;
/
SHOW ERRORS;
Has this been fixed in later releases?