DBA Data[Home] [Help]

APPS.FA_ASSET_TRACE_PKG SQL Statements

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

Line: 112

   SELECT OWNER||'.'||OBJECT_NAME
   FROM   DBA_OBJECTS OBJ, USER_SYNONYMS SYN
   WHERE OBJ.OBJECT_NAME = UPPER('GAT_message_type')
   AND OBJ.OBJECT_TYPE = 'TYPE'
   AND SYN.SYNONYM_NAME = OBJ.OBJECT_NAME
   AND OBJ.OWNER        =  SYN.TABLE_OWNER
   AND obj.object_name = syn.table_name;
Line: 200

     SELECT asset_number
     INTO g_asset_number
     FROM fa_additions_b
     where asset_id = g_asset_id;
Line: 207

        SELECT asset_id
          INTO l_asset_id
          FROM fa_additions_b
         WHERE asset_number = p_asset_number;
Line: 214

        SELECT count(*)
          INTO l_count
          FROM fa_books
         WHERE asset_id = g_asset_id
           AND book_type_code = g_book;
Line: 303

   select release_name
   into l_app_version
   from fnd_product_groups;
Line: 444

   select count(1)
   into l_check_reval
   from fa_transaction_headers
   where transaction_type_code = 'REVALUATION'
   and asset_id = g_asset_id
   and book_type_code = g_book;
Line: 453

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 457

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 460

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 471

   l_options_tbl(l_idx).l_cnt_stmt      := 'SELECT count(1) FROM FA_TRANSACTION_HEADERS'
    ||' WHERE asset_id = '||g_asset_id||' and book_type_code in ('||''''||g_source_book||''''||','||''''||g_book||''''||')';
Line: 475

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 478

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 488

   l_options_tbl(l_idx).l_cnt_stmt      := 'SELECT count(1) FROM FA_DISTRIBUTION_HISTORY'
    ||' WHERE asset_id = '||g_asset_id||' and book_type_code = '||''''||g_source_book||'''';
Line: 492

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 502

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 514

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 519

       ||' and mass_reval_id in (select mass_transaction_id from fa_transaction_headers where transaction_type_code = ''REVALUATION'''
	   ||' and asset_id = '||g_asset_id||' and book_type_code = '||'''' || g_book || ''''||')';
Line: 521

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 524

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 529

       ||' and mass_reval_id in (select mass_transaction_id from fa_transaction_headers where transaction_type_code = ''REVALUATION'''
	   ||' and asset_id = '||g_asset_id||' and book_type_code = '||'''' || g_book || ''''||')';
Line: 531

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 535

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 547

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 559

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 562

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 571

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 580

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 589

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 598

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 608

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 617

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 627

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 636

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 644

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 652

   l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 655

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 663

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 672

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 682

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 692

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 701

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 710

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 717

   l_options_tbl(l_idx).l_cnt_stmt     := 'SELECT count(it.invoice_transaction_id) FROM FA_INVOICE_TRANSACTIONS it, fa_asset_invoices ai'
     ||' where ai.asset_id = ' || g_asset_id ||' and (ai.invoice_transaction_id_in = it.invoice_transaction_id '
     ||' or ai.invoice_transaction_id_out = it.invoice_transaction_id)';
Line: 722

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 729

   l_options_tbl(l_idx).l_cnt_stmt     := 'SELECT count(1) FROM FA_TRX_REFERENCES WHERE book_type_code = '||''''||g_book||''''
     ||' and (member_asset_id = '||g_asset_id||' or src_asset_id = '||g_asset_id||' or dest_asset_id = '||g_asset_id||')';
Line: 731

   l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 734

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 771

     g_options_tbl.delete;
Line: 809

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 820

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 831

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 840

   l_options_tbl(l_idx).l_cnt_stmt     := 'SELECT count(*) FROM fa_mass_additions WHERE asset_number = '
     ||''''||g_asset_number||'''' ||' OR add_to_asset_id = '||g_asset_id;
