DBA Data[Home] [Help]

APPS.ARP_TAX_RATE_UPD SQL Statements

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

Line: 6

PROCEDURE  update_tax_rate( errbuf        OUT NOCOPY   VARCHAR2,
                            retcode       OUT NOCOPY   VARCHAR2,
                            p_batch_size  IN NUMBER,
                            p_worker_id   IN NUMBER,
                            p_num_workers IN NUMBER  ) IS

  l_limit_rows      number ;
Line: 21

  l_update_name     varchar2(30);
Line: 31

     l_update_name     := 'ar3294352.sql';
Line: 52

         select count(*) into ln_cnt  from ar_system_parameters_all
         where TAX_DATABASE_VIEW_SET in ('_V','_A')
         and nvl(global_attribute17,'XXXXXX')  not in ('EFF_RATE_ENH','EFF_RATE_RUN');
Line: 55

         fnd_file.put_line( fnd_file.log,'Running Tax Rate update program in '||ln_cnt|| ' operating units.');
Line: 75

       update ar_system_parameters_all p
         set global_attribute17='EFF_RATE_RUN'
         where  TAX_DATABASE_VIEW_SET in ('_V','_A');
Line: 85

  ad_parallel_updates_pkg.initialize_rowid_range(
           ad_parallel_updates_pkg.ROWID_RANGE,
           l_table_owner,
           l_table_name,
           l_update_name,
           l_worker_id,
           l_num_workers,
           l_batch_size, 0);
Line: 96

  ad_parallel_updates_pkg.get_rowid_range(
           l_start_rowid,
           l_end_rowid,
           l_any_rows_to_process,
           l_batch_size,
           TRUE);
Line: 106

    update /*+ rowid(t) */ ra_customer_trx_lines_all t
        set global_attribute17 = t.tax_rate,
            tax_rate = ( select round (100 * t.extended_amount /
                   l.extended_amount,2)
              from ra_customer_trx_lines_all l
              where  l.customer_trx_line_id = t.link_to_cust_trx_line_id
               and l.line_type = 'LINE'
               and l.extended_amount <> 0),
                   last_update_date = to_date(sysdate, 'DD/MM/YYYY'),
                 last_updated_by = 1
      where t.line_type = 'TAX'
        and t.global_attribute17 is null
        and t.global_attribute_category in ('VERTEX', 'AVP')
        and t.rowid between l_start_rowid and l_end_rowid;
Line: 129

    ad_parallel_updates_pkg.processed_rowid_range(
                       l_rows_processed,
                       l_end_rowid);
Line: 139

    ad_parallel_updates_pkg.get_rowid_range(
                       l_start_rowid,
                       l_end_rowid,
                       l_any_rows_to_process,
                       l_batch_size,
                       FALSE);
Line: 151

           update ar_system_parameters_all set global_attribute17='EFF_RATE_ENH'
            where  TAX_DATABASE_VIEW_SET in ('_V','_A')
            and global_attribute17 = 'EFF_RATE_RUN';
Line: 181

END update_tax_rate;