Showing posts with label API to update supplier payment method in r12. Show all posts
Showing posts with label API to update supplier payment method in r12. Show all posts

Tuesday, 2 February 2021

API to update supplier payment method in r12

API to update supplier payment method in r12

Hi friends, we are going to discuss about the api to update supplier payment method in r12. We will share the detail plsql script to update the supplier payment methods in oracle r12. We have the standard api in oracle apps r12 to maintain and update the supplier payment method details. We are using this api in our plsql script to update the supplier payment method in oracle r12. This is one of the most useful script while working on oracle r12 projects. We need to use this api script to update supplier details in r12. Please find below the complete detail about the API to update supplier payment method in r12.

API to update supplier payment method in r12
API to update supplier payment method in r12

Important API to update supplier payment method in r12

iby_disbursement_setup_pub.update_external_payee

API to update supplier payment method in r12
API to update supplier payment method in r12


Detail PLSQL API to update supplier payment method in r12

Here below is the complete script using the api to update the payment method of suppliers in oracle apps r12. You just need to use this , to make the changes in the supplier payment method.

API to update supplier payment method in r12
API to update supplier payment method in r12

DECLARE
   x_return_status             VARCHAR2 (200) := NULL;
   x_msg_count                 NUMBER :=0;
   x_msg_data                  VARCHAR2 (200) := NULL;
   l_payee_upd_status          iby_disbursement_setup_pub.ext_payee_update_tab_type;
   p_external_payee_tab_type   iby_disbursement_setup_pub.external_payee_tab_type;
   p_ext_payee_id_tab_type     iby_disbursement_setup_pub.ext_payee_id_tab_type;
   p_ext_payee_id_rec          iby_disbursement_setup_pub.Ext_Payee_ID_Rec_Type;
   l_ext_payee_rec             IBY_DISBURSEMENT_SETUP_PUB.External_Payee_Rec_Type;

   i                           NUMBER := 0;
   g_org_id                    NUMBER := 85;
   g_user_id                   NUMBER := 3675;
   g_resp_id                   NUMBER := 20639;
   g_resp_appl_id              NUMBER := 200;
BEGIN
      fnd_global.apps_initialize (user_id        => g_user_id,
                                  resp_id        => g_resp_id,
                                  resp_appl_id   => g_resp_appl_id);

     mo_global.set_policy_context ('S',115);
     
FOR I IN C LOOP

      p_external_payee_tab_type (1).default_pmt_method := 'CHECK';
      p_external_payee_tab_type (1).payment_function := 'PAYABLES_DISB';
      p_external_payee_tab_type (1).exclusive_pay_flag := 'N';
      p_external_payee_tab_type (1).payee_party_id :=12234;
      p_external_payee_tab_type (1).Delivery_Channel:='CRDB';
      p_external_payee_tab_type (1).payer_org_id := 115;
      p_external_payee_tab_type (1).payer_org_type := 'OPERATING_UNIT';
      p_external_payee_tab_type (1).supplier_site_id :=33444;
      p_external_payee_tab_type (1).Payee_Party_Site_Id :=45555;
      p_ext_payee_id_tab_type (1).ext_payee_id :=3456;
      
      iby_disbursement_setup_pub.update_external_payee (
         p_api_version            => 1.0,
         p_init_msg_list          => 'T',
         p_ext_payee_tab          => p_external_payee_tab_type,
         p_ext_payee_id_tab       => p_ext_payee_id_tab_type,
         x_return_status          => x_return_status,
         x_msg_count              => x_msg_count,
         x_msg_data               => x_msg_data,
         x_ext_payee_status_tab   => l_payee_upd_status
      );

      COMMIT;
    --  DBMS_OUTPUT.PUT_LINE ('External Payee Update :' || j.ext_payee_id);
      DBMS_OUTPUT.PUT_LINE ('x_return_status: ' || x_return_status);

      IF x_return_status = 'E'
      THEN
         FOR k IN l_payee_upd_status.FIRST .. l_payee_upd_status.LAST
         LOOP
            DBMS_OUTPUT.put_line('Error Message from table type : '
                                 || l_payee_upd_status (k).Payee_update_Msg);
         END LOOP;
      END IF;
      COMMIT;
     END LOOP;

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

API to update supplier payment method in r12
API to update supplier payment method in r12

Contact us for any Collaboration, Project Support & On Job Support Work

Name

Email *

Message *