The following lines contain the word 'select', 'insert', 'update' or 'delete':
pg_update_claim_amount NUMBER; /* Bug 4170060 for rct to rct applications */
select nvl(RECEIPT_CREATION_RULE_CODE,'MANUAL')
into l_rec_creation_rule_code
from AR_RECEIPT_METHODS
where receipt_method_id = l_receipt_method_id;
arp_proc_receipts2.insert_cash_receipt(
l_currency_code,
l_amount,
l_customer_id,
l_receipt_number,
l_receipt_date,
l_gl_date,
l_maturity_date,
p_comments,
l_exchange_rate_type,
l_exchange_rate,
l_exchange_rate_date,
NULL, --batch_id
l_attribute_rec.attribute_category,
l_attribute_rec.attribute1,
l_attribute_rec.attribute2,
l_attribute_rec.attribute3,
l_attribute_rec.attribute4,
l_attribute_rec.attribute5,
l_attribute_rec.attribute6,
l_attribute_rec.attribute7,
l_attribute_rec.attribute8,
l_attribute_rec.attribute9,
l_attribute_rec.attribute10,
l_attribute_rec.attribute11,
l_attribute_rec.attribute12,
l_attribute_rec.attribute13,
l_attribute_rec.attribute14,
l_attribute_rec.attribute15,
l_override_remit_account_flag,
l_remit_bank_acct_use_id ,
l_customer_bank_account_id ,
l_customer_site_use_id,
l_customer_receipt_reference ,
l_factor_discount_amount ,
l_deposit_date,
l_receipt_method_id,
l_doc_sequence_value,
l_doc_sequence_id,
l_ussgl_transaction_code ,
NULL, --Vat_tax_id
l_anticipated_clearing_date ,
l_customer_bank_branch_id,
l_postmark_date,
l_global_attribute_rec.global_attribute1,
l_global_attribute_rec.global_attribute2,
l_global_attribute_rec.global_attribute3,
l_global_attribute_rec.global_attribute4,
l_global_attribute_rec.global_attribute5,
l_global_attribute_rec.global_attribute6,
l_global_attribute_rec.global_attribute7,
l_global_attribute_rec.global_attribute8,
l_global_attribute_rec.global_attribute9,
l_global_attribute_rec.global_attribute10,
l_global_attribute_rec.global_attribute11,
l_global_attribute_rec.global_attribute12,
l_global_attribute_rec.global_attribute13,
l_global_attribute_rec.global_attribute14,
l_global_attribute_rec.global_attribute15,
l_global_attribute_rec.global_attribute16,
l_global_attribute_rec.global_attribute17,
l_global_attribute_rec.global_attribute18,
l_global_attribute_rec.global_attribute19,
l_global_attribute_rec.global_attribute20,
l_global_attribute_rec.global_attribute_category,
p_issuer_name,
trunc(p_issue_date), /* Bug fix 3135407 */
p_issuer_bank_branch_id,
null, -- application_notes
l_cr_id,
l_ps_id,
l_row_id,
'RAPI',
p_api_version
,p_called_from
,l_legal_entity_id /* R12 LE updtake */
,l_payment_trxn_extension_id /* payment uptake */
);
FND_MESSAGE.SET_TOKEN('GENERIC_TEXT','ARP_PROC_RECEIPTS2.INSERT_CASH_RECEIPT : '||SQLERRM);
select count(1) into l_count from ar_llca_trx_errors_gt
where customer_trx_id = p_customer_trx_id;
ar_receipt_val_pvt.validate_llca_insert_ad(
p_cash_receipt_id => l_cash_receipt_id
,p_customer_trx_id => l_customer_trx_id
,p_customer_trx_line_id => l_customer_trx_line_id
,p_cr_unapp_amount => l_cr_unapp_amount
,p_llca_type => l_llca_type
,p_group_id => l_group_id
,p_line_amount => l_line_amount
,p_tax_amount => l_tax_amount
,p_freight_amount => l_freight_amount
,p_charges_amount => l_charges_amount
,p_line_discount => l_line_discount
,p_tax_discount => l_tax_discount
,p_freight_discount => l_freight_discount
,p_amount_applied => l_amount_applied
,p_amount_applied_from => l_amount_applied_from
,p_trans_to_receipt_rate => l_trans_to_receipt_rate
,p_invoice_currency_code => l_trx_currency_code
,p_receipt_currency_code => l_cr_currency_code
,p_earned_discount => l_discount_earned_allowed
,p_unearned_discount => l_discount_unearned
,p_max_discount => l_discount_max_allowed
,p_line_items_original => l_line_items_original
,p_line_items_remaining => l_line_items_remaining
,p_tax_original => l_tax_original
,p_tax_remaining => l_tax_remaining
,p_freight_original => l_freight_original
,p_freight_remaining => l_freight_remaining
,p_rec_charges_charged => l_rec_charges_charged
,p_rec_charges_remaining => l_rec_charges_remaining
,p_attribute_category => l_line_attribute_rec.attribute_category
,p_attribute1 => l_line_attribute_rec.attribute1
,p_attribute2 => l_line_attribute_rec.attribute2
,p_attribute3 => l_line_attribute_rec.attribute3
,p_attribute4 => l_line_attribute_rec.attribute4
,p_attribute5 => l_line_attribute_rec.attribute5
,p_attribute6 => l_line_attribute_rec.attribute6
,p_attribute7 => l_line_attribute_rec.attribute7
,p_attribute8 => l_line_attribute_rec.attribute8
,p_attribute9 => l_line_attribute_rec.attribute9
,p_attribute10 => l_line_attribute_rec.attribute10
,p_attribute11 => l_line_attribute_rec.attribute11
,p_attribute12 => l_line_attribute_rec.attribute12
,p_attribute13 => l_line_attribute_rec.attribute13
,p_attribute14 => l_line_attribute_rec.attribute14
,p_attribute15 => l_line_attribute_rec.attribute15
,p_comments => p_comments
,p_return_status => l_llca_return_status
,p_msg_count => l_llca_msg_count
,p_msg_data => l_llca_msg_data
);
ar_receipt_val_pvt.validate_llca_insert_app(
p_cash_receipt_id => l_cash_receipt_id
,p_customer_trx_id => l_customer_trx_id
,p_disc_earn_allowed => l_discount_earned_allowed
,p_disc_max_allowed => l_discount_max_allowed
,p_return_status => l_llca_app_return_status
,p_msg_count => l_llca_app_msg_count
,p_msg_data => l_llca_app_msg_data
);
update ar_activity_details
set source_table = 'RA',
source_id = llca_ra_rec.receivable_application_id
where source_id is null
and nvl(current_activity_flag, 'Y') = 'Y' -- Bug 7241111
and cash_receipt_id = l_cash_receipt_id
and customer_trx_line_id in (select customer_trx_line_id
from ra_customer_trx_lines
where customer_trx_id = l_customer_trx_id);
delete from ar_llca_trx_lines_gt
where customer_trx_id = l_customer_trx_id;
SELECT application_ref_type,
secondary_application_ref_id,
amount_applied
INTO l_application_ref_type,
l_secondary_app_ref_id,
l_amount_applied
FROM ar_receivable_applications
WHERE receivable_application_id = l_receivable_application_id;
-- LLCA - Delete the activity record if llca exists. We need to modify the LLCA update
-- logic to preserve the previous record details on AR_ACTIVITY_DETAILS instead of
--- removing it. Open bug exist for this issue.
/*
delete from ar_activity_details ad
where ad.cash_receipt_id = l_cash_receipt_id
and ad.customer_trx_line_id in
(select customer_trx_line_id from ra_customer_trx_lines
where customer_trx_id = l_customer_trx_id);
INSERT INTO AR_ACTIVITY_DETAILS(
CASH_RECEIPT_ID,
CUSTOMER_TRX_LINE_ID,
ALLOCATED_RECEIPT_AMOUNT,
AMOUNT,
TAX,
FREIGHT,
CHARGES,
LAST_UPDATE_DATE,
LAST_UPDATED_BY,
LINE_DISCOUNT,
TAX_DISCOUNT,
FREIGHT_DISCOUNT,
LINE_BALANCE,
TAX_BALANCE,
CREATION_DATE,
CREATED_BY,
LAST_UPDATE_LOGIN,
COMMENTS,
APPLY_TO,
ATTRIBUTE1,
ATTRIBUTE2,
ATTRIBUTE3,
ATTRIBUTE4,
ATTRIBUTE5,
ATTRIBUTE6,
ATTRIBUTE7,
ATTRIBUTE8,
ATTRIBUTE9,
ATTRIBUTE10,
ATTRIBUTE11,
ATTRIBUTE12,
ATTRIBUTE13,
ATTRIBUTE14,
ATTRIBUTE15,
ATTRIBUTE_CATEGORY,
GROUP_ID,
REFERENCE1,
REFERENCE2,
REFERENCE3,
REFERENCE4,
REFERENCE5,
OBJECT_VERSION_NUMBER,
CREATED_BY_MODULE,
SOURCE_ID,
SOURCE_TABLE,
LINE_ID,
CURRENT_ACTIVITY_FLAG)
SELECT
LLD.CASH_RECEIPT_ID,
LLD.CUSTOMER_TRX_LINE_ID,
LLD.ALLOCATED_RECEIPT_AMOUNT*-1,
LLD.AMOUNT*-1,
LLD.TAX*-1,
LLD.FREIGHT*-1,
LLD.CHARGES*-1,
LLD.LAST_UPDATE_DATE,
LLD.LAST_UPDATED_BY,
LLD.LINE_DISCOUNT,
LLD.TAX_DISCOUNT,
LLD.FREIGHT_DISCOUNT,
LLD.LINE_BALANCE,
LLD.TAX_BALANCE,
LLD.CREATION_DATE,
LLD.CREATED_BY,
LLD.LAST_UPDATE_LOGIN,
LLD.COMMENTS,
LLD.APPLY_TO,
LLD.ATTRIBUTE1,
LLD.ATTRIBUTE2,
LLD.ATTRIBUTE3,
LLD.ATTRIBUTE4,
LLD.ATTRIBUTE5,
LLD.ATTRIBUTE6,
LLD.ATTRIBUTE7,
LLD.ATTRIBUTE8,
LLD.ATTRIBUTE9,
LLD.ATTRIBUTE10,
LLD.ATTRIBUTE11,
LLD.ATTRIBUTE12,
LLD.ATTRIBUTE13,
LLD.ATTRIBUTE14,
LLD.ATTRIBUTE15,
LLD.ATTRIBUTE_CATEGORY,
LLD.GROUP_ID,
LLD.REFERENCE1,
LLD.REFERENCE2,
LLD.REFERENCE3,
LLD.REFERENCE4,
LLD.REFERENCE5,
LLD.OBJECT_VERSION_NUMBER,
LLD.CREATED_BY_MODULE,
LLD.SOURCE_ID,
LLD.SOURCE_TABLE,
ar_Activity_details_s.nextval,
'R'
FROM ar_Activity_details LLD
where LLD.cash_receipt_id = l_cash_receipt_id
and nvl(LLD.CURRENT_ACTIVITY_FLAG, 'Y') = 'Y'
and LLD.customer_trx_line_id in
(select customer_trx_line_id
from ra_customer_trx_lines
where customer_trx_id = l_customer_trx_id);
UPDATE ar_Activity_details dtl
set CURRENT_ACTIVITY_FLAG = 'N'
where dtl.cash_receipt_id = l_cash_receipt_id
and nvl(dtl.CURRENT_ACTIVITY_FLAG, 'Y') = 'Y'
and dtl.customer_trx_line_id in
(select customer_trx_line_id
from ra_customer_trx_lines
where customer_trx_id = l_customer_trx_id);
SELECT cr.receipt_number,
cr.amount,
cr.currency_code,
rm.merchant_ref,
rc.creation_status,
ba.bank_branch_id,
ba.bank_account_num,
ba.bank_account_name,
ba.inactive_date,
cr.unique_reference --bug 3672953
FROM ar_cash_receipts cr,
ar_receipt_methods rm,
ar_receipt_classes rc,
ap_bank_accounts ba
WHERE cr.cash_receipt_id = p_cash_receipt_id
AND cr.customer_bank_account_id = ba.bank_account_id
AND cr.receipt_method_id = rm.receipt_method_id
and rm.receipt_class_id = rc.receipt_class_id;
select 'ARI_'||ar_payment_server_ord_num_s.nextval
into l_payment_server_order_num
from dual;
ARP_CASH_RECEIPTS_PKG.update_p(l_cr_rec, p_cash_receipt_id);
arp_standard.debug('Apply: ' || 'CR rec updated with payment server auth code');
SELECT cr.receipt_number,
cr.amount,
cr.currency_code,
rm.PAYMENT_CHANNEL_CODE, /* NEW ADDED */
rc.creation_status, /* AR USE */
cr.org_id,
party.party_id,
cr.pay_from_customer,
cr.customer_site_use_id,
cr.payment_trxn_extension_id,
cr.receipt_date
FROM ar_cash_receipts_all cr,
ar_receipt_methods rm,
ar_receipt_classes rc,
hz_cust_accounts hca,
hz_parties party
WHERE cr.cash_receipt_id = p_cash_receipt_id
AND hca.party_id = party.party_id
AND hca.cust_account_id = cr.pay_from_customer
AND cr.receipt_method_id = rm.receipt_method_id
and rm.receipt_class_id = rc.receipt_class_id;
SELECT decode(summ.status, NULL, 'N', 'Y') AUTHORIZED_FLAG
into l_auth_flag
FROM iby_trxn_summaries_all summ,
iby_fndcpt_tx_operations op
WHERE summ.transactionid = op.transactionid
AND reqtype = 'ORAPMTREQ'
AND status IN(0, 100)
AND trxntypeid IN(2, 3, 20)
AND op.trxn_extension_id = p_payment_trxn_extension_id
AND summ.trxnmid =
(SELECT MAX(trxnmid)
FROM iby_trxn_summaries_all
WHERE transactionid = summ.transactionid
AND reqtype = 'ORAPMTREQ'
AND status IN(0, 100)
AND trxntypeid IN(2, 3, 20));
select AUTHORIZATION_ID
into l_auth_id
from IBY_TRXN_EXT_AUTHS_V
where TRXN_EXTENSION_ID = p_payment_trxn_extension_id;
ARP_CASH_RECEIPTS_PKG.update_p(l_cr_rec, p_cash_receipt_id);
arp_standard.debug('CR rec updated with auth_id and auth code ');
ARP_CASH_RECEIPTS_PKG.update_p(l_cr_rec, p_cash_receipt_id);
arp_standard.debug('CR rec updated with auth_id and auth code ');
SELECT party.party_id
INTO l_party_id
FROM hz_cust_accounts hca,
hz_parties party
WHERE hca.party_id = party.party_id
AND hca.cust_account_id = l_customer_id ;
SELECT payment_channel_code
INTO l_pmt_channel_code
from ar_receipt_methods
where receipt_method_id = l_receipt_method_id;
SELECT INSTR_ASSIGNMENT_ID
INTO l_assignment_id
from iby_fndcpt_tx_extensions
where trxn_extension_id = l_payment_trxn_extension_id;
SELECT INSTR_ASSIGNMENT_ID
into l_assignment_id
FROM iby_fndcpt_tx_extensions
where trxn_extension_id = l_init_extension_id;
SELECT party.party_id
INTO l_party_id
FROM hz_cust_accounts hca,
hz_parties party
WHERE hca.party_id = party.party_id
AND hca.cust_account_id = l_customer_id ;
SELECT payment_channel_code
INTO l_payment_channel_code
from ar_receipt_methods
where receipt_method_id = p_receipt_method_id;
arp_standard.debug(to_char(SQL%ROWCOUNT) || 'PMT_EXTN_ID row(s) updated.');
delete from ar_activity_details
where cash_receipt_id = l_cash_receipt_id;
INSERT INTO AR_ACTIVITY_DETAILS(
CASH_RECEIPT_ID,
CUSTOMER_TRX_LINE_ID,
ALLOCATED_RECEIPT_AMOUNT,
AMOUNT,
TAX,
FREIGHT,
CHARGES,
LAST_UPDATE_DATE,
LAST_UPDATED_BY,
LINE_DISCOUNT,
TAX_DISCOUNT,
FREIGHT_DISCOUNT,
LINE_BALANCE,
TAX_BALANCE,
CREATION_DATE,
CREATED_BY,
LAST_UPDATE_LOGIN,
COMMENTS,
APPLY_TO,
ATTRIBUTE1,
ATTRIBUTE2,
ATTRIBUTE3,
ATTRIBUTE4,
ATTRIBUTE5,
ATTRIBUTE6,
ATTRIBUTE7,
ATTRIBUTE8,
ATTRIBUTE9,
ATTRIBUTE10,
ATTRIBUTE11,
ATTRIBUTE12,
ATTRIBUTE13,
ATTRIBUTE14,
ATTRIBUTE15,
ATTRIBUTE_CATEGORY,
GROUP_ID,
REFERENCE1,
REFERENCE2,
REFERENCE3,
REFERENCE4,
REFERENCE5,
OBJECT_VERSION_NUMBER,
CREATED_BY_MODULE,
SOURCE_ID,
SOURCE_TABLE,
LINE_ID,
CURRENT_ACTIVITY_FLAG)
SELECT
LLD.CASH_RECEIPT_ID,
LLD.CUSTOMER_TRX_LINE_ID,
LLD.ALLOCATED_RECEIPT_AMOUNT*-1,
LLD.AMOUNT*-1,
LLD.TAX*-1,
LLD.FREIGHT*-1,
LLD.CHARGES*-1,
LLD.LAST_UPDATE_DATE,
LLD.LAST_UPDATED_BY,
LLD.LINE_DISCOUNT,
LLD.TAX_DISCOUNT,
LLD.FREIGHT_DISCOUNT,
LLD.LINE_BALANCE,
LLD.TAX_BALANCE,
LLD.CREATION_DATE,
LLD.CREATED_BY,
LLD.LAST_UPDATE_LOGIN,
LLD.COMMENTS,
LLD.APPLY_TO,
LLD.ATTRIBUTE1,
LLD.ATTRIBUTE2,
LLD.ATTRIBUTE3,
LLD.ATTRIBUTE4,
LLD.ATTRIBUTE5,
LLD.ATTRIBUTE6,
LLD.ATTRIBUTE7,
LLD.ATTRIBUTE8,
LLD.ATTRIBUTE9,
LLD.ATTRIBUTE10,
LLD.ATTRIBUTE11,
LLD.ATTRIBUTE12,
LLD.ATTRIBUTE13,
LLD.ATTRIBUTE14,
LLD.ATTRIBUTE15,
LLD.ATTRIBUTE_CATEGORY,
LLD.GROUP_ID,
LLD.REFERENCE1,
LLD.REFERENCE2,
LLD.REFERENCE3,
LLD.REFERENCE4,
LLD.REFERENCE5,
LLD.OBJECT_VERSION_NUMBER,
LLD.CREATED_BY_MODULE,
LLD.SOURCE_ID,
LLD.SOURCE_TABLE,
ar_Activity_details_s.nextval,
'R'
FROM ar_Activity_details LLD
where LLD.cash_receipt_id = l_cash_receipt_id
and nvl(LLD.CURRENT_ACTIVITY_FLAG, 'Y') = 'Y';
UPDATE ar_Activity_details dtl
set CURRENT_ACTIVITY_FLAG = 'N'
where dtl.cash_receipt_id = l_cash_receipt_id
and nvl(dtl.CURRENT_ACTIVITY_FLAG, 'Y') = 'Y';
SELECT applied_payment_schedule_id
, secondary_application_ref_id
, amount_applied
INTO l_applied_ps_id
, l_sec_app_ref_id
, l_amount_applied
FROM ar_receivable_applications
WHERE receivable_application_id = p_receivable_application_id;
/* Bug 4170060 do not update with claim balance for partial
rct to rct applications */
IF (NVL(p_called_from,'RAPI') = 'APPLY_OPEN_RECEIPT' AND
NVL(pg_update_claim_amount,0) <> 0) THEN
NULL;
arp_process_application.update_claim(
p_claim_id => l_sec_app_ref_id
, p_invoice_ps_id => NULL
, p_customer_trx_id => NULL
, p_amount => 0
, p_amount_applied => l_amount_applied
, p_apply_date => trunc(SYSDATE)
, p_cash_receipt_id => l_cash_receipt_id
, p_receipt_number => l_receipt_number
, p_action_type => 'U'
, x_claim_reason_code_id => l_claim_reason_code_id
, x_claim_reason_name => l_claim_reason_name
, x_claim_number => l_claim_number
, x_return_status => l_clm_return_status
, x_msg_count => x_msg_count
, x_msg_data => x_msg_data);
SELECT applied_payment_schedule_id, application_ref_id
INTO l_applied_ps_id, l_application_ref_id
FROM ar_receivable_applications
WHERE receivable_application_id = l_receivable_application_id;
/* 5955921 Replaced select statement */
SELECT tax_account_ccid
INTO l_tax_account_id
FROM zx_accounts
WHERE tax_account_entity_id = l_vat_tax_id
AND tax_account_entity_code = 'RATES'
AND internal_organization_id = l_org_id;
/*SELECT tax_account_id
INTO l_tax_account_id
FROM ar_vat_tax
WHERE vat_tax_id = l_vat_tax_id;*/
select pay_from_customer,customer_site_use_id
into l_customer_id,l_customer_site_use_id
from ar_cash_receipts
--where payment_trxn_extension_id = l_payment_trxn_extension_id;
arp_process_misc_receipts.insert_misc_receipt(
p_currency_code
=> l_currency_code,
p_amount
=> p_amount,
p_receivables_trx_id
=> l_receivables_trx_id,
p_misc_payment_source
=> p_misc_payment_source,
p_receipt_number
=> l_receipt_number,
p_receipt_date
=> l_receipt_date,
p_gl_date
=> l_gl_date,
p_comments
=> p_comments,
p_exchange_rate_type
=> l_exchange_rate_type,
p_exchange_rate
=> l_exchange_rate,
p_exchange_date
=> l_exchange_date,
p_batch_id
=> null,
p_attribute_category
=> l_attribute_rec.attribute_category,
p_attribute1
=> l_attribute_rec.attribute1,
p_attribute2
=> l_attribute_rec.attribute2,
p_attribute3
=> l_attribute_rec.attribute3,
p_attribute4
=> l_attribute_rec.attribute4,
p_attribute5
=> l_attribute_rec.attribute5,
p_attribute6
=> l_attribute_rec.attribute6,
p_attribute7
=> l_attribute_rec.attribute7,
p_attribute8
=> l_attribute_rec.attribute8,
p_attribute9
=> l_attribute_rec.attribute9,
p_attribute10
=> l_attribute_rec.attribute10,
p_attribute11
=> l_attribute_rec.attribute11,
p_attribute12
=> l_attribute_rec.attribute12,
p_attribute13
=> l_attribute_rec.attribute13,
p_attribute14
=> l_attribute_rec.attribute14,
p_attribute15
=> l_attribute_rec.attribute15,
p_remittance_bank_account_id
=> l_remit_bank_acct_use_id,
p_deposit_date
=> l_deposit_date,
p_receipt_method_id
=> l_receipt_method_id,
p_doc_sequence_value
=> l_doc_sequence_value,
p_doc_sequence_id
=> l_doc_sequence_id,
p_distribution_set_id
=> l_distribution_set_id,
p_reference_type
=> p_reference_type,
p_reference_id
=> l_reference_id,
p_vat_tax_id
=> l_vat_tax_id,
p_ussgl_transaction_code
=> p_ussgl_transaction_code,
p_anticipated_clearing_date
=> l_anticipated_clearing_date, /* Bug fix 3135407 */
p_global_attribute1
=> l_global_attribute_rec.global_attribute1,
p_global_attribute2
=> l_global_attribute_rec.global_attribute2,
p_global_attribute3
=> l_global_attribute_rec.global_attribute3,
p_global_attribute4
=> l_global_attribute_rec.global_attribute4,
p_global_attribute5
=> l_global_attribute_rec.global_attribute5,
p_global_attribute6
=> l_global_attribute_rec.global_attribute6,
p_global_attribute7
=> l_global_attribute_rec.global_attribute7,
p_global_attribute8
=> l_global_attribute_rec.global_attribute8,
p_global_attribute9
=> l_global_attribute_rec.global_attribute9,
p_global_attribute10
=> l_global_attribute_rec.global_attribute10,
p_global_attribute11
=> l_global_attribute_rec.global_attribute11,
p_global_attribute12
=> l_global_attribute_rec.global_attribute12,
p_global_attribute13
=> l_global_attribute_rec.global_attribute13,
p_global_attribute14
=> l_global_attribute_rec.global_attribute14,
p_global_attribute15
=> l_global_attribute_rec.global_attribute15,
p_global_attribute16
=> l_global_attribute_rec.global_attribute16,
p_global_attribute17
=> l_global_attribute_rec.global_attribute17,
p_global_attribute18
=> l_global_attribute_rec.global_attribute18,
p_global_attribute19
=> l_global_attribute_rec.global_attribute19,
p_global_attribute20
=> l_global_attribute_rec.global_attribute20,
p_global_attribute_category
=> l_global_attribute_rec.global_attribute_category,
p_cr_id
=> p_misc_receipt_id,
p_row_id
=> l_row_id,
p_form_name
=> 'RAPI',
p_form_version
=> p_api_version,
p_tax_rate
=> l_tax_rate,
p_gl_tax_acct
=> l_tax_account_id ,/* Bug fix 2300268 */
p_crh_id
=> l_crh_id, /* Bug fix 2742388 */
p_legal_entity_id => l_legal_entity_id, /* R12 LE uptake */
p_payment_trxn_extension_id => l_copy_pmt_trxn_extension_id
);
'ARP_PROCESS_MISC_RECEIPTS.INSERT_MISC_RECEIPT : '||SQLERRM);
pg_update_claim_amount := l_reapply_amount * -1; /* Bug 4170060 */
arp_app_pkg.update_p(l_app_rec);
arp_app_pkg.update_p(l_app_rec);