223: ra_cm.amount_applied,null)
224: )
225: )
226: )) cm_cl_past_due_inv_amt
227: from ra_customer_trx trx,
228: ar_payment_schedules ps,
229: ra_customer_trx prev_trx,
230: ra_cust_trx_types ctt,
231: ra_terms rt,
225: )
226: )) cm_cl_past_due_inv_amt
227: from ra_customer_trx trx,
228: ar_payment_schedules ps,
229: ra_customer_trx prev_trx,
230: ra_cust_trx_types ctt,
231: ra_terms rt,
232: ra_terms_lines rtl,
233: ar_receivable_applications_all ra_cm,
1836: FOR UPDATE;
1837:
1838: CURSOR get_prev_ctx_id (ctx_id IN NUMBER) IS
1839: select ct.previous_customer_trx_id , ctt.type
1840: from ra_customer_trx ct,
1841: ra_customer_trx prev_ct,
1842: ra_cust_trx_types ctt
1843: where ct.customer_trx_id = ctx_id
1844: and prev_ct.customer_trx_id = ct.previous_customer_trx_id
1837:
1838: CURSOR get_prev_ctx_id (ctx_id IN NUMBER) IS
1839: select ct.previous_customer_trx_id , ctt.type
1840: from ra_customer_trx ct,
1841: ra_customer_trx prev_ct,
1842: ra_cust_trx_types ctt
1843: where ct.customer_trx_id = ctx_id
1844: and prev_ct.customer_trx_id = ct.previous_customer_trx_id
1845: and prev_ct.cust_trx_type_id = ctt.cust_trx_type_id;
2179: WHERE history_id = p_hist_id;
2180:
2181: CURSOR get_prev_ctx_id (ctx_id IN NUMBER) IS
2182: select previous_customer_trx_id
2183: from ra_customer_trx
2184: where customer_trx_id = ctx_id;
2185:
2186: i INTEGER;
2187: l_key VARCHAR2(240) := p_event.GetEventKey();
6101: ra_cm.amount_applied,null)
6102: )
6103: )
6104: )) cm_cl_past_due_inv_amt
6105: from ra_customer_trx trx,
6106: ar_payment_schedules ps,
6107: ra_customer_trx prev_trx,
6108: ra_cust_trx_types ctt,
6109: ra_terms rt,
6103: )
6104: )) cm_cl_past_due_inv_amt
6105: from ra_customer_trx trx,
6106: ar_payment_schedules ps,
6107: ra_customer_trx prev_trx,
6108: ra_cust_trx_types ctt,
6109: ra_terms rt,
6110: ra_terms_lines rtl,
6111: ar_receivable_applications_all ra_cm,