Skip to Main Content

SQL & PL/SQL

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!

Alternative for HTP.P() in ORDS

User_CI7SYNov 30 2021

Hi Team,
Below code inside ORDS template to call one procedure named DISTINV.calc_distinv_rank using huge clob data as input works fine without HTP.P(DOC1) but since we want to print output we use it. For less number of records ,everything works fine. But when record size grows, it throws error-REST Data Services
555 User Defined Resource Error
2021-11-30T10:39:24.645289Z | itkNbD_ylF1ZI_OHddPrxg | ORDS-25001

The request could not be processed because an error occurred whilst attempting to evaluate the SQL statement associated with this resource. Please check the SQL statement is correctly formed and executes without error. SQL Error Code: 6502, Error Message: ORA-06502: PL/SQL: numeric or value error ORA-06512: at line 6
Debug Trace
[TE] url-mapping start: 2021-11-30T10:39:24.645312Z duration: 0ms
[TE] dispatch start: 2021-11-30T10:39:24.660585Z duration: 327ms
---------------------------------------------------------------------
Code:
DECLARE
DOC1 CLOB ;
BEGIN
DISTINV.calc_distinv_rank( :body_text,DOC1);
OWA_UTIL.MIME_HEADER('application/json');
HTP.P(DOC1);
END;

This post has been answered by Paulzip on Nov 30 2021
Jump to Answer
Comments
Post Details
Added on Nov 30 2021
14 comments
2,522 views