Skip to Content
-1

Transfer values of ABAP Variable to PL/SQL code block

Jul 28, 2017 at 11:09 AM

33

avatar image
Former Member

Dears,

I am going to call a stored function in Oracle DB from SAP R/3 using ABAP, I want to use the below PL/SQL statement, what I need is to assign a value to TicketInfo from ABAP global variable, and to transfer the result apex_reply to ABAP global variable, would you please assist me how could I achive this,

EXEC SQL.
DECLARE
        TicketInfo CLOB;
        deq_key NUMBER(5);
        apex_reply CLOB;
        err_str NUMBER;
        err_msg VARCHAR2(2000);


    BEGIN
    
    TicketInfo := 'request xml  here';
      deq_key :=  APEX_CLI.ENQUEUE_PRORATION_REQUEST (  'APEX_CLI.APEX_CLI_Q', 1, TicketInfo, 1, 86400, 0 );
      
        IF(deq_key > 0 ) THEN
        err_str := APEX_CLI.dequeue_proration_request('APEX_CLI.APEX_CLI_Q', deq_key, apex_reply, err_msg, 240 );
   		END IF;          
   END;
 ENDEXEC.

Regards,

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Horst Keller
Jul 28, 2017 at 11:30 AM
1

I propose to use ADBC instead of EXEC SQL, see example.

(same example for EXEC SQL)

Share
10 |10000 characters needed characters left characters exceeded