Line: 844

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 850

   l_options_tbl(l_idx).l_add_clause   := ' FROM FA_MASSADD_DISTRIBUTIONS WHERE mass_addition_id IN (SELECT mass_addition_id FROM '
     ||'fa_mass_additions WHERE asset_number =' ||''''||g_asset_number||''''||')';
Line: 852

   l_options_tbl(l_idx).l_cnt_stmt     := 'SELECT count(*) FROM fa_mass_additions WHERE asset_number = '
     ||''''||g_asset_number||'''' ||' OR add_to_asset_id = '||g_asset_id;
Line: 856

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 862

   l_options_tbl(l_idx).l_add_clause   := ' FROM FA_MC_MASS_RATES WHERE mass_addition_id IN (SELECT mass_addition_id FROM fa_mass_additions '
     ||'WHERE asset_number =' ||''''||g_asset_number||''''||')';
Line: 864

   l_options_tbl(l_idx).l_cnt_stmt     := 'SELECT count(*) FROM fa_mass_additions WHERE asset_number = '
     ||''''||g_asset_number||'''' ||' OR add_to_asset_id = '||g_asset_id;
Line: 868

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 872

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 876

   l_options_tbl(l_idx).l_gen_select    := 'Y';
Line: 886

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 890

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 895

   l_options_tbl(l_idx).l_add_clause   := ' FROM FA_CATEGORIES_B WHERE category_id IN (SELECT DISTINCT ah.category_id FROM fa_asset_history ah'
     ||' WHERE ah.asset_id = '||g_asset_id|| ') ORDER BY category_id';
Line: 899

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 904

   l_options_tbl(l_idx).l_add_clause   := ' FROM FA_CATEGORIES_TL WHERE category_id IN (SELECT DISTINCT ah.category_id FROM fa_asset_history ah'
     ||' WHERE ah.asset_id = '||g_asset_id|| ') ORDER BY category_id';
Line: 908

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 913

   l_options_tbl(l_idx).l_add_clause   := ' FROM fa_category_books WHERE category_id IN (SELECT DISTINCT ah.category_id FROM fa_asset_history ah'
	 ||' WHERE ah.asset_id = '||g_asset_id|| ') AND book_type_code = '||''''||g_book||'''' ||' ORDER BY category_id';
Line: 917

   l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 922

   l_options_tbl(l_idx).l_add_clause   := ' FROM fa_category_book_defaults WHERE category_id IN (SELECT DISTINCT ah.category_id '
     ||'FROM fa_asset_history ah WHERE ah.asset_id = '||g_asset_id||') AND book_type_code = '||''''||g_book||''''
	 ||' ORDER BY category_id, start_dpis';
Line: 949

   l_select_clause   varchar2(2000);
Line: 962

      SELECT APPLICATION_COLUMN_NAME, SEGMENT_NAME
      from fnd_id_flex_segments
      where application_id = 101
      and id_flex_code = 'GL#'
      AND ID_FLEX_NUM = l_flex_num;
Line: 1072

      l_select_clause := l_select_clause||','||l_dist_tbl(i);
Line: 1075

   l_select_clause := substr(l_select_clause,2,length(l_select_clause));
Line: 1079

     fa_debug_pkg.add(l_calling_fn, 'l_select_clause', l_select_clause,
                               p_log_level_rec => p_log_level_rec);
Line: 1098

     l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1100

     l_options_tbl(l_idx).l_col_order    := l_select_clause;
Line: 1106

             (SELECT '||l_tbl_cols(i).cCol||' from fa_category_books where book_type_code = '||''''||g_book||'''' ||
                ' and category_id in (SELECT DISTINCT ah.category_id FROM fa_asset_history ah
                WHERE ah.asset_id = '||g_asset_id||')) ORDER BY code_combination_id';
