DBA Data[Home] [Help]

APPS.IGI_IAC_REVAL_CONCURRENT SQL Statements

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

Line: 37

    select revaluation_id, book_type_code, revaluation_period
    from   igi_iac_revaluations
    where  revaluation_id = p_revaluation_id
    ;
Line: 126

     select iir.revaluation_id, iir.book_type_code
     from   igi_iac_revaluations iir
     where  iir.revaluation_id = fp_revaluation_id
       and  iir.book_type_code = fp_book_type_code
       ;
Line: 135

     select category_id
     from   igi_iac_reval_categories
     where  revaluation_id = cp_revaluation_id
       and  book_type_code = cp_book_type_code
       and  nvl(select_category,'X') = 'Y';
Line: 145

       select ac.asset_id, ac.revaluation_type, ac.revaluation_factor, fadd.asset_number
       from   igi_iac_reval_asset_rules ac, fa_additions fadd
       where  ac.revaluation_id = cp_revaluation_id
         and  ac.book_type_code = cp_book_type_code
         and  ac.category_id    = cp_category_id
         and  ac.asset_id       = fadd.asset_id
         and  nvl(ac.selected_for_reval_flag,'X') = 'Y'
         and  exists ( select 1
                       from igi_iac_transaction_headers
                           where asset_id = ac.asset_id
                           and   book_type_code = ac.book_type_code
                           and  mass_reference_id = ac.revaluation_id
                           and  adjustment_status = 'PREVIEW'
             )
         ;
Line: 227

                if IGI_IAC_REVAL_CRUD.update_balances
                     ( fp_reval_id       => l_reval.revaluation_id
                     , fp_asset_id       => l_asset_id(l_loop_count)
                     , fp_period_counter => fp_period_counter
                     , fp_book_type_code => l_reval.book_type_code
                     )
                then
                   l_success_ct := l_success_ct + 1;
Line: 269

                     select adjustment_id
                     into   l_adjustment_id
                     from   igi_iac_transaction_headers
                     where  book_type_code = l_reval.book_type_code
                     and    asset_id       = l_asset_id(l_loop_count)
                     and    adjustment_id_out is null
                     ;
Line: 283

                     if not igi_iac_reval_crud.update_reval_rates
                          ( fp_adjustment_id => l_adjustment_id )
                     then
                         l_failure_ct := l_failure_ct + 1;
Line: 347

           Following code will delete SLA event in case of failure*/
          if l_failure_ct = 0 and l_success_ct > 0 then
	         igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'Revaluation is complete...');
Line: 352

             If IGI_IAC_XLA_EVENTS_PKG.delete_revaluation_event(l_reval.revaluation_id) then
                igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'Event deleted successfully');
Line: 391

     select iir.revaluation_id, iir.book_type_code
     from   igi_iac_revaluations iir
     where  iir.revaluation_id = fp_revaluation_id
       and  iir.book_type_code = fp_book_type_code
--     and  upper(iir.status)  = IGI_IAC_TYPES.gc_previewed_status
       ;
Line: 401

     select category_id
     from   igi_iac_reval_categories
     where  revaluation_id = cp_revaluation_id
       and  book_type_code = cp_book_type_code
       and  nvl(select_category,'X') = 'Y'
       ;
Line: 413

       select r.asset_id, r.revaluation_type, r.revaluation_factor, fadd.asset_number
       from   igi_iac_reval_asset_rules r, fa_additions fadd
       where  r.revaluation_id = cp_revaluation_id
         and  r.book_type_code = cp_book_type_code
         and  r.category_id    = cp_category_id
         and  nvl(r.selected_for_reval_flag,'X') = 'Y'
         and  r.asset_id       = fadd.asset_id
         and not exists ( select 'x'
                          from igi_iac_transaction_headers
                          where asset_id = r.asset_id
                          and   book_type_code = r.book_type_code
                          and   mass_reference_id = r.revaluation_id
                          and   transaction_type_code = 'REVALUATION'
                        )
         ;
Line: 600

