0

I have following error message.

2011-08-08 14:27:09 [E]: xxx - ORA-06502: PL/SQL: numeric or value error:
character string buffer too small
ORA-06512: at "xxx", line 1671
ORA-06512: at "xxx", line 2083
ORA-06512: at "xxx", line 921
ORA-06512: at line 1

Can you tell me why there are many lines? It is stack unwinding or that messages were artificially put together?

OMG Ponies
  • 325,700
  • 82
  • 523
  • 502
michael nesterenko
  • 14,222
  • 25
  • 114
  • 182

1 Answers1

2

It's indeed stack unwinding.

You have probably called stored procedure from a database IDE such as Toad (line 1). That procedure has a procedure call at line 921, which in turn... The error eventually occurred in a procedure or function on line 1671.

If I'm not mistaken, exception handlers can also contribute lines to the multi-line error message.

Codo
  • 75,595
  • 17
  • 168
  • 206
  • Is it possible to get the Procedure and Package name as you do in c# through reflection? – Revious Aug 11 '11 at 19:49
  • What do you mean, get the procedure name from the stack trace or get the current procedure name? I'm a bit confused because the term "through reflection" wouldn't be used for either one. Whatever, with the help of the DBMS_UTILITY package, you can get the current stacktrace or exception backtrace as a _string_. So you'll have to parse this string. That's doable. I've seen software successfully do it. – Codo Aug 11 '11 at 20:07
  • Yes, I'd like something like that. I've posted the question: http://stackoverflow.com/questions/7032373/oracle-pl-sql-how-to-get-the-stack-trace-package-name-and-procedure-name – Revious Aug 11 '11 at 20:27