Line: 1109

       l_stmt := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1112

             (SELECT distinct code_combination_id from fa_adjustments where book_type_code = '||''''||g_book||''''||
              ' and asset_id = '||g_asset_id||' and code_combination_id is not null) ORDER BY code_combination_id';
Line: 1114

       l_stmt := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1117

             (select distinct code_combination_id from XLA_AE_LINES where application_id in (140,'||l_appid||') and ae_header_id in
             (select ae_header_id from xla_ae_headers where application_id in (140,'||l_appid||') and event_id '||get_event_list
             ||')) ORDER BY code_combination_id';
Line: 1120

       l_stmt := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1123

             (SELECT code_combination_id FROM fa_distribution_history
              WHERE asset_id = '||g_asset_id||' AND transaction_header_id_out IS NULL) ORDER BY code_combination_id';
Line: 1125

       l_stmt := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1128

             (SELECT FLEXBUILDER_DEFAULTS_CCID FROM fa_book_controls WHERE book_type_code = '||''''||g_book||''''||')';
Line: 1129

       l_stmt := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1135

             ' and fda.distribution_id IN (SELECT distribution_id FROM fa_distribution_history WHERE asset_id = '||g_asset_id||')
              ORDER BY code_combination_id';
Line: 1137

       l_stmt := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1142

       l_options_tbl.delete(l_idx);
Line: 1149

   l_dist_tbl.delete;
Line: 1158

   l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1163

      ||',SETS.SECURITY_ENABLED_FLAG,STRU.FREEZE_FLEX_DEFINITION_FLAG,STRU.DYNAMIC_INSERTS_ALLOWED_FLAG,STRU.CROSS_SEGMENT_VALIDATION_FLAG';
Line: 1196

   l_select_clause         varchar2(4000);
Line: 1219

   l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1231

   l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1238

     ' AND (CO.PRORATE_CONVENTION_CODE IN (select distinct PRORATE_CONVENTION_CODE from fa_books '||
     ' where asset_id = '||g_asset_id||' and book_type_code = '||'''' || g_book || ''''||') '||
     ' OR CO.PRORATE_CONVENTION_CODE in (select distinct RETIREMENT_PRORATE_CONVENTION from fa_retirements '||
     ' where asset_id = '||g_asset_id|| ' and book_type_code = '||'''' || g_book || ''''||')) '||
     ' AND CO.START_DATE BETWEEN FY.START_DATE AND FY.END_DATE '||
	 ' AND CO.PRORATE_CONVENTION_CODE = CT.PRORATE_CONVENTION_CODE ORDER BY CT.PRORATE_CONVENTION_CODE, CO.START_DATE';
Line: 1246

   l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1250

     ' where BR.BONUS_RULE=BRL.BONUS_RULE and BR.BONUS_RULE IN (select distinct BONUS_RULE from fa_books '||
     ' where asset_id = '||g_asset_id||' and book_type_code = '||'''' || g_book || ''''||') '||
     ' order by BR.Bonus_Rule,BR.Start_Year';
Line: 1253

   l_options_tbl(l_idx).l_cnt_stmt     := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1256

   l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1261

     ||' WHERE cl.ceiling_name = ct.ceiling_name AND (cl.ceiling_name in (select distinct Ceiling_Name '||
     ' from fa_books where asset_id = '||g_asset_id||' and book_type_code = '||'''' || g_book || ''''||') '
     ||' OR  cl.ceiling_name in (select Ceiling_Name from fa_category_book_defaults '||
     ' where category_id in (SELECT DISTINCT ah.category_id FROM fa_asset_history ah '||
     ' WHERE ah.asset_id = '||g_asset_id|| ') and book_type_code = '||'''' || g_book || ''''||'))';
Line: 1266

   l_options_tbl(l_idx).l_cnt_stmt     := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1269

   l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1278

   l_options_tbl(l_idx).l_cnt_stmt     := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1288

     ||' IN (select DEPRN_METHOD_CODE||to_char(nvl(LIFE_IN_MONTHS,99999)) from fa_books'
     ||' where book_type_code = '||'''' || g_book || ''''||' and asset_id = '||g_asset_id||')';
