Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

GET_DDL Returning Error ORA-31603 (Object Not Found)

lawarnerJul 26 2005 — edited Jun 22 2011
Executing the following statement:

SELECT dbms_lob.substr(
DBMS_METADATA.GET_DDL('TYPE', 'VEST_INCR_HIST_T', 'LW_SM' ),32000,1)
INTO :P1_CLOB FROM DUAL;

from htmldb returns the following error.

ORA-31603: object "SM_RETENTION_LOG" of type TABLE not found in schema "LW_SM"

Executing the equivalent statement from SQLQ*Plus works fine.

DECLARE
v_str VARCHAR2(4000);
BEGIN
SELECT dbms_lob.substr(
DBMS_METADATA.GET_DDL('TYPE', 'VEST_INCR_HIST_T', 'LW_SM' ),32000,1)
INTO v_str FROM DUAL;
DBMS_OUTPUT.PUT_LINE ( SUBSTR(v_Str,1,255) );
END;

We have seen the same error with permission problems, but the HTMLDB_PUBLIC_USER has the correct access to execute the statement as seen in SQL*PLUS. The only difference is that from the HTMLDB application I must log in as the user. Within SQL*PLUS the password is the administrator's password.

Can anyone help? This is keeping us from going live with the application.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 20 2011
Added on Jul 26 2005
12 comments
17,502 views