Friday, 6 November 2015

iSupplier User Creation Script



DECLARE
   l_return_Status      VARCHAR2 (10);
   l_msg_count          NUMBER;
   l_msg_data           VARCHAR2 (1000);
   l_user_id            NUMBER;
   l_password           VARCHAR2 (100);
   l_resp_ids           po_tbl_number := po_tbl_number ();
   l_resp_app_ids       po_tbl_number := po_tbl_number ();
   l_sec_attr_numbers   po_tbl_number := po_tbl_number ();
   l_po_tbl_varchar30   po_tbl_varchar30 := po_tbl_varchar30 ();
BEGIN
   l_resp_ids.EXTEND;
   l_resp_app_ids.EXTEND;
   l_resp_ids (1) := 23075;
   l_resp_app_ids (1) := 177;
   l_po_tbl_varchar30.EXTEND;
   l_po_tbl_varchar30 (1) := 'ICX_SUPPLIER_ORG_ID';
   l_sec_attr_numbers.EXTEND;
   l_sec_attr_numbers (1) := '748046';
   pos_user_admin_pkg.create_supplier_user_account (
      p_user_name          => 'MYERPCIRCLES',
      p_user_email         => 'test123@erpcircles.com',
      p_person_party_id    => 4189720,
      p_resp_ids           => l_resp_ids,
      p_resp_app_ids       => l_resp_app_ids,
      p_sec_attr_codes     => l_po_tbl_varchar30,
      p_sec_attr_numbers   => l_sec_attr_numbers,
      p_password           => 'welcome',
      x_return_status      => l_return_Status,
      x_msg_count          => l_msg_count,
      x_msg_data           => l_msg_data,
      x_user_id            => l_user_id,
      x_password           => l_password);
   DBMS_OUTPUT.put_line (' User Id is : ' || l_user_id);
   DBMS_OUTPUT.put_line (' Message Count : ' || l_msg_count);
   DBMS_OUTPUT.put_line (' Message Data: ' || l_msg_data);
   DBMS_OUTPUT.put_line (' Return Status: ' || l_return_Status);
END;


COMMIT;