Line: 1292

   l_options_tbl(l_idx).l_add_clause   := ' FROM fa_deprn_basis_rules WHERE deprn_basis_rule_id IN (SELECT deprn_basis_rule_id'
     ||' FROM fa_methods WHERE METHOD_CODE||to_char(nvl(LIFE_IN_MONTHS,99999)) IN '
	 ||'(select DEPRN_METHOD_CODE||to_char(nvl(LIFE_IN_MONTHS,99999)) from fa_books where book_type_code = '
	 ||'''' || g_book || ''''||' and asset_id = '||g_asset_id||'))';
Line: 1296

   l_options_tbl(l_idx).l_cnt_stmt     := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1300

     ||'(SELECT to_char(mt.method_id) || to_char(basic_rate) FROM FA_METHODS mt, fa_books bk '
     ||'where mt.method_code = bk.deprn_method_code and nvl(mt.life_in_months,0) = nvl(bk.life_in_months,0) '
     ||'and bk.book_type_code = '||'''' || g_book || ''''||' and bk.asset_id = '||g_asset_id||')';
Line: 1303

   l_options_tbl(l_idx).l_cnt_stmt     := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1315

   l_options_tbl(l_idx).l_add_clause   := ' From fa_formulas Where method_id in (SELECT mt.method_id '
     ||'FROM FA_METHODS mt, fa_books bk where mt.method_code = bk.deprn_method_code '
	 ||'and nvl(mt.life_in_months,0) = nvl(bk.life_in_months,0) and bk.book_type_code = '||'''' || g_book || ''''
	 ||' and bk.asset_id = '||g_asset_id||')';
