Start Debugging Object Method

dbForge Fusion PL/SQL Debugger allows debugging object static and member procedures and functions. The process of object method debugging can be initiated by calling this method in the PL/SQL program. Put the breakpoint on the line where the object method is called. On the Tools menu, select dbForge Fusion, and then click Step Into.

Creating a Sample Object Type

Procedure

Use the script available in How To: Debug a Stored Procedure to the procedure used in the sample below.

Object Type

Execute the following script to create an object type:

CREATE OR REPLACE TYPE SCHEDULE.REC_TYPE1
  AS
  OBJECT (DATE_OUT DATE,
          DAY_ORDER SMALLINT,
          TIME_SHEET_DATE DATE,
          MEMBER PROCEDURE ADMIT(DAYOPER SMALLINT));
/
 
CREATE OR REPLACE TYPE BODY SCHEDULE.REC_TYPE1 AS
MEMBER PROCEDURE ADMIT
( DAYOPER SMALLINT) AS
BEGIN
 DAY_ORDER := DAYOPER;
END;
END;
/

Debugging an Object Method

To debug the method of a created object, call it in the PL/SQL block and run the debugging process of this block. Select Step Into command when the debugger reaches the line where an object procedure call is fulfilled to step inside the method definition.

TYPE ENUM_TYPE IS TABLE OF REC_TYPE;
  DAY_ENUM ENUM_TYPE;
  DAY_ENUM2 REC_TYPE1;
 
  BEGIN
    DAY_ENUM2 := REC_TYPE1(DATE_FROM, NULL, SYSDATE);
    DAY_ENUM2.ADMIT(1);
  ...
END;