What would you do to execute the above block successfully?

Examine the following error:
SQL> DECLARE
v_runid NUMBER;
BEGIN
v_runid := DBMS_HPROF.ANALYZE (LOCATION => ‘PROFILE_DATA’,
FILENAME => ‘pd_cc_pkg.txt’);
DBMS_OUTPUT.PUT_LINE(‘Run ID: ‘ || v_runid);
END;
DECLARE
*
ERROR at line 1:
ORA-00942: table or view does not exist
ORA-06512: at “SYS.DBMS_HPROF”, line 299
ORA-06512: at line 4
What would you do to execute the above block successfully?

Examine the following error:
SQL> DECLARE
v_runid NUMBER;
BEGIN
v_runid := DBMS_HPROF.ANALYZE (LOCATION => ‘PROFILE_DATA’,
FILENAME => ‘pd_cc_pkg.txt’);
DBMS_OUTPUT.PUT_LINE(‘Run ID: ‘ || v_runid);
END;
DECLARE
*
ERROR at line 1:
ORA-00942: table or view does not exist
ORA-06512: at “SYS.DBMS_HPROF”, line 299
ORA-06512: at line 4
What would you do to execute the above block successfully?

A.
Start the PL/SQL profiler before executing the block.

B.
Run the tracetab.sql script located at ORACLE_HOME\RDBMS\ADMIN.

C.
Run the dbmshptab.sql script located at ORACLE_HOME\RDBMS\ADMIN.

D.
Grant READ and WRITE privileges to the current user on the PROFILE_DATA directory
object.



Leave a Reply 2

Your email address will not be published. Required fields are marked *


ja

ja

C.

http://docs.oracle.com/cd/B28359_01/appdev.111/b28424/adfns_profiler.htm#CHDGEFJF

To create the hierarchical profiler tables in Table 9-3 and the other data structures required for persistently storing profile data, follow these steps:

Run the script dbmshptab.sql (located in the directory rdbms/admin).

This script creates both the hierarchical profiler tables in Table 9-3 and the other data structures required for persistently storing profile data.

Note:
Running the script dbmshptab.sql drops any previously created hierarchical profiler tables.
Ensure that you have the following privileges:

EXECUTE privilege on the DBMS_HPROF package
READ privilege on the directory that DBMS_HPROF.analyze specifies