The following lines contain the word 'select', 'insert', 'update' or 'delete':
l_TxnUpdatedByTab pa_utils.IdTabTyp ;
t_TxnUpdatedByTab pa_utils.IdTabTyp ;
select 1
from gl_code_combinations
where code_combination_id = p_ccid
and account_type = 'A' ;
select assets_tracking_flag
from ap_invoice_distributions_all
where invoice_distribution_id = p_related_id
and invoice_distribution_id <> related_id
and assets_tracking_flag = 'Y' ;
select assets_tracking_flag
from ap_invoice_distributions_all
where invoice_distribution_id = p_charge_appl_to_dist_id
and assets_tracking_flag = 'Y' ;
PROCEDURE Insert_Receipts(
P_acctg_date IN DATE,
P_ledger_id IN number,
P_user_id IN number,
P_request_id IN number,
P_bt_code IN varchar2,
P_primary_accounting_method IN varchar2,
P_calling_sequence IN varchar2 DEFAULT NULL) ;
PROCEDURE Insert_Mass( p_api_version IN number,
p_init_msg_list IN varchar2 default FND_API.G_FALSE,
p_commit IN varchar2 default FND_API.G_FALSE,
p_validation_level IN number default FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY varchar2,
x_msg_count OUT NOCOPY number,
x_msg_data OUT NOCOPY varchar2,
x_count OUT NOCOPY number,
P_acctg_date IN DATE,
P_ledger_id IN number,
P_user_id IN number,
P_request_id IN number,
P_bt_code IN varchar2,
P_primary_accounting_method IN varchar2,
P_calling_sequence IN varchar2 DEFAULT NULL) IS
--
lrec number ;
l_api_name CONSTANT varchar2(100) := 'PA INSERT_MASS';
select ei.expenditure_item_id,
ei.expenditure_item_date ,
cdl.line_num,
ei.document_header_id,
ei.document_distribution_id,
ei.document_payment_id,
ei.document_line_number,
ei.document_type,
ei.document_distribution_type,
ei.transaction_source,
rtrim(SUBSTRB(eic.expenditure_comment,1,80)) description,
(NVL(XDL.unrounded_accounted_dr,0) - NVL(XDL.unrounded_accounted_cr,0)) acct_raw_cost,
--cdl.acct_raw_cost acct_raw_cost,
cdl.gl_date,
cdl.acct_event_id,
cdl.quantity,
ei.net_zero_adjustment_flag,
ei.adjusted_expenditure_item_id,
ei.transferred_from_exp_item_id,
ei.vendor_id,
rtrim(POV.segment1) vendor_number,
apb.batch_name,
api.invoice_date,
api.created_by invoice_created_by,
api.last_updated_by invoice_updated_by,
api.invoice_id invoice_id,
api.source,
rtrim(api.invoice_num) invoice_num,
apil.warranty_number,
apil.manufacturer,
apil.serial_number,
apil.model_number,
decode(apd.line_type_lookup_code, 'ITEM', 'PA-ADJ', apd.line_type_lookup_code) line_type_lookup_code,
apd.po_distribution_id,
apd.related_id,
apd.distribution_line_number,
apd.invoice_distribution_id,
apd.dist_code_combination_id,
apd.invoice_line_number ,
decode(cdl.reversed_flag, NULL, NULL,
( select cdl2.si_assets_addition_flag
from pa_cost_distribution_lines_all cdl2
where cdl2.expenditure_item_id = cdl.expenditure_item_id
and cdl2.line_num_reversed = cdl.line_num ) ) reversed_assets_flag,
decode(cdl.line_num_reversed, NULL, NULL,
( select cdl2.si_assets_addition_flag
from pa_cost_distribution_lines_all cdl2
where cdl2.expenditure_item_id = cdl.expenditure_item_id
and cdl2.line_num = cdl.line_num_reversed ) ) source_assets_flag,
DECODE(apd.line_type_lookup_code,
'ITEM', decode( apd.corrected_invoice_dist_id,
NULL,apd.invoice_distribution_id,
apd.corrected_invoice_dist_id),
'ACCRUAL',decode(apd.corrected_invoice_dist_id,
NULL, apd.invoice_distribution_id,
apd.corrected_invoice_dist_id),
'IPV', apd.related_id,
'ERV', apd.related_id, apd.charge_applicable_to_dist_id) parent_invoice_dist_id,
apd.assets_addition_flag ap_assets_addition_flag,
apd.dist_match_type,
glcc.account_type ,
xal.code_combination_id,
algt.ledger_category_code,
algt.ledger_id,
fsp.inventory_organization_id,
apd.assets_tracking_flag
from pa_expenditure_items ei,
pa_expenditure_comments eic,
pa_cost_distribution_lines cdl,
ap_invoices api,
ap_batches_all apb,
ap_invoice_lines apil,
ap_invoice_distributions apd,
financials_system_params_all fsp,
po_vendors pov,
xla_distribution_links xdl,
xla_ae_headers xah,
ap_alc_ledger_gt algt,
xla_ae_lines xal,
ap_acct_class_code_gt aagt,
gl_code_combinations glcc,
--
-- bug:4778189 - cross charge projects related transactions didn't generate assets.
--
pa_projects_all p,
pa_project_types_all pt
where ei.expenditure_item_id = cdl.expenditure_item_id
and cdl.expenditure_item_id = eic.expenditure_item_id (+)
and cdl.line_num = eic.line_number (+)
and ei.transaction_source in ('AP INVOICE' , 'AP EXPENSE', 'AP NRTAX', 'AP VARIANCE', 'AP ERV', /* Bug 5284323 */
'INTERPROJECT_AP_INVOICES','INTERCOMPANY_AP_INVOICES')
and cdl.gl_date <= P_acctg_date
and cdl.line_type = 'R'
and cdl.transfer_status_code = 'A'
and cdl.si_assets_addition_flag = 'T'
and cdl.project_id = p.project_id
and p.project_type = pt.project_type
-- Bug : 5368600
and p.org_id = pt.org_id
and pt.project_type_class_code <> 'CAPITAL'
and ei.document_header_id = api.invoice_id
and ei.document_distribution_id = apd.invoice_distribution_id
and ei.document_line_number = apd.invoice_line_number
and apil.invoice_id = api.invoice_id
and api.org_id = fsp.org_id
and apil.line_number = apd.invoice_line_number
and api.batch_id = apb.batch_id(+)
and apd.posted_flag = 'Y'
and api.vendor_id = pov.vendor_id
and apd.set_of_books_id = P_ledger_id
-- 5911379: Modified the join
AND xah.application_id = 275
and xah.event_id = cdl.acct_event_id
AND xah.balance_type_code = 'A'
and xah.accounting_entry_status_code = 'F'
and xal.application_id = xah.application_id
AND xal.ae_header_id = xah.ae_header_id
and xal.accounting_class_code = aagt.accounting_class_code
and xdl.event_id = xah.event_id
AND xdl.ae_header_id = xal.ae_header_id
AND xdl.ae_line_num = xal.ae_line_num
and xdl.application_id = xal.application_id
and xdl.source_distribution_id_num_1 = ei.expenditure_item_id
and xdl.source_distribution_id_num_2 = cdl.line_num
and xah.ledger_id = algt.ledger_id
and decode(algt.org_id, -99, algt.org_id, cdl.org_id) =
decode(algt.org_id, -99, -99, algt.org_id)
and glcc.code_combination_id = xal.code_combination_id
-- 5911379: ends
ORDER BY ei.document_distribution_id, ei.expenditure_item_id, cdl.line_num ;
'Insert_Mass';
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', '*** 10 : ORACLE PROJECTS INSERT MASS PROCESSING ***') ;
'INSERT_MASS',
G_pkg_name) THEN
RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'INSERT MASS Processing begins.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Calling Insert_Receipts processing.') ;
Insert_Receipts( P_acctg_date ,
P_ledger_id ,
P_user_id ,
P_request_id ,
P_bt_code ,
P_primary_accounting_method ,
P_calling_sequence ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Insert Mass Main Loop Begins Here.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Main Loop Iteration Begins' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Initialize Plsql variables' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Fetching records from cursor c_apinv.') ;
t_TxnUpdatedByTab,
t_invoiceIdTab,
t_sourceTab,
t_InvoiceNumberTab,
t_warrantyNumberTab,
t_ManufacturerTab,
t_SerialNumberTab,
t_ModelNumberTab,
t_linetypeLcdTab,
t_poDistIdTab,
t_RelatedIdTab,
t_DistLineNumberTab,
t_invDistIdTab,
t_DistCcidTab,
t_InvLineNumberTab,
t_RvrAssetsFlagTab,
t_SrcAssetsFlagTab,
t_parentInvDstIdTab,
t_apAssetsFlagTab,
t_DstMatchTypeTab,
t_accTypeTab,
t_XalccidTab,
t_ledgercatcdTab,
t_ledgeridTab,
t_invOrgIDTab,
t_ATrackFlagTab
limit l_count ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Exiting from main loop') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Expenditure Item ID:'||t_eiIDTab(indx)) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL Line Number:'||t_lineNumTab(indx)) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','t_cdlEventIDTab:'||t_cdlEventIDTab(indx) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','Reversing and reversed cdls are ignored' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL ignored because ap distribution not eligible' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL c_assets_tracking_flagA returns N for related ID '|| t_RelatedIdTab(indx) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL c_assets_tracking_flagA and B returns N ' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL c_assets_tracking_flagA and B returns Y ' ) ;
-- write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL ignored because ap distribution not eligible' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL does not belong to assets account.' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL does not belong to assets account.' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass',
'Getting asset_category_id for po distribution:'||t_poDistIdTab(indx));
select mtlsi.asset_category_id,
polt.order_type_lookup_code,
decode(pod.accrue_on_receipt_flag, 'Y', pod.code_combination_id, NULL ),
pod.deliver_to_person_id,
rtrim(upper(poh.segment1))
into l_assets_category_id,
l_po_order_type_lcd,
l_po_ccid,
l_assigned_to,
l_po_number
from po_distributions_all pod,
po_headers poh,
po_lines_all pol,
po_line_types_b polt,
mtl_system_items mtlsi
where pod.po_distribution_id = t_PoDistIdTab(indx)
and pod.po_header_id = poh.po_header_id
and pod.po_line_id = pol.po_line_id
and pol.line_type_id = polt.line_type_id
and pol.item_id = mtlsi.inventory_item_id(+)
and t_invOrgIDTab(indx) = mtlsi.organization_id (+) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass',
'Asset_category_id for po distribution:'||l_assets_category_id);
l_TxnUpdatedByTab(lrec) := t_TxnUpdatedByTab(indx) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Intercompany Invoice' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Code combination ID:'|| l_payCCIDTab(lrec) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Ignore CDL flag value:'||l_ignore_cdl ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'Count of cdls ignored:'||Flag_no_eiIDTab.COUNT ) ;
UPDATE pa_cost_distribution_lines
SET si_assets_addition_flag = 'N',
program_update_date = SYSDATE,
program_application_id = FND_GLOBAL.prog_appl_id,
program_id = FND_GLOBAL.conc_program_id,
request_id = p_request_id
WHERE si_assets_addition_flag = 'T'
AND expenditure_item_id = Flag_no_eiIDTab(i)
AND line_num = Flag_no_lineNumTab(i);
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'FA_MASS_ADDITIONS_GT Count:'||l_eiIDtab.count) ;
INSERT INTO FA_MASS_ADDITIONS_GT(
mass_addition_id,
description,
asset_category_id,
manufacturer_name,
serial_number,
model_number,
book_type_code,
transaction_date,
fixed_assets_cost,
payables_units,
fixed_assets_units,
payables_cost,
payables_code_combination_id,
assigned_to,
feeder_system_name,
create_batch_date,
create_batch_id,
last_update_date,
last_updated_by,
invoice_date,
invoice_created_by,
invoice_updated_by,
invoice_id,
invoice_number,
invoice_distribution_id,
invoice_line_number,
ap_distribution_line_number,
merge_invoice_number,
merge_vendor_number,
vendor_number,
po_vendor_id,
po_number,
payables_batch_name,
accounting_date,
created_by,
creation_date,
last_update_login,
parent_invoice_dist_id,
ledger_id,
ledger_category_code,
warranty_number,
line_type_lookup_code,
po_distribution_id,
expenditure_item_id,
line_num,
line_status ,
posting_status,
queue_name,
asset_number,
tag_number,
depreciate_flag,
parent_mass_addition_id,
parent_asset_id,
split_merged_code,
inventorial,
date_placed_in_service,
transaction_type_code,
expense_code_combination_id,
location_id,
reviewer_comments,
post_batch_id,
add_to_asset_id,
amortize_flag,
new_master_flag,
asset_key_ccid,
asset_type,
deprn_reserve,
ytd_deprn,
beginning_nbv,
salvage_value)
SELECT fa_mass_additions_s.nextval,
l_descriptionTab(i),
l_assetsCatIDTab(i) ,
l_ManufacturerTab(i),
l_SerialNumberTab(i),
l_ModelNumberTab(i),
l_BookTypCdTab(i) ,
l_eiDateTab(i),
l_payCostTab(i),
l_PayUnitTab(i),
l_FAUnitTab(i),
l_payCostTab(i),
l_payCCIDTab(i),
l_assignedToTab(i) ,
'ORACLE PROJECTS',
trunc(SYSDATE) Create_batch_date,
P_request_id create_batch_id,
trunc(SYSDATE) last_update_date,
p_user_id last_update_by,
l_TxnDateTab(i) ,
l_TxnCreatedByTab(i),
l_TxnUpdatedByTab(i),
l_invoiceIdTab(i) ,
l_InvoiceNumberTab(i),
l_invDistIdtab(i) ,
l_InvLineNumberTab(i),
l_DistLineNumberTab(i),
l_InvoiceNumberTab(i),
l_vendorNumberTab(i),
l_vendorNumberTab(i),
l_vendorIdTab(i),
l_PoNumberTab(i),
l_payBatchNameTab(i), -- Payables Batch Name,
l_GlDateTab(i) ,
p_user_id, -- Created by
trunc(SYSDATE), -- creation date
p_user_id, -- lst update login
l_parentInvDstIdTab(i),
l_ledgerIdTab(i),
l_ledgercatcdTab(i) ,
l_warrantyNumberTab(i),
l_linetypeLcdtab(i),
l_poDistIdTab(i),
l_eiIDtab(i),
l_lineNumTab(lrec) ,
'NEW',
'NEW',
'NEW',
NULL, -- assets_number
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL -- Salvage Value
FROM dual ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass', 'When Others:'||SQLERRM ) ;
END Insert_Mass;
PROCEDURE Insert_Discounts(p_api_version IN number,
p_init_msg_list IN varchar2 default FND_API.G_FALSE,
p_commit IN varchar2 default FND_API.G_FALSE,
p_validation_level IN number default FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY varchar2,
x_msg_count OUT NOCOPY number,
x_msg_data OUT NOCOPY varchar2,
x_count OUT NOCOPY number,
P_acctg_date IN DATE,
P_ledger_id IN number,
P_user_id IN number,
P_request_id IN number,
P_bt_code IN varchar2,
P_primary_accounting_method IN varchar2,
P_calling_sequence IN varchar2 DEFAULT NULL) IS
--
l_current_calling_sequence varchar2(2000);
l_api_name CONSTANT varchar2(100) := 'INSERT_DISCOUNTS';
select ei.expenditure_item_id,
ei.expenditure_item_date ,
cdl.line_num,
ei.document_header_id,
ei.document_distribution_id,
ei.document_payment_id,
ei.document_line_number,
ei.document_type,
ei.document_distribution_type,
ei.transaction_source,
RTRIM(SUBSTRB(eic.expenditure_comment,1,80)) description,
(NVL(XDL.unrounded_accounted_dr,0) - NVL(XDL.unrounded_accounted_cr,0)) acct_raw_cost,
--cdl.acct_raw_cost acct_raw_cost,
cdl.gl_date,
cdl.acct_event_id,
cdl.quantity,
ei.net_zero_adjustment_flag,
ei.adjusted_expenditure_item_id,
ei.transferred_from_exp_item_id,
ei.vendor_id,
rtrim(POV.segment1) vendor_number,
apb.batch_name,
api.invoice_date,
cdl.created_by invoice_created_by,
ei.last_updated_by invoice_updated_by,
api.invoice_id invoice_id,
api.source,
rtrim(api.invoice_num) invoice_num,
apil.warranty_number,
apil.manufacturer,
apil.serial_number,
apil.model_number,
apd.line_type_lookup_code line_type_lookup_code,
apd.po_distribution_id,
apd.related_id,
apd.distribution_line_number,
apd.invoice_distribution_id,
apd.dist_code_combination_id,
apd.invoice_line_number,
decode(cdl.reversed_flag, NULL, NULL,
( select cdl2.si_assets_addition_flag
from pa_cost_distribution_lines_all cdl2
where cdl2.expenditure_item_id = cdl.expenditure_item_id
and cdl2.line_num_reversed = cdl.line_num ) ) reversed_assets_flag,
decode(cdl.line_num_reversed, NULL, NULL,
( select cdl2.si_assets_addition_flag
from pa_cost_distribution_lines_all cdl2
where cdl2.expenditure_item_id = cdl.expenditure_item_id
and cdl2.line_num = cdl.line_num_reversed ) ) source_assets_flag,
DECODE(apd.line_type_lookup_code,
'ITEM', decode(apd.corrected_invoice_dist_id,
NULL, apd.invoice_distribution_id,
apd.corrected_invoice_dist_id),
'ACCRUAL',decode(apd.corrected_invoice_dist_id,
NULL, apd.invoice_distribution_id,
apd.corrected_invoice_dist_id),
apd.charge_applicable_to_dist_id ) parent_invoice_dist_id,
apip.assets_addition_flag ap_assets_addition_flag,
apd.dist_match_type,
glcc.account_type ,
xal.code_combination_id,
algt.ledger_category_code,
algt.ledger_id,
fsp.inventory_organization_id,
apd.assets_tracking_flag
from pa_expenditure_items ei,
pa_expenditure_comments eic,
pa_cost_distribution_lines cdl,
ap_invoices api,
ap_invoice_lines apil,
ap_invoice_distributions apd,
financials_system_params_all fsp,
ap_invoice_payments apip,
ap_batches_all apb,
po_vendors pov,
xla_distribution_links xdl,
xla_ae_headers xah,
xla_ae_lines xal,
ap_alc_ledger_gt algt,
ap_acct_class_code_gt aagt,
gl_code_combinations glcc,
pa_projects_all p,
pa_project_types_all pt
where ei.expenditure_item_id = cdl.expenditure_item_id
and cdl.expenditure_item_id = eic.expenditure_item_id (+)
and cdl.line_num = eic.line_number (+)
and ei.transaction_source in ('AP DISCOUNTS')
and cdl.gl_date <= P_acctg_date
and cdl.line_type = 'R'
and cdl.transfer_status_code = 'A'
and cdl.si_assets_addition_flag = 'T'
and cdl.project_id = p.project_id
and p.project_type = pt.project_type
and p.org_id = pt.org_id
and pt.project_type_class_code <> 'CAPITAL'
and ei.document_header_id = api.invoice_id
and ei.document_distribution_id = apd.invoice_distribution_id
and ei.document_line_number = apd.invoice_line_number
and apil.invoice_id = api.invoice_id
and api.org_id = fsp.org_id
and apil.line_number = apd.invoice_line_number
and API.batch_id = apb.batch_id(+)
and apd.posted_flag = 'Y'
--and apd.cash_posted_flag = 'Y'
--and apd.assets_addition_flag = 'Y'
and api.vendor_id = pov.vendor_id
and ei.document_payment_id = apip.invoice_payment_id
and apip.accounting_date <= P_acctg_date
and apip.set_of_books_id = P_ledger_id
AND xah.application_id = 275
-- 5911379: Modified the join
and xdl.application_id = xah.application_id
and xah.event_id = cdl.acct_event_id
AND xah.balance_type_code = 'A'
and xah.accounting_entry_status_code = 'F'
and xal.application_id = xah.application_id
AND xal.ae_header_id = xah.ae_header_id
and xal.accounting_class_code = aagt.accounting_class_code
and xdl.event_id = xah.event_id
AND xdl.ae_header_id = xal.ae_header_id
AND xdl.ae_line_num = xal.ae_line_num
and xdl.application_id = xal.application_id
and xdl.source_distribution_id_num_1 = ei.expenditure_item_id
and xdl.source_distribution_id_num_2 = cdl.line_num
AND xah.ledger_id = algt.ledger_id
and decode(algt.org_id, -99, algt.org_id, cdl.org_id) =
decode(algt.org_id, -99, -99, algt.org_id)
and glcc.code_combination_id = xal.code_combination_id
-- 5911379: ends
order by ei.document_distribution_id, ei.expenditure_item_id, cdl.line_num ;
'Insert_Discounts';
'INSERT_DISCOUNTS',
G_pkg_name) THEN
RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Begin discount processing.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Begin Main LOOP.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Init PLSQL Tab variables.') ;
t_TxnUpdatedByTab,
t_invoiceIdTab,
t_sourceTab,
t_InvoiceNumberTab,
t_warrantyNumberTab,
t_ManufacturerTab,
t_SerialNumberTab,
t_ModelNumberTab,
t_linetypeLcdTab,
t_poDistIdTab,
t_RelatedIdTab,
t_DistLineNumberTab,
t_invDistIdTab,
t_DistCcidTab,
t_InvLineNumberTab,
t_RvrAssetsFlagTab,
t_SrcAssetsFlagTab,
t_parentInvDstIdTab,
t_apAssetsFlagTab,
t_DstMatchTypeTab,
t_accTypeTab,
t_XalccidTab,
t_ledgercatcdTab,
t_ledgerIdTab ,
t_InvOrgIDTab,
t_ATrackFlagTab
limit l_count ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Leaving main LOOP.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Exp Item ID:'||t_eiIDTab(indx)) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'CDL Line num:'||t_lineNumTab(indx)) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL ignored because ap distribution not eligible' ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL c_assets_tracking_flagA returns N ') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL c_assets_tracking_flagA and B returns N ') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '10:PA Insert_mass','CDL c_assets_tracking_flagA or B returns Y ') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Invoice Source:'||t_sourceTab(indx)) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Account Type :'||t_accTypeTab(indx)) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Ignore CDL :'||l_ignore_cdl) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'PO DistributionID:'||t_poDistIdTab(indx));
SELECT mtlsi.asset_category_id,
polt.order_type_lookup_code,
decode(pod.accrue_on_receipt_flag, 'Y', pod.code_combination_id, NULL ),
pod.deliver_to_person_id,
rtrim(upper(poh.segment1))
into l_assets_category_id,
l_po_order_type_lcd,
l_po_ccid,
l_assigned_to,
l_po_number
FROM po_distributions_all pod,
po_headers poh,
po_lines_all pol,
po_line_types_b polt,
mtl_system_items mtlsi
WHERE pod.po_distribution_id = t_PoDistIdTab(indx)
AND pod.po_header_id = poh.po_header_id
AND pod.po_line_id = pol.po_line_id
AND pol.line_type_id = polt.line_type_id
AND pol.item_id = mtlsi.inventory_item_id(+)
AND t_InvOrgIDTab(indx) = mtlsi.organization_id (+) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS',
'Asset_category_id for po distribution:'||l_assets_category_id);
l_TxnUpdatedByTab(lrec) := t_TxnUpdatedByTab(indx) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'Flag_no_eiIDTab.COUNT:'||Flag_no_eiIDTab.COUNT) ;
UPDATE pa_cost_distribution_lines
SET si_assets_addition_flag = 'N',
program_update_date = SYSDATE,
program_application_id = FND_GLOBAL.prog_appl_id,
program_id = FND_GLOBAL.conc_program_id,
request_id = p_request_id
WHERE si_assets_addition_flag in ('T', 'O')
AND expenditure_item_id = Flag_no_eiIDTab(i)
AND line_num = Flag_no_lineNumTab(i);
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'eiIDTab.COUNT:'||l_eiIDTab.COUNT) ;
INSERT INTO FA_MASS_ADDITIONS_GT(
mass_addition_id,
description,
asset_category_id,
manufacturer_name,
serial_number,
model_number,
book_type_code,
transaction_date,
fixed_assets_cost,
payables_units,
fixed_assets_units,
payables_cost,
payables_code_combination_id,
assigned_to,
feeder_system_name,
create_batch_date,
create_batch_id,
last_update_date,
last_updated_by,
invoice_date,
invoice_created_by,
invoice_updated_by,
invoice_id,
invoice_number,
invoice_distribution_id,
invoice_line_number,
ap_distribution_line_number,
merge_invoice_number,
merge_vendor_number,
vendor_number,
po_vendor_id,
po_number,
payables_batch_name,
accounting_date,
created_by,
creation_date,
last_update_login,
parent_invoice_dist_id,
ledger_id,
ledger_category_code,
warranty_number,
line_type_lookup_code,
po_distribution_id,
expenditure_item_id,
line_num,
line_status ,
posting_status,
queue_name,
inventorial,
asset_number,
tag_number,
depreciate_flag,
parent_mass_addition_id,
parent_asset_id,
split_merged_code,
date_placed_in_service,
transaction_type_code,
expense_code_combination_id,
location_id,
reviewer_comments,
post_batch_id,
add_to_asset_id,
amortize_flag,
new_master_flag,
asset_key_ccid,
asset_type,
deprn_reserve,
ytd_deprn,
beginning_nbv,
salvage_value
)
SELECT fa_mass_additions_s.nextval,
l_descriptionTab(i),
l_assetsCatIDTab(i),
l_ManufacturerTab(i),
l_SerialNumberTab(i),
l_ModelNumberTab(i),
l_BookTypCdTab(i) ,
l_eiDateTab(i),
l_payCostTab(i),
l_PayUnitTab(i),
l_FAUnitTab(i),
l_payCostTab(i),
l_payCCIDTab(i),
l_assignedToTab(i) ,
'ORACLE PROJECTS',
trunc(SYSDATE) Create_batch_date,
P_request_id create_batch_id,
trunc(SYSDATE) last_update_date,
p_user_id last_update_by,
l_TxnDateTab(i) ,
l_TxnCreatedByTab(i),
l_TxnUpdatedByTab(i),
l_invoiceIdTab(i) ,
l_InvoiceNumberTab(i),
l_invDistIdtab(i) ,
l_InvLineNumberTab(i),
l_DistLineNumberTab(i),
l_InvoiceNumberTab(i),
l_vendorNumberTab(i),
l_vendorNumberTab(i),
l_vendorIdTab(i),
l_PoNumberTab(i),
l_payBatchNameTab(i), -- Payables Batch Name,
l_GlDateTab(i) ,
p_user_id, -- Created by
trunc(SYSDATE), -- creation date
p_user_id, -- lst update login
l_parentInvDstIdTab(i),
l_ledgerIdTab(i) ,
l_ledgercatcdTab(i) ,
l_warrantyNumberTab(i),
'DISCOUNT' , --l_linetypeLcdtab(i),
l_poDistIdTab(i),
l_eiIDtab(i),
l_lineNumTab(lrec) ,
'NEW',
'NEW',
'NEW',
'Yes', --inventorial,
NULL, -- assets_number
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL -- Salvage Value
from DUAL ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '40:INSERT_DISCOUNTS', 'EXCEPTION:'||SQLERRM) ;
END Insert_Discounts;
PROCEDURE update_mass (p_api_version IN number,
p_init_msg_list IN varchar2 default FND_API.G_FALSE,
p_commit IN varchar2 default FND_API.G_FALSE,
p_validation_level IN number default FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY varchar2,
x_msg_count OUT NOCOPY number,
x_msg_data OUT NOCOPY varchar2,
p_request_id IN number ) is
l_msg_count number ;
'UPDATE_MASS',
G_pkg_name) THEN
RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
write_to_log(FND_LOG.LEVEL_STATEMENT,'50:UPDATE_MASS','UPDATE MASS Processing begins.') ;
UPDATE pa_cost_distribution_lines
SET si_assets_addition_flag = 'Y',
program_update_date = SYSDATE,
program_application_id = FND_GLOBAL.prog_appl_id,
program_id = FND_GLOBAL.conc_program_id,
request_id = p_request_id
where si_assets_addition_flag = ('T')
AND (expenditure_item_id, line_num ) in
(SELECT expenditure_item_id, line_num
FROM fa_mass_additions_gt
WHERE line_status = 'PROCESSED') ;
write_to_log(FND_LOG.LEVEL_STATEMENT,'50:UPDATE_MASS','UPDATE MASS Record processed:'||SQL%ROWCOUNT );
UPDATE pa_cost_distribution_lines
SET si_assets_addition_flag = 'N',
program_update_date = SYSDATE,
program_application_id = FND_GLOBAL.prog_appl_id,
program_id = FND_GLOBAL.conc_program_id,
request_id = p_request_id
where si_assets_addition_flag = ('T')
AND (expenditure_item_id, line_num ) in
(SELECT expenditure_item_id, line_num
FROM fa_mass_additions_gt
WHERE line_status = 'REJECTED') ;
write_to_log(FND_LOG.LEVEL_STATEMENT,'50:UPDATE_MASS', 'UPDATE MASS Record processed with N-status:'||SQL%ROWCOUNT);
END update_mass ;
PROCEDURE Insert_Receipts(
P_acctg_date IN DATE,
P_ledger_id IN number,
P_user_id IN number,
P_request_id IN number,
P_bt_code IN varchar2,
P_primary_accounting_method IN varchar2,
P_calling_sequence IN varchar2 DEFAULT NULL) IS
--
l_current_calling_sequence varchar2(2000);
l_api_name CONSTANT varchar2(100) := 'INSERT_MASS';
select ei.expenditure_item_id,
ei.expenditure_item_date ,
cdl.line_num,
ei.document_header_id,
ei.document_distribution_id,
ei.document_payment_id,
ei.document_line_number,
ei.document_type,
ei.document_distribution_type,
ei.transaction_source,
RTRIM(SUBSTRB(eic.expenditure_comment,1,80)) description,
(NVL(XDL.unrounded_accounted_dr,0) - NVL(XDL.unrounded_accounted_cr,0)) acct_raw_cost,
--cdl.acct_raw_cost acct_raw_cost,
cdl.gl_date,
cdl.acct_event_id,
cdl.quantity,
ei.net_zero_adjustment_flag,
ei.adjusted_expenditure_item_id,
ei.transferred_from_exp_item_id,
ei.vendor_id,
rtrim(POV.segment1) vendor_number,
NULL, --Batch_name
rcvtxn.transaction_date,
rcvtxn.created_by txn_created_by,
rcvtxn.last_updated_by txn_updated_by,
NULL invoice_id,
NULL, --api.source,
NULL, --rtrim(api.invoice_num) invoice_num,
NULL, --warranty_number,
NULL, --manufacturer,
NULL, --serial_number,
NULL, --model_number,
'ACCRUAL', --line_type_lookup_code,
rcvtxn.po_distribution_id,
NULL, --apd.related_id,
NULL, --distribution_line_number,
NULL, --apd.invoice_distribution_id,
NULL, --dist_code_combination_id,
NULL, --apd.invoice_line_number
decode(cdl.reversed_flag, NULL, NULL,
( select cdl2.si_assets_addition_flag
from pa_cost_distribution_lines_all cdl2
where cdl2.expenditure_item_id = cdl.expenditure_item_id
and cdl2.line_num_reversed = cdl.line_num ) ) reversed_assets_flag,
decode(cdl.line_num_reversed, NULL, NULL,
( select cdl2.si_assets_addition_flag
from pa_cost_distribution_lines_all cdl2
where cdl2.expenditure_item_id = cdl.expenditure_item_id
and cdl2.line_num = cdl.line_num_reversed ) ) source_assets_flag,
NULL parent_invoice_dist_id,
'Y' txn_assets_addition_flag,
glcc.account_type ,
xal.code_combination_id,
algt.ledger_category_code,
algt.ledger_id,
fsp.inventory_organization_id
from pa_cost_distribution_lines cdl,
xla_ae_headers xah,
xla_ae_lines xal,
xla_distribution_links xdl,
pa_expenditure_items ei,
pa_expenditure_comments eic,
rcv_transactions rcvtxn ,
po_distributions pod,
financials_system_params_all fsp,
po_vendors pov,
ap_alc_ledger_gt algt,
ap_acct_class_code_gt aagt,
gl_code_combinations glcc,
pa_projects_all p,
pa_project_types_all pt
where ei.expenditure_item_id = cdl.expenditure_item_id
and cdl.expenditure_item_id = eic.expenditure_item_id (+)
and cdl.line_num = eic.line_number (+)
and ei.transaction_source in ('PO RECEIPT',
'PO RECEIPT NRTAX',
'PO RECEIPT NRTAX PRICE ADJ',
'PO RECEIPT PRICE ADJ')
and cdl.gl_date <= P_acctg_date
and cdl.line_type = 'R'
and cdl.transfer_status_code = 'A'
and cdl.si_assets_addition_flag = 'T'
and cdl.project_id = p.project_id
and p.project_type = pt.project_type
-- Bug : 5368600
and p.org_id = pt.org_id
and pt.project_type_class_code <> 'CAPITAL'
and ei.document_distribution_id = rcvtxn.transaction_id
and pod.po_distribution_id = rcvtxn.po_distribution_id
and pod.org_id = fsp.org_id
and ei.vendor_id = pov.vendor_id
-- 5911379: Modified the join
and xdl.application_id = xah.application_id
AND xah.application_id = 275
and xah.event_id = cdl.acct_event_id
AND xah.balance_type_code = 'A'
and xah.accounting_entry_status_code = 'F'
and xal.application_id = xah.application_id
AND xal.ae_header_id = xah.ae_header_id
and xal.accounting_class_code = aagt.accounting_class_code
and xdl.event_id = xah.event_id
AND xdl.ae_header_id = xal.ae_header_id
AND xdl.ae_line_num = xal.ae_line_num
and xdl.application_id = xal.application_id
and xdl.source_distribution_id_num_1 = ei.expenditure_item_id
and xdl.source_distribution_id_num_2 = cdl.line_num
and pod.set_of_books_id = p_ledger_id
AND xah.ledger_id = algt.ledger_id
and decode(algt.org_id, -99, algt.org_id, cdl.org_id) =
decode(algt.org_id, -99, -99, algt.org_id)
-- 5911379: ends
and glcc.code_combination_id = xal.code_combination_id
order by ei.document_distribution_id, ei.expenditure_item_id, cdl.line_num ;
'Insert_Mass';
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Inside Insert Receipt procedure.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Main Loop Begins here.') ;
t_TxnUpdatedByTab,
t_invoiceIdTab,
t_sourceTab,
t_InvoiceNumberTab,
t_warrantyNumberTab,
t_ManufacturerTab,
t_SerialNumberTab,
t_ModelNumberTab,
t_linetypeLcdTab,
t_poDistIdTab,
t_RelatedIdTab,
t_DistLineNumberTab,
t_invDistIdTab,
t_DistCcidTab,
t_InvLineNumberTab,
t_RvrAssetsFlagTab,
t_SrcAssetsFlagTab,
t_parentInvDstIdTab,
t_apAssetsFlagTab,
--t_DstMatchTypeTab,
t_accTypeTab,
t_XalccidTab,
t_ledgercatcdTab,
t_ledgerIdTab,
t_invOrgIDTab
limit l_count ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Exiting Main Loop.') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Exp Item ID:'|| t_eiIDTab(indx) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'line Number:'|| t_lineNumTab(indx) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Account Type:'|| t_accTypeTab(indx) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'PO Dist ID :'|| t_poDistIdTab(indx) ) ;
SELECT mtlsi.asset_category_id,
polt.order_type_lookup_code,
decode(pod.accrue_on_receipt_flag, 'Y', pod.code_combination_id, NULL ),
pod.deliver_to_person_id,
rtrim(upper(poh.segment1))
INTO l_assets_category_id,
l_po_order_type_lcd,
l_po_ccid,
l_assigned_to,
l_po_number
FROM po_distributions_all pod,
po_headers_all poh,
po_lines_all pol,
po_line_types_b polt,
mtl_system_items mtlsi
WHERE pod.po_distribution_id = t_PoDistIdTab(indx)
AND pod.po_header_id = poh.po_header_id
AND pod.po_line_id = pol.po_line_id
AND pol.line_type_id = polt.line_type_id
AND pol.item_id = mtlsi.inventory_item_id(+)
AND t_InvOrgIDTab(indx) = mtlsi.organization_id (+) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Asset_category_id for po distribution:'||l_assets_category_id);
l_TxnUpdatedByTab(lrec) := t_TxnUpdatedByTab(indx) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Payable CCID:'||l_payCCIDTab(lrec) ) ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Flag_no_eiIDTab.COUNT:'||Flag_no_eiIDTab.COUNT ) ;
UPDATE pa_cost_distribution_lines
SET si_assets_addition_flag = 'N',
program_update_date = SYSDATE,
program_application_id = FND_GLOBAL.prog_appl_id,
program_id = FND_GLOBAL.conc_program_id,
request_id = p_request_id
WHERE si_assets_addition_flag in ('T')
AND expenditure_item_id = Flag_no_eiIDTab(i)
AND line_num = Flag_no_lineNumTab(i);
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'l_eiIDtab.count:'||l_eiIDtab.count) ;
INSERT INTO FA_MASS_ADDITIONS_GT(
mass_addition_id,
description,
asset_category_id,
manufacturer_name,
serial_number,
model_number,
book_type_code,
transaction_date,
fixed_assets_cost,
payables_units,
fixed_assets_units,
payables_cost,
payables_code_combination_id,
assigned_to,
feeder_system_name,
create_batch_date,
create_batch_id,
last_update_date,
last_updated_by,
invoice_date,
invoice_created_by,
invoice_updated_by,
invoice_id,
invoice_number,
invoice_distribution_id,
invoice_line_number,
ap_distribution_line_number,
merge_invoice_number,
merge_vendor_number,
vendor_number,
po_vendor_id,
po_number,
payables_batch_name,
accounting_date,
created_by,
creation_date,
last_update_login,
parent_invoice_dist_id,
ledger_id,
ledger_category_code,
warranty_number,
line_type_lookup_code,
po_distribution_id,
expenditure_item_id,
line_num,
line_status ,
posting_status,
queue_name,
asset_number,
tag_number,
depreciate_flag,
parent_mass_addition_id,
parent_asset_id,
split_merged_code,
inventorial,
date_placed_in_service,
transaction_type_code,
expense_code_combination_id,
location_id,
reviewer_comments,
post_batch_id,
add_to_asset_id,
amortize_flag,
new_master_flag,
asset_key_ccid,
asset_type,
deprn_reserve,
ytd_deprn,
beginning_nbv,
salvage_value)
SELECT fa_mass_additions_s.nextval,
l_descriptionTab(i),
l_assetsCatIDTab(i) ,
l_ManufacturerTab(i),
l_SerialNumberTab(i),
l_ModelNumberTab(i),
l_BookTypCdTab(i) ,
l_eiDateTab(i),
l_payCostTab(i),
l_PayUnitTab(i),
l_FAUnitTab(i),
l_payCostTab(i),
l_payCCIDTab(i),
l_assignedToTab(i) ,
'ORACLE PROJECTS',
trunc(SYSDATE) Create_batch_date,
P_request_id create_batch_id,
trunc(SYSDATE) last_update_date,
p_user_id last_update_by,
l_TxnDateTab(i) ,
l_TxnCreatedByTab(i),
l_TxnUpdatedByTab(i),
l_invoiceIdTab(i) ,
l_InvoiceNumberTab(i),
l_invDistIdtab(i) ,
l_InvLineNumberTab(i),
l_DistLineNumberTab(i),
l_InvoiceNumberTab(i),
l_vendorNumberTab(i),
l_vendorNumberTab(i),
l_vendorIdTab(i),
l_PoNumberTab(i),
l_payBatchNameTab(i), --Payables Batch Name,
l_GlDateTab(i) ,
p_user_id, -- Created by
trunc(SYSDATE), -- creation date
p_user_id, -- lst update login
l_parentInvDstIdTab(i),
l_ledgeridTab(i) ,
l_ledgerCatcdTab(i),
l_warrantyNumberTab(i),
l_linetypeLcdtab(i),
l_poDistIdTab(i),
l_eiIDtab(i),
l_lineNumTab(lrec) ,
'NEW',
'NEW',
'NEW',
NULL, -- assets_number
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL -- Salvage Value
from DUAL ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'Inserting MRC Records...') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT',
'End of Receipt Insert') ;
write_to_log(FND_LOG.LEVEL_STATEMENT, '50:PA INSERT_RECEIPT', SQLERRM) ;
END Insert_Receipts;
t_eiIDtab.DELETE ;
t_eiDatetab.DELETE ;
t_lineNumtab.DELETE ;
t_DocHeaderIdtab.DELETE ;
t_DocDistIdtab.DELETE ;
t_DocPaymentIdtab.DELETE ;
t_DocLineNumbertab.DELETE ;
t_DocTypetab.DELETE ;
t_DocDistTypetab.DELETE ;
t_transSourcetab.DELETE ;
t_descriptiontab.DELETE ;
t_acctRawCosttab.DELETE ;
t_NZAdjFlagtab.DELETE ;
t_adjEiIdtab.DELETE ;
t_trFmEiIdtab.DELETE ;
t_vendorIdtab.DELETE ;
t_vendorNumbertab.DELETE ;
t_TxnDatetab.DELETE ;
t_TxnCreatedByTab.DELETE ;
t_TxnUpdatedByTab.DELETE ;
t_invoiceIdtab.DELETE ;
t_sourcetab.DELETE ;
t_InvoiceNumbertab.DELETE ;
t_warrantyNumberTab.DELETE ;
t_Manufacturertab.DELETE ;
t_SerialNumbertab.DELETE ;
t_ModelNumbertab.DELETE ;
t_linetypeLcdtab.DELETE ;
t_poDistIdtab.DELETE ;
t_RelatedIdtab.DELETE ;
t_DistLineNumbertab.DELETE ;
t_invDistIdtab.DELETE ;
t_DistCcidtab.DELETE ;
t_InvLineNumbertab.DELETE ;
t_RvrAssetsFlagtab.DELETE ;
t_SrcAssetsFlagtab.DELETE ;
t_parentInvDstIdtab.DELETE ;
t_apAssetsFlagTab.DELETE ;
t_DstMatchTypetab.DELETE ;
t_GlDateTab.DELETE ;
t_cdlEventIDTab.Delete ;
t_cdlQtyTab.DELETE ;
t_SiAssetsFlagTab.delete ;
t_ATrackFlagTab.delete ;
t_payBatchNameTab.delete ;
Flag_no_eiIDTab.DELETE ;
Flag_no_lineNumTab.DELETE ;
t_invOrgIDTab.DELETE ;
l_SiAssetsFlagTab.delete ;
l_descriptionTab.Delete ;
l_poDistIdTab.Delete ;
l_assetsCatIDTab.Delete ;
l_ManufacturerTab.Delete ;
l_SerialNumberTab.Delete ;
l_ModelNumberTab.Delete ;
l_BookTypCdTab.Delete ;
l_eiDateTab.Delete ;
l_FACostTab.Delete ;
l_PayUnitTab.Delete ;
l_FAUnitTab.Delete ;
l_assignedToTab.Delete ;
l_payCostTab.Delete ;
l_vendorNumberTab.Delete ;
l_vendorIdTab.Delete ;
l_PoNumberTab.Delete ;
l_TxnDateTab.Delete ;
l_TxnCreatedByTab.Delete ;
l_TxnUpdatedByTab.Delete ;
l_invoiceIdTab.Delete ;
l_payBatchNameTab.Delete ;
l_DistLineNumberTab.Delete ;
l_GlDateTab.Delete ;
l_invDistIdTab.Delete ;
l_parentInvDstIdTab.Delete ;
l_linetypeLcdTab.Delete ;
l_eiIDTab.Delete ;
l_warrantyNumberTab.Delete ;
l_InvLineNumberTab.Delete ;
l_PayCcidTab.Delete ;
l_cdlEventIDTab.Delete ;
l_cdlQtyTab.DELETE ;
l_payBatchNameTab.delete ;
l_XalccidTab.DELETE ;
l_accTypeTab.DELETE ;
t_XalccidTab.DELETE ;
t_accTypeTab.DELETE ;
l_ledgeridtab.delete ;
l_ledgercatcdTab.delete ;
l_ATrackFlagTab.delete ;
t_ledgeridtab.delete ;
t_ledgercatcdTab.delete ;