The following lines contain the word 'select', 'insert', 'update' or 'delete':
select fiscal_year, period_num
into l_prorate_fy, l_start_per_num
from fa_deprn_periods
where period_counter = px_asset_fin_rec_new.extended_depreciation_period
and book_type_code = p_asset_hdr_rec.book_type_code;
select fc.period_num
, ffy.fiscal_year
into l_start_per_num
, l_prorate_fy
from fa_calendar_periods fc
, fa_book_controls fb
, fa_fiscal_year ffy
, fa_calendar_types fct
where fc.calendar_type = fb.deprn_calendar
and fb.book_type_code = p_asset_hdr_rec.book_type_code
and ffy.fiscal_year_name = fb.fiscal_year_name
and ffy.fiscal_year_name = fct.fiscal_year_name
and fc.calendar_type = fct.calendar_type
and fct.calendar_type = fb.deprn_calendar
and fc.start_date >= ffy.start_date
and fc.end_date <= ffy.end_date
and (ffy.fiscal_year * fct.number_per_fiscal_year + fc.period_num) =
px_asset_fin_rec_new.extended_depreciation_period;
select bk_old.adjusted_cost
from fa_books bk_old
, fa_books bk_extnd
where bk_old.book_type_code = p_book_type_code
and bk_old.asset_id = p_asset_id
and bk_old.extended_depreciation_period is null
and bk_extnd.book_type_code = p_book_type_code
and bk_extnd.asset_id = p_asset_id
and bk_extnd.extended_depreciation_period is not null
and bk_extnd.transaction_header_id_in = bk_old.transaction_header_id_out
order by bk_extnd.transaction_header_id_in desc;
l_dpr.update_override_status := TRUE;