Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Transfer values of ABAP Variable to PL/SQL code block

Former Member
0 Kudos

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,

1 REPLY 1

horst_keller
Product and Topic Expert
Product and Topic Expert

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

(same example for EXEC SQL)