Line: 1319

   l_options_tbl(l_idx).l_cnt_stmt     := 'select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1352

  l_event_list := l_event_list|| 'select ev.event_id
    from fa_transaction_headers th, xla_transaction_entities en, xla_events ev
    where th.book_type_code = '||'''' || g_book || ''''||
    ' and th.asset_id = '||g_asset_id||
    ' and en.application_id  in ('||l_appid||',140)
    and en.ledger_id = '||g_sob_id||
    ' and en.entity_code in (''MANUAL'', ''TRANSACTIONS'')
    and nvl(en.source_id_int_1, (-99)) = th.transaction_header_id
    and en.valuation_method = '||'''' || g_book || ''''||
    ' and ev.application_id in ('||l_appid||',140)
    and ev.entity_id = en.entity_id
    union
    select ev.event_id
    from fa_transaction_headers th, xla_transaction_entities en, xla_events ev
    where th.book_type_code = '||'''' || g_source_book || ''''||
    ' and th.asset_id = '||g_asset_id||
    ' and th.transaction_type_code in (''REINSTATEMENT'')
    and en.application_id in ('||l_appid||',140)
    and en.ledger_id = '||g_sob_id||
    ' and en.entity_code in (''TRANSACTIONS'')
    and nvl(en.source_id_int_1, (-99)) = th.transaction_header_id
    and en.valuation_method = '||'''' || g_book || ''''||
    ' and en.valuation_method <> '||'''' || g_source_book || ''''||
    ' and ev.application_id in ('||l_appid||',140)
    and ev.entity_id = en.entity_id
    union
    select ev.event_id
    from fa_transaction_headers th, xla_transaction_entities en, xla_events ev
    where th.book_type_code = '||'''' || g_source_book || ''''||
    ' and th.asset_id = '||g_asset_id||
    ' and th.transaction_type_code in (''UNIT ADJUSTMENT'',''TRANSFER OUT'',''TRANSFER'',''RECLASS'')
    and en.application_id in ('||l_appid||',140)
    and en.ledger_id = '||g_sob_id||
    ' and en.entity_code in (''MANUAL'', ''TRANSACTIONS'')
    and nvl(en.source_id_int_1, (-99)) = th.transaction_header_id
    and en.valuation_method = '||'''' || g_book || ''''||
    ' and ev.application_id in ('||l_appid||',140)
    and ev.entity_id = en.entity_id
    union
    select ev.event_id
    from fa_transaction_headers th, xla_transaction_entities en, xla_events ev
    where th.book_type_code = '||'''' || g_book || ''''||
    ' and th.asset_id = '||g_asset_id||
    ' and en.application_id in ('||l_appid||',140)
    and en.ledger_id = '||g_sob_id||
    ' and en.entity_code in (''MANUAL'', ''INTER_ASSET_TRANSACTIONS'')
    and nvl(en.source_id_int_1, (-99)) = th.trx_reference_id
    and ev.application_id in ('||l_appid||',140)
    and ev.entity_id = en.entity_id
    union
    select ev.event_id
    from xla_transaction_entities en, xla_events ev, fa_book_controls bc
    where bc.book_type_code = '||'''' || g_book || ''''||
    ' and en.application_id in ('||l_appid||',140)
    and en.ledger_id = '||g_sob_id||
    ' and en.entity_code in (''MANUAL'', ''DEPRECIATION'',''DEFERRED_DEPRECIATION'')
    and nvl(en.source_id_int_1, (-99)) = '||g_asset_id||
    ' and nvl(en.source_id_char_1, '''')   = bc.book_type_code
    and ev.application_id in ('||l_appid||',140)
    and ev.entity_id = en.entity_id ) ' ;
Line: 1458

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1465

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1469

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1476

           ||' and entity_id in (select entity_id from xla_events where event_id '||l_event_list||')';
Line: 1477

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1481

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1487

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1490

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1494

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1501

           ||' and ae_header_id in (select ae_header_id from xla_ae_headers where application_id in (140,'||l_appid||') and event_id '||l_event_list||')';
Line: 1502

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1506

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1512

           ||'(SELECT ae_header_id FROM xla_ae_headers WHERE application_id in (140,'||l_appid||') AND event_id '||l_event_list||' )';
Line: 1513

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1517

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1523

        '(select SLA_ACCOUNTING_METHOD_CODE from gl_ledgers where ledger_id = '||g_sob_id||')';
Line: 1524

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1528

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1534

        '(select distinct product_rule_code from xla_ae_headers where application_id in (140,'||l_appid||') and event_id '||l_event_list||')';
Line: 1535

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1539

     l_options_tbl(l_idx).l_gen_select   := 'Y';
Line: 1544

     l_options_tbl(l_idx).l_add_clause   := ' from xla_ledger_options where (ledger_id = '||g_sob_id||' or ledger_id in (select target_ledger_id '||
        ' FROM gl_ledger_relationships WHERE primary_ledger_id = '||g_sob_id||' AND relationship_type_code <> ''NONE'' '||
        ' AND application_id IN (101,140) AND relationship_enabled_flag = ''Y'')) and application_id IN (101,140) order by APPLICATION_ID, LEDGER_ID';
Line: 1547

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1551

     l_options_tbl(l_idx).l_gen_select   := 'N';
Line: 1558

     l_options_tbl(l_idx).l_add_clause   := ' from gl_ledgers where ledger_id = '||g_sob_id||' or ledger_id in (select target_ledger_id '||
        ' FROM gl_ledger_relationships WHERE primary_ledger_id = '||g_sob_id||' AND relationship_type_code <> ''NONE'' '||
        ' AND application_id IN (101,140) AND relationship_enabled_flag = ''Y'') order by ledger_id';
Line: 1561

     l_options_tbl(l_idx).l_cnt_stmt     := 'Select count(1) '||l_options_tbl(l_idx).l_add_clause;
Line: 1564

     l_idx:= l_idx+ 1;   l_col_exclusions(l_idx).cValue  := 'LAST_UPDATE_LOGIN';
Line: 1798

    log('prt_opt_tbl',p_options_tbl(i).l_gen_select);