32: -- ====================================================================
33: PROCEDURE Recreate_Intf_Data(p_book_type_code VARCHAR2,
34: p_request_id NUMBER)
35: IS
36: CURSOR c_get_intf_data(cp_request_id igi_imp_iac_itf.request_id%TYPE,
37: cp_book_type_code igi_imp_iac_itf.book_type_code%TYPE)
38: IS
39: SELECT book_type_code,
40: request_id,
33: PROCEDURE Recreate_Intf_Data(p_book_type_code VARCHAR2,
34: p_request_id NUMBER)
35: IS
36: CURSOR c_get_intf_data(cp_request_id igi_imp_iac_itf.request_id%TYPE,
37: cp_book_type_code igi_imp_iac_itf.book_type_code%TYPE)
38: IS
39: SELECT book_type_code,
40: request_id,
41: functional_currency_code,
73: sum(HIST_COST),
74: sum(HIST_YTD_DEPRN),
75: sum(HIST_ACC_DEPRN),
76: sum(OPER_ACCT)
77: FROM igi_imp_iac_itf
78: WHERE request_id = cp_request_id
79: AND book_type_code = cp_book_type_code
80: GROUP BY book_type_code,
81: request_id,
240: l_hist_ytd_deprn,
241: l_hist_acc_deprn,
242: l_oper_acct;
243:
244: -- delete existing data in igi_imp_iac_itf
245: -- for request_id and book_type_code
246: DELETE FROM igi_imp_iac_itf
247: WHERE book_type_code = p_book_type_code
248: AND request_id = p_request_id;
242: l_oper_acct;
243:
244: -- delete existing data in igi_imp_iac_itf
245: -- for request_id and book_type_code
246: DELETE FROM igi_imp_iac_itf
247: WHERE book_type_code = p_book_type_code
248: AND request_id = p_request_id;
249:
250: -- insert the data back into the interface table
249:
250: -- insert the data back into the interface table
251:
252: FORALL j IN l_book_type_code.FIRST..l_book_type_code.LAST
253: INSERT INTO IGI_IMP_IAC_ITF( distribution_id ,
254: request_id ,
255: set_of_books_id ,
256: asset_id,
257: category_id,
1159: l_dist_source_book )) THEN
1160: null;
1161: END IF;
1162:
1163: INSERT INTO IGI_IMP_IAC_ITF( distribution_id ,
1164: request_id ,
1165: set_of_books_id ,
1166: asset_id,
1167: category_id,