2 Replies Latest reply: Jan 23, 2013 9:12 PM by Sanjay Desai EBS RSS

    Concurrent program invoking through PLSQL

    647268
      I am executing the concurrent program through pl/sql and encounter below error message.

      REP-0004: Warning: Unable to open user preference file.
      MSG-00001: Error : GL set of Book Not Set Up
      REP-1419: 'beforereport': PL/SQL program aborted.
      REP-0069: Internal error
      REP-57054: In-process job terminated:Terminated with error:
      REP-1419: MSG-00001: Error : GL set of Book Not Set Up
      REP-1419: 'beforereport': PL/SQL program aborted.

      PL/SQL
      DECLARE
      v_request_id NUMBER DEFAULT 0;

      --Order Import Parameters
      p_operating_unit VARCHAR2(20) := NULL;
      p_order_source VARCHAR2(20) := 'XYZ';
      p_orig_sys_document_ref VARCHAR2(20) := NULL;
      p_operation_code VARCHAR2(20) := NULL;
      p_validate_only VARCHAR2(20) := 'N';
      p_debug_level VARCHAR2(20) := '1';
      p_num_instances VARCHAR2(20) := '4';
      p_sold_to_org_id VARCHAR2(20) := NULL;
      p_sold_to_org VARCHAR2(20) := NULL;
      p_change_sequence VARCHAR2(20) := NULL;
      p_perf_param VARCHAR2(20) := 'Y';
      p_rtrim_data VARCHAR2(20) := 'N';
      p_pro_ord_with_null_flag VARCHAR2(20) := 'Y';
      p_default_org_id VARCHAR2(20) := '83';
      p_validate_desc_flex VARCHAR2(20) := 'N';

      -- End of Parameters -----

      v_context varchar2(100);

      BEGIN
      -- Setting the context ----
      v_context := set_context('14013','XXXXXX',1762);
      IF v_context = 'F'
      THEN
      DBMS_OUTPUT.PUT_LINE('Error while setting the context');
      END IF;

      DBMS_OUTPUT.PUT_LINE('Submit Order Import Concurrent Program');

      v_request_id:= fnd_request.submit_request(
      application => 'PA'
      ,program => 'PAXACMPT'
      ,description => null
      ,start_time => SYSDATE
      ,sub_request => null
      ,argument1 => '129994'
      ,argument2 => '129994'
      ,argument3 => null
      ,argument4 => 'Y'
      ,argument5 => null
      ,argument6 => 'Y'
      ,argument7 => 'Y'
      ,argument8 => null
      ,argument9 => 'Y'
      ,argument10 => null
      ,argument11 => 'REGULAR'
      ,argument12 => null
      ,argument13 => 'N'
      ,argument14 => null
      ,argument15 => 'Y'
      ,argument16 => 'Y'
      );

      COMMIT;

      DBMS_OUTPUT.PUT_LINE('Request_id: '||v_request_id);

      EXCEPTION WHEN OTHERS THEN
      DBMS_OUTPUT.PUT_LINE(SQLCODE||' Error :'||SQLERRM);
      END;



      set_context is a function which is initialize fnd_global.apps_initialize and mo_global.set_policy_context.