I don't know how to debug it when I write a store. There is a commissioning method to print the value of the variable in the program, in Java, is printing on the console. The following tells how exclusive will be implemented from SQLPLUS.
1. Execute the "SET ServerOptput on" command on SQLPLUS
2, you can use dBMS_output.put_line (varname) during storage.
Example for a stored procedure:
Create or Replace Procedure Test IS
EMP_NAME VARCHAR2 (10); CURSOR C1 IS SELECT ENAME FROM EMP WHERE DEPTNO = 20; Begin Open C1; LOOP FETCH C1 INTO EMP_NAME; EXIT WHEN C1% Notfound; DBMS_OUTPUT.PUT_LINE (EMP_NAME); End Loop;
End test;
Establish TEST stored procedures, compile it, enter the Scott / Tiger account, execute SET ServerOptput ON, then execute "Exec Test"