20: v_from_counter fa_deprn_periods.period_counter%type;
21: v_from_cal_date fa_deprn_periods.calendar_period_open_date%type;
22: v_to_date fa_deprn_periods.period_close_date%type;
23: v_to_counter fa_deprn_periods.period_counter%type;
24: v_col1 fnd_id_flex_segments.application_column_name%type;
25: v_col2 fnd_id_flex_segments.application_column_name%type;
26:
27: CURSOR C_Get_First_Category IS
28: SELECT B.Category_id
21: v_from_cal_date fa_deprn_periods.calendar_period_open_date%type;
22: v_to_date fa_deprn_periods.period_close_date%type;
23: v_to_counter fa_deprn_periods.period_counter%type;
24: v_col1 fnd_id_flex_segments.application_column_name%type;
25: v_col2 fnd_id_flex_segments.application_column_name%type;
26:
27: CURSOR C_Get_First_Category IS
28: SELECT B.Category_id
29: FROM FA_Categories_B B,
43: C.SEGMENT3, 'SEGMENT2', C.SEGMENT2, 'SEGMENT1', C.SEGMENT1,
44: ' '))
45: FROM fa_categories C,
46: fnd_id_flexs flexid,
47: fnd_id_flex_segments flex1,
48: fnd_id_flex_segments flex2
49: WHERE C.Category_id = nvl(C_category_id,C_first_category)
50: and flexid.application_id = 140
51: and flexid.id_flex_code = 'CAT#'
44: ' '))
45: FROM fa_categories C,
46: fnd_id_flexs flexid,
47: fnd_id_flex_segments flex1,
48: fnd_id_flex_segments flex2
49: WHERE C.Category_id = nvl(C_category_id,C_first_category)
50: and flexid.application_id = 140
51: and flexid.id_flex_code = 'CAT#'
52: and flex1.id_flex_code = flexid.id_flex_code
74: nvl(flex2.application_column_name, ' ')
75: from fa_deprn_periods dp1,
76: fa_deprn_periods dp2,
77: fnd_id_flexs flexid,
78: fnd_id_flex_segments flex1,
79: fnd_id_flex_segments flex2
80: where dp1.book_type_code = C_book_type_code
81: and dp1.period_name = C_from_period
82: and dp2.book_type_code = dp1.book_type_code
75: from fa_deprn_periods dp1,
76: fa_deprn_periods dp2,
77: fnd_id_flexs flexid,
78: fnd_id_flex_segments flex1,
79: fnd_id_flex_segments flex2
80: where dp1.book_type_code = C_book_type_code
81: and dp1.period_name = C_from_period
82: and dp2.book_type_code = dp1.book_type_code
83: and dp2.period_name = C_to_period