DBA Data[Home] [Help]

APPS.PO_MASS_UPDATE SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 39

/* Bug#2718220 Added the REJECTED status also so that the Program will update
** all the Documents with REJECTED also apart from APPROVED,REQUIRES REAPPROVAL
** and INCOMPLETE statuses.
*/

cursor c_rel is
select por.rowid,
       poh.segment1,
       por.release_num,
       pdt.type_name,
       por.po_release_id--8551445
from po_releases por,
     po_headers poh,
     po_document_types_vl pdt
where por.po_header_id = poh.po_header_id
and por.agent_id = x_old_buyer_id
and nvl(por.authorization_status,'INCOMPLETE') in ('APPROVED','REQUIRES REAPPROVAL','INCOMPLETE','REJECTED')
and nvl(por.closed_code,'OPEN') not in ('CLOSED','FINALLY CLOSED')
and nvl(por.cancel_flag,'N') = 'N'
and nvl(por.frozen_flag,'N') = 'N'
and pdt.document_type_code ='RELEASE'
and pdt.document_subtype = por.release_type
order by poh.segment1,por.release_num;
Line: 92

l_api_name VARCHAR2(30) := 'po_update_buyer';
Line: 129

    select org_id
    into x_org_id
    from po_system_parameters;
Line: 134

    select hou.name
    into x_org_name
    from hr_all_organization_units hou,
         hr_all_organization_units_tl hout
    where hou.organization_id = hout.organization_id
    and hout.language = userenv('LANG')
    and hou.organization_id = x_org_id;
Line: 175

  *     Mass Update of Buyer Name on Purchasing Documents Report *
  *                                                              *
  *   DATE                   :  DD-MON-YYYY                      *
  *   OPERATING UNIT         :  Vision Operations                *
  *   OLD BUYER              :  Green, Terry                     *
  *   NEW BUYER              :  Stock, Pat                       *
  *                                                              *
  *  The Buyer was updated on the following Documents.           *
  *  Document Number        Document Type                        *
  *  ------------------------------------------------            *
  *  1234                   Standard Purchase Order              *
  *  1222                   Blanket Agreement                    *
  *  1222-1                 Blanket Release                      *
  *  .....                  ......                               *
  *--------------------------------------------------------------*/

     fnd_file.put_line(fnd_file.output, x_msg1);
Line: 222

 /* Update all the fetched PO documents with the new buyer */
    x_progress := '003';
Line: 225

/* Bug#3082301 Added the WHO columns to the below update statement so that
** Mass Update Buyer Name Program will update the WHO columns also on all
** Purchasing Documents(POs) which are effected by the program.
*/
         update po_headers_all
         set agent_id = x_new_buyer_id,
             last_update_date  = sysdate,
             last_updated_by   = fnd_global.user_id,
             last_update_login = fnd_global.login_id
         where rowid = x_po_rowid;
Line: 239

         UPDATE po_headers_archive_all
         SET  agent_id = x_new_buyer_id,
              last_update_date  = sysdate,
             last_updated_by   = fnd_global.user_id,
             last_update_login = fnd_global.login_id
         WHERE po_header_id=l_document_id
         AND   latest_external_flag= 'Y';
Line: 286

               okc_manage_deliverables_grp.updateIntContactOnDeliverables (
                   p_api_version                  => 1.0,
                   p_init_msg_list                => FND_API.G_FALSE,
                   p_commit                       => FND_API.G_FALSE,
                   p_bus_docs_tbl                 => l_busdocs_tbl,
                   p_original_internal_contact_id => x_old_buyer_id,
                   p_new_internal_contact_id      => x_new_buyer_id,
                   x_msg_data                     => l_msg_data,
                   x_msg_count                    => l_msg_count,
                   x_return_status                => l_return_status);
Line: 331

     okc_manage_deliverables_grp.updateIntContactOnDeliverables (
                   p_api_version                  => 1.0,
                   p_init_msg_list                => FND_API.G_FALSE,
                   p_commit                       => FND_API.G_FALSE,
                   p_bus_docs_tbl                 => l_busdocs_tbl,
                   p_original_internal_contact_id => x_old_buyer_id,
                   p_new_internal_contact_id      => x_new_buyer_id,
                   x_msg_data                     => l_msg_data,
                   x_msg_count                    => l_msg_count,
                   x_return_status                => l_return_status);
Line: 367

  /* Update all the fetched PO Release documents with the new buyer */
     x_progress := '006';
Line: 370

/* Bug#3082301 Added the WHO columns to the below update statement so that
** Mass Update Buyer Name Program will update the WHO columns also on all
** Purchasing Documents(Releases) which are effected by the program.
*/
         update po_releases_all
         set agent_id = x_new_buyer_id,
             last_update_date  = sysdate,
             last_updated_by   = fnd_global.user_id,
             last_update_login = fnd_global.login_id
         where rowid = x_rel_rowid;
Line: 383

         UPDATE po_releases_archive_all
         SET  agent_id = x_new_buyer_id,
              last_update_date  = sysdate,
             last_updated_by   = fnd_global.user_id,
             last_update_login = fnd_global.login_id
         WHERE po_release_id=l_document_id
         AND   latest_external_flag= 'Y';
Line: 435

         po_message_s.sql_error('po_update_buyer', x_progress, sqlcode);