function preview_mode_hist_delete  ( fp_revaluation_id in number)
return   boolean is
     cursor c_reval_rates is
         select distinct asset_id, book_type_code, period_counter
         from   igi_iac_transaction_headers
         where  mass_reference_id    = fp_revaluation_id
           and  transaction_type_code = 'REVALUATION'
         ;
Line: 612

         select adjustment_id
         from   igi_iac_transaction_headers t
         where  book_type_code   = cp_book_type_code
           and  asset_id         = cp_asset_id
           and  transaction_type_code = 'REVALUATION'
           and  period_counter        = cp_period_counter
           and  mass_reference_id     = fp_revaluation_id
           and exists ( select 'x'
                        from igi_iac_reval_asset_rules
                        where asset_id = t.asset_id
                        and   book_type_code = t.book_type_code
                        and   revaluation_id = t.mass_reference_id
                        and   nvl(allow_prof_update,'X') = 'Y'
                      )
          ;
Line: 627

      l_delete_flag boolean;
Line: 632

      l_path  := g_path||'preview_mode_hist_delete';
Line: 634

   igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'Begin preview_mode_hist_delete');
Line: 636

       l_delete_flag := false;
Line: 644

          igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+delete from exceptions table');
Line: 645

          l_delete_flag := true;
Line: 646

          delete from igi_iac_exceptions
          where asset_id = l_rates.asset_id
          and   revaluation_id = fp_revaluation_id
          and   book_type_code = l_rates.book_type_code
          ;
Line: 651

          igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+delete from the transaction headers table');
Line: 652

          delete igi_iac_transaction_headers
          where  adjustment_id     = l_headers.adjustment_id
          and    adjustment_id_out is null
/*          and not exists ( select 'x'
                       from igi_iac_transaction_headers
                       where adjustment_id_out = l_headers.adjustment_id
                     )*/
          ;
Line: 665

          igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+update previous transaction row if one exists');
Line: 668

               select 'x'
               from  igi_iac_transaction_headers
               where adjustment_id_out = l_headers.adjustment_id
               ;
Line: 679

                  update igi_iac_transaction_headers
                  set    adjustment_id_out = null
                  where  adjustment_id_out = l_headers.adjustment_id
                  and    book_type_code    = l_rates.book_type_code
                  and    asset_id          = l_rates.asset_id
                  ;
Line: 692

          igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+delete from the adjustments table');
Line: 693

          delete igi_iac_adjustments
          where  adjustment_id     = l_headers.adjustment_id
          ;
Line: 697

             igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+deleted the iac adjustments');
Line: 700

           igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+delete from the det balances table');
Line: 701

          delete igi_iac_det_balances
          where  adjustment_id     = l_headers.adjustment_id
          ;
Line: 705

             igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+deleted the det balances info');
Line: 708

          igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+delete from the revaluation rates table');
Line: 709

          delete from igi_iac_revaluation_rates
          where  adjustment_id  = l_headers.adjustment_id
          ;
Line: 713

             igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'+deleted the revaluation rates info');
Line: 721

   if not l_delete_flag then
      igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'no preview_mode_hist_delete');
Line: 724

      igi_iac_debug_pkg.debug_other_string(g_state_level,l_path,'yes preview_mode_hist_delete');
Line: 739

      select distinct asset_id, book_type_code, period_counter
         from   igi_iac_transaction_headers
         where  mass_reference_id    = fp_revaluation_id
           and  transaction_type_code = 'REVALUATION'
           and  adjustment_status     = 'PREVIEW'
         ;
Line: 764

          select distinct asset_id, book_type_code, period_counter
         from   igi_iac_transaction_headers
         where  mass_reference_id    = fp_revaluation_id
           and  transaction_type_code = 'REVALUATION'
           and  adjustment_status     = 'RUN'
         ;
Line: 886

         preview_mode_hist_delete ( fp_revaluation_id => revaluation_id ) then
             if not preview_mode_hist_generate ( fp_revaluation_id => revaluation_id ,
                                                 fp_book_type_code => book_type_code ,
                                                 fp_period_counter => period_counter ,
                                                 fp_wait_request_id => create_request_id
                                               ) then
                rollback;