PL SQL Remote Debug using SQL Developer

The following video outlines the usage of SQL Developer to remotely debug PL SQL procedures using JDWP protocol.

Some of the code snippets used in the presentation -

1. Sample Procedure for debug -

CREATE OR REPLACE procedure TEST.debug1 as
v1 int;
v2 int;
v3 int;
Begin
DBMS_DEBUG_JDWP.CONNECT_TCP(‘192.168.1.7′,4000);
v1:= 134;
v2 := 3;
v3 := 4;
dbms_output.put_line(v1);
dbms_output.put_line(v2);
dbms_output.put_line(v3);
dbms_debug_jdwp.disconnect(dbms_debug_jdwp.current_session_id, dbms_debug_jdwp.current_session_serial);
End;
/

2. Calling Procedure -

Begin
TEST.debug1;
End;

Presentation -

About these ads

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: