The following lines contain the word 'select', 'insert', 'update' or 'delete':
PROCEDURE INSERT_ROW (
p_trx_header_id IN NUMBER,
x_errmsg OUT NOCOPY VARCHAR2,
x_return_status OUT NOCOPY VARCHAR2 ) IS
l_pmt_trxn_id NUMBER;
ar_invoice_utils.debug ('AR_TRX_BULK_PROCESS_HEADER.INSERT_ROW (+)');
arp_util.debug ( 'insert header ' || p_trx_header_id );
select payment_trxn_extension_id
into l_pmt_trxn_id
FROM ar_trx_header_gt
WHERE trx_header_id = nvl(p_trx_header_id, trx_header_id);
arp_util.debug ( 'insert header ' || p_trx_header_id );
arp_util.debug ( 'insert header trxn _id ' || l_pmt_trxn_id );
INSERT INTO ra_customer_trx (
customer_trx_id,
trx_number,
created_by,
creation_date,
last_updated_by,
last_update_date,
last_update_login,
set_of_books_id,
program_application_id,
program_id,
program_update_date,
posting_control_id,
ra_post_loop_number,
complete_flag,
related_customer_trx_id,
cust_trx_type_id,
batch_id,
batch_source_id,
agreement_id,
trx_date,
bill_to_customer_id,
bill_to_contact_id,
bill_to_site_use_id,
ship_to_customer_id,
ship_to_contact_id,
ship_to_site_use_id,
sold_to_customer_id,
sold_to_site_use_id,
sold_to_contact_id,
customer_reference,
customer_reference_date,
credit_method_for_installments,
credit_method_for_rules,
start_date_commitment,
end_date_commitment,
exchange_date,
exchange_rate,
exchange_rate_type,
customer_bank_account_id,
finance_charges,
fob_point,
comments,
internal_notes,
invoice_currency_code,
invoicing_rule_id,
orig_system_batch_name,
primary_salesrep_id,
printing_count,
printing_last_printed,
printing_option,
printing_original_date,
printing_pending,
purchase_order,
purchase_order_date,
purchase_order_revision,
receipt_method_id,
remit_to_address_id,
shipment_id,
ship_date_actual,
ship_via,
term_due_date,
term_id,
territory_id,
waybill_number,
status_trx,
reason_code,
doc_sequence_id,
doc_sequence_value,
paying_customer_id,
paying_site_use_id,
default_tax_exempt_flag,
created_from,
default_ussgl_trx_code_context,
default_ussgl_transaction_code,
old_trx_number,
interface_header_context,
interface_header_attribute1,
interface_header_attribute2,
interface_header_attribute3,
interface_header_attribute4,
interface_header_attribute5,
interface_header_attribute6,
interface_header_attribute7,
interface_header_attribute8,
interface_header_attribute9,
interface_header_attribute10,
interface_header_attribute11,
interface_header_attribute12,
interface_header_attribute13,
interface_header_attribute14,
interface_header_attribute15,
attribute_category,
attribute1,
attribute2,
attribute3,
attribute4,
attribute5,
attribute6,
attribute7,
attribute8,
attribute9,
attribute10,
attribute11,
attribute12,
attribute13,
attribute14,
attribute15,
br_amount,
br_unpaid_flag,
br_on_hold_flag,
drawee_id,
drawee_contact_id,
drawee_site_use_id,
drawee_bank_account_id,
remit_bank_acct_use_id,
override_remit_account_flag,
special_instructions,
remittance_batch_id,
address_verification_code,
approval_code,
bill_to_address_id,
edi_processed_flag,
edi_processed_status,
payment_server_order_num,
post_request_id,
request_id,
ship_to_address_id,
global_attribute_category,
global_attribute1,
global_attribute2,
global_attribute3,
global_attribute4,
global_attribute5,
global_attribute6,
global_attribute7,
global_attribute8,
global_attribute9,
global_attribute10,
global_attribute11,
global_attribute12,
global_attribute13,
global_attribute14,
global_attribute15,
global_attribute16,
global_attribute17,
global_attribute18,
global_attribute19,
global_attribute20,
global_attribute21,
global_attribute22,
global_attribute23,
global_attribute24,
global_attribute25,
global_attribute26,
global_attribute27,
global_attribute28,
global_attribute29,
global_attribute30,
ct_reference,org_id,
legal_entity_id,
payment_trxn_extension_id,
billing_date
-- Late Charges
,interest_header_id
,late_charges_assessed
)
SELECT customer_trx_id,
trx_number,
created_by,
creation_date,
last_updated_by,
last_update_date,
last_update_login,
set_of_books_id,
program_application_id,
program_id,
program_update_date,
posting_control_id,
ra_post_loop_number,
'Y', -- 5921925
RELATED_CUSTOMER_TRX_ID,
cust_trx_type_id,
batch_id,
batch_source_id,
agreement_id,
trx_date,
bill_to_customer_id,
bill_to_contact_id,
bill_to_site_use_id,
ship_to_customer_id,
ship_to_contact_id,
ship_to_site_use_id,
sold_to_customer_id,
sold_to_site_use_id,
sold_to_contact_id,
customer_reference,
customer_reference_date,
credit_method_for_installments,
credit_method_for_rules,
start_date_commitment,
end_date_commitment,
exchange_date,
exchange_rate,
exchange_rate_type,
customer_bank_account_id,
finance_charges,
fob_point,
comments,
internal_notes,
trx_currency,
invoicing_rule_id,
orig_system_batch_name,
primary_salesrep_id,
printing_count,
printing_last_printed,
printing_option,
printing_original_date,
printing_pending,
purchase_order,
purchase_order_date,
purchase_order_revision,
receipt_method_id,
remit_to_address_id,
shipment_id,
ship_date_actual,
ship_via,
term_due_date,
term_id,
territory_id,
waybill_number,
status_trx,
reason_code,
doc_sequence_id,
doc_sequence_value,
nvl(paying_customer_id,bill_to_customer_id),
paying_site_use_id,
default_tax_exempt_flag,
created_from,
default_ussgl_trx_code_context,
default_ussgl_transaction_code,
old_trx_number,
interface_header_context,
interface_header_attribute1,
interface_header_attribute2,
interface_header_attribute3,
interface_header_attribute4,
interface_header_attribute5,
interface_header_attribute6,
interface_header_attribute7,
interface_header_attribute8,
interface_header_attribute9,
interface_header_attribute10,
interface_header_attribute11,
interface_header_attribute12,
interface_header_attribute13,
interface_header_attribute14,
interface_header_attribute15,
attribute_category,
attribute1,
attribute2,
attribute3,
attribute4,
attribute5,
attribute6,
attribute7,
attribute8,
attribute9,
attribute10,
attribute11,
attribute12,
attribute13,
attribute14,
attribute15,
br_amount,
br_unpaid_flag,
br_on_hold_flag,
drawee_id,
drawee_contact_id,
drawee_site_use_id,
drawee_bank_account_id,
-- will leave the column name alone for gts
remittance_bank_account_id,
override_remit_account_flag,
special_instructions,
remittance_batch_id,
address_verification_code,
approval_code,
bill_to_address_id,
edi_processed_flag,
edi_processed_status,
payment_server_order_num,
post_request_id,
request_id,
ship_to_address_id,
global_attribute_category,
global_attribute1,
global_attribute2,
global_attribute3,
global_attribute4,
global_attribute5,
global_attribute6,
global_attribute7,
global_attribute8,
global_attribute9,
global_attribute10,
global_attribute11,
global_attribute12,
global_attribute13,
global_attribute14,
global_attribute15,
global_attribute16,
global_attribute17,
global_attribute18,
global_attribute19,
global_attribute20,
global_attribute21,
global_attribute22,
global_attribute23,
global_attribute24,
global_attribute25,
global_attribute26,
global_attribute27,
global_attribute28,
global_attribute29,
global_attribute30,
ct_reference,arp_standard.sysparm.org_id,
legal_entity_id,
payment_trxn_extension_id,
billing_date
-- Late Charges
,interest_header_id
,late_charges_assessed
FROM ar_trx_header_gt
WHERE trx_header_id = nvl(p_trx_header_id, trx_header_id);
ar_invoice_utils.debug ('AR_TRX_BULK_PROCESS_HEADER.INSERT_ROW (+)');
x_errmsg := 'Error in AR_TRX_BULK_PROCESS_HEADER.INSERT_ROW '||sqlerrm;
END INSERT_ROW;