API to Update an Internal Bank in R12

Script for to update an Internal Bank in Oracle Apps R12.1.1.


API USED: CE_BANK_PUB.UPDATE_BANK

SET SERVEROUTPUT ON;

DECLARE
   p_init_msg_list           VARCHAR2 (200);
   p_bank_id                 NUMBER;
   p_bank_name               VARCHAR2 (200);
   p_bank_number             VARCHAR2 (200);
   p_alternate_bank_name     VARCHAR2 (200);
   p_short_bank_name         VARCHAR2 (200);
   p_description             VARCHAR2 (200);
   p_object_version_number   NUMBER;
   x_return_status           VARCHAR2 (200);
   x_msg_count               NUMBER;
   x_msg_data                VARCHAR2 (200);
   p_count                   NUMBER;
BEGIN
   p_init_msg_list := fnd_api.g_true;
   p_bank_id := 1147;
   p_bank_name := 'test bank2';
   p_bank_number := 3933;
   p_alternate_bank_name := 'Alternate Test Bank2';
   p_short_bank_name := 'IDF';
   p_description := 'Test Bank2 Description';
   p_object_version_number := 1;
   ce_bank_pub.update_bank
                         (p_init_msg_list              => p_init_msg_list,
                          p_bank_id                    => p_bank_id,
                          p_bank_name                  => p_bank_name,
                          p_bank_number                => p_bank_number,
                          p_alternate_bank_name        => p_alternate_bank_name,
                          p_short_bank_name            => p_short_bank_name,
                          p_description                => p_description,
                          p_object_version_number      => p_object_version_number,
                          x_return_status              => x_return_status,
                          x_msg_count                  => x_msg_count,
                          x_msg_data                   => x_msg_data
                         );
   DBMS_OUTPUT.put_line (   'P_OBJECT_VERSION_NUMBER = '
                         || p_object_version_number
                        );
   DBMS_OUTPUT.put_line ('X_RETURN_STATUS = ' || x_return_status);
   DBMS_OUTPUT.put_line ('X_MSG_COUNT = ' || x_msg_count);
   DBMS_OUTPUT.put_line ('X_MSG_DATA = ' || x_msg_data);

   IF x_msg_count = 1
   THEN
      DBMS_OUTPUT.put_line ('x_msg_data ' || x_msg_data);
   ELSIF x_msg_count > 1
   THEN
      LOOP
         p_count := p_count + 1;
         x_msg_data := fnd_msg_pub.get (fnd_msg_pub.g_next, fnd_api.g_false);

         IF x_msg_data IS NULL
         THEN
            EXIT;
         END IF;

         DBMS_OUTPUT.put_line ('Message' || p_count || ' ---' || x_msg_data);
      END LOOP;
   END IF;

END;
/


No comments:

Post a Comment

How to find all cancel Requisitions

SELECT prha . *   FROM po_Requisition_headers_all prha , po_action_history pah   WHERE      1 = 1        AND pah . object_id ...