-
Insert new line character into RAISE_APPLICATION_ERROR text
Hi,
I have an exception which should output certain information:
WHEN OTHERS THEN
RAISE_APPLICATION_ERROR
( -20100, 'Unknown Error when attempting to log sql script: ' || i_Scriptname ||SQLERRM ( SQLCODE ) );
Problem is, it seems to output the first error code immedialty after the error text, like so:
BEGIN
*
ERROR at line 1:
ORA-20100: Unknown Error when attempting to log sql script:
Ora_Rat_DatabaseInfo.sqlORA-00920: invalid relational operator
ORA-06512: at "BLAKEYM.PR_LOGSCRIPTSTART", line 55
ORA-06512: at line 2
I'd ideally like to have to the SQLERRM printed on a seperate line so that it would look something like:
ORA-20100: Unknown Error when attempting to log sql script:
Ora_Rat_DatabaseInfo.sql
ORA-00920: invalid relational operator
ORA-06512: at "BLAKEYM.PR_LOGSCRIPTSTART", line 55
\n doesnt seem to work. Does anyone know a way to do this?
OCP 8i DBA
-
use CHR(10) fro new line
eg,
select 'zzzz' || chr(10) || 'aaaaaaaa' || chr(10) || 'bbbbb' from dual;
Cheers!
OraKid.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|