Debug Function within a package

Asked

Viewed 1,155 times

0

I have a package with several functions and procs. How do I, using pl/sql Developer, debug? I would like to know how I go to the error and see what is being passed.

Using the pl/sql Tests tool I know I can debug. What happens is that Function is inside a package and would like to know how I do it, debugging, seeing the value of variables and etc

1 answer

1


You can use the Command:

ALTER PACKAGE PKG_NOME COMPILE DEBUG;

This will make it possible to debug your package.

Then in Sqlwindow right click on your package, and select: "Edig Spec & Body", then put the break points where want to test then run your test on a "Test Window", as an example:

declare
  result boolean;
begin
  result := PKG_NOME.F_NOME('PRIMEIROPARAMETRO','SEGUNDOPARAMETRO');
  :result := sys.diutil.bool_to_int(result);
end;

Beyond this option within the "Edig Spec & Body", go to the second tab and locate its function right click and select Test, which will have the same effect.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.