Articles Oracle Forms, PL/SQL, Java, J2EE
The DBMS_PROFILER package allows to determine the time taken by each instruction of your code.
At the same time, you could also see the internal processing time for the basic instructions.
Of course, these times depend on the power of the test machine.
On 9i database, you have to run some scripts to install the DBMS_PROFILER package
Connect to SYS
|
connect / as sysdba @<ORACLE_HOME>/rdbms/admin/proftab.sql |
| SQL> 1 DECLARE 2 Pgm NUMBER; 3 BEGIN 4 DBMS_PROFILER.START_PROFILER('test','test1',Pgm); 5 FD.F_TRACE('Hello Oracle world','T'); 6 DBMS_PROFILER.STOP_PROFILER; 7 DBMS_PROFILER.ROLLUP_RUN(Pgm); 8 PROF_REPORT_UTILITIES.PRINT_RUN(Pgm); 9* END; SQL> / |
On 10g database, it seems that there is nothing to install
This is a very simple procedure to test the DBMS_PROFILER package :
|
CREATE OR REPLACE PROCEDURE TEST_PROFILER i1 := i ; |
|
SQL> Begin PL/SQL procedure successfully completed. |
|
SQL> set linesize 500 UNIT_NAME OCCURED TOT_TIME LINE TEXT 19 rows selected. SQL> |