DBA Data[Home] [Help]

APPS.AR_PURGE dependencies on RA_CUSTOMER_TRX

Line 750: ra_customer_trx ct_prev,

746: iby_trxn_extensions_v iby,
747: ra_salesreps sales,
748: ra_terms term,
749: ra_cust_trx_line_gl_dist ctlgd,
750: ra_customer_trx ct_prev,
751: ra_customer_trx ct
752: WHERE lu.lookup_code (+) = ct.reason_code
753: AND lu.lookup_type (+) = 'INVOICING_REASON'
754: AND iby.trxn_extension_id(+) = ct.payment_trxn_extension_id

Line 751: ra_customer_trx ct

747: ra_salesreps sales,
748: ra_terms term,
749: ra_cust_trx_line_gl_dist ctlgd,
750: ra_customer_trx ct_prev,
751: ra_customer_trx ct
752: WHERE lu.lookup_code (+) = ct.reason_code
753: AND lu.lookup_type (+) = 'INVOICING_REASON'
754: AND iby.trxn_extension_id(+) = ct.payment_trxn_extension_id
755: AND rule.rule_id (+) = ct.invoicing_rule_id

Line 913: ra_customer_trx ct

909: ar_lookups lu,
910: ar_adjustments adj,
911: hz_cust_accounts cust,
912: hz_parties cust_party,
913: ra_customer_trx ct
914: WHERE lu.lookup_code (+) = adj.reason_code
915: AND lu.lookup_type (+) = 'ADJUST_REASON'
916: AND ctt.cust_trx_type_id = ct.cust_trx_type_id
917: AND doc.doc_sequence_id (+) = adj.doc_sequence_id

Line 1658: ra_customer_trx_lines ctl,

1654: ra_rules rule1,
1655: ra_cust_trx_types ctt_prev,
1656: ra_cust_trx_types ctt,
1657: mtl_system_items mtl,
1658: ra_customer_trx_lines ctl,
1659: ra_customer_trx ct_prev,
1660: ra_customer_trx ct,
1661: ar_deferred_lines dl
1662: WHERE te.tax_exemption_id (+) = ctl.tax_exemption_id

Line 1659: ra_customer_trx ct_prev,

1655: ra_cust_trx_types ctt_prev,
1656: ra_cust_trx_types ctt,
1657: mtl_system_items mtl,
1658: ra_customer_trx_lines ctl,
1659: ra_customer_trx ct_prev,
1660: ra_customer_trx ct,
1661: ar_deferred_lines dl
1662: WHERE te.tax_exemption_id (+) = ctl.tax_exemption_id
1663: AND te.reason_code = lu_te.lookup_code (+)

Line 1660: ra_customer_trx ct,

1656: ra_cust_trx_types ctt,
1657: mtl_system_items mtl,
1658: ra_customer_trx_lines ctl,
1659: ra_customer_trx ct_prev,
1660: ra_customer_trx ct,
1661: ar_deferred_lines dl
1662: WHERE te.tax_exemption_id (+) = ctl.tax_exemption_id
1663: AND te.reason_code = lu_te.lookup_code (+)
1664: AND lu_te.lookup_type (+) = 'TAX_REASON'

Line 1798: ra_customer_trx ct

1794: '' /* override_auto_accounting_flag */
1795: FROM
1796: ra_cust_trx_types ctt,
1797: ra_cust_trx_line_gl_dist ctlgd,
1798: ra_customer_trx ct
1799: WHERE ctt.cust_trx_type_id = ct.cust_trx_type_id
1800: AND ctlgd.customer_trx_id = ct.customer_trx_id
1801: AND ctlgd.account_set_flag <> 'Y' /* no acount sets */
1802: AND decode(ctlgd.account_class, 'REC',

Line 1918: ra_customer_trx ct,

1914: to_date(null), /* expiration_date */
1915: to_number(null), /* expiration_days */
1916: '' /* override_auto_accounting_flag */
1917: FROM ra_cust_trx_types ctt,
1918: ra_customer_trx ct,
1919: ar_adjustments adj
1920: WHERE adj.customer_trx_id = cp_customer_trx_id
1921: and adj.customer_trx_id = ct.customer_trx_id
1922: and ctt.cust_trx_type_id = ct.cust_trx_type_id

Line 2036: ra_customer_trx_lines ctl,

2032: lc.expiration_date, /* expiration_date */
2033: lc.expiration_days, /* expiration_days */
2034: '' /* override_auto_accounting_flag */
2035: FROM
2036: ra_customer_trx_lines ctl,
2037: ar_line_conts lc
2038: WHERE cp_customer_trx_id = ctl.customer_trx_id
2039: and ctl.customer_trx_line_id = lc.customer_trx_line_id
2040: and cp_archive_level <> 'H'

Line 2290: ra_customer_trx ct

2286: ra_cust_trx_types ctt,
2287: ar_payment_schedules ps,
2288: ar_cash_receipts cr,
2289: ar_receivable_applications ra,
2290: ra_customer_trx ct
2291: WHERE ctt.cust_trx_type_id = ct.cust_trx_type_id
2292: and ps.payment_schedule_id (+) = ra.applied_payment_schedule_id
2293: and cr.cash_receipt_id = ra.cash_receipt_id
2294: and ra.applied_customer_trx_id = ct.customer_trx_id

Line 2422: ra_customer_trx ct_cm,

2418: to_number(null), /* expiration_days */
2419: '' /* override_auto_accounting_flag */
2420: FROM
2421: ra_cust_trx_types ctt_cm,
2422: ra_customer_trx ct_cm,
2423: ra_cust_trx_types ctt_inv,
2424: ar_receivable_applications ra,
2425: ra_customer_trx ct_inv
2426: WHERE ctt_cm.cust_trx_type_id = ct_cm.cust_trx_type_id

Line 2425: ra_customer_trx ct_inv

2421: ra_cust_trx_types ctt_cm,
2422: ra_customer_trx ct_cm,
2423: ra_cust_trx_types ctt_inv,
2424: ar_receivable_applications ra,
2425: ra_customer_trx ct_inv
2426: WHERE ctt_cm.cust_trx_type_id = ct_cm.cust_trx_type_id
2427: AND ra.applied_customer_trx_id = ct_inv.customer_trx_id
2428: AND ra.customer_trx_id = ct_cm.customer_trx_id
2429: -- bug3948805 removed

Line 2428: AND ra.customer_trx_id = ct_cm.customer_trx_id

2424: ar_receivable_applications ra,
2425: ra_customer_trx ct_inv
2426: WHERE ctt_cm.cust_trx_type_id = ct_cm.cust_trx_type_id
2427: AND ra.applied_customer_trx_id = ct_inv.customer_trx_id
2428: AND ra.customer_trx_id = ct_cm.customer_trx_id
2429: -- bug3948805 removed
2430: -- AND ct_cm.previous_customer_trx_id = ct_inv.customer_trx_id
2431: AND ctt_inv.cust_trx_type_id = ct_inv.cust_trx_type_id
2432: AND ctt_inv.type <> 'CM'

Line 2922: from ra_customer_trx trx

2918: /* bug1999155: Divided select stmt which lock all transactions
2919: records into the following stmts */
2920: cursor trx_cur is
2921: SELECT 'Found' record_found
2922: from ra_customer_trx trx
2923: WHERE trx.customer_trx_id = p_entity_id
2924: FOR UPDATE OF trx.customer_trx_id NOWAIT;
2925:
2926: cursor trx_line_cur is

Line 2928: from ra_customer_trx_lines lines

2924: FOR UPDATE OF trx.customer_trx_id NOWAIT;
2925:
2926: cursor trx_line_cur is
2927: SELECT 'Found' record_found
2928: from ra_customer_trx_lines lines
2929: WHERE lines.customer_trx_id = p_entity_id
2930: FOR UPDATE OF lines.customer_trx_id NOWAIT;
2931:
2932: cursor dist_cur is

Line 2954: FOR UPDATE OF ra.customer_trx_id NOWAIT;

2950: cursor recv_app_cur is
2951: SELECT 'Found' record_found
2952: from ar_receivable_applications ra
2953: WHERE ra.applied_customer_trx_id = p_entity_id
2954: FOR UPDATE OF ra.customer_trx_id NOWAIT;
2955:
2956: cursor pay_sched_cur is
2957: SELECT 'Found' record_found
2958: from ar_payment_schedules ps

Line 2973: ra_customer_trx_lines lines,

2969: ar_receivable_applications ra,
2970: ar_payment_schedules ps,
2971: ar_adjustments adj,
2972: ra_cust_trx_line_gl_dist dist,
2973: ra_customer_trx_lines lines,
2974: ra_customer_trx trx
2975: WHERE trx.customer_trx_id = p_entity_id
2976: AND trx.customer_trx_id = lines.customer_trx_id
2977: AND trx.customer_trx_id = dist.customer_trx_id (+)

Line 2974: ra_customer_trx trx

2970: ar_payment_schedules ps,
2971: ar_adjustments adj,
2972: ra_cust_trx_line_gl_dist dist,
2973: ra_customer_trx_lines lines,
2974: ra_customer_trx trx
2975: WHERE trx.customer_trx_id = p_entity_id
2976: AND trx.customer_trx_id = lines.customer_trx_id
2977: AND trx.customer_trx_id = dist.customer_trx_id (+)
2978: AND trx.customer_trx_id = sales.customer_trx_id (+)

Line 2987: ra.customer_trx_id,

2983: lines.customer_trx_id,
2984: dist.customer_trx_id,
2985: sales.customer_trx_id,
2986: adj.customer_trx_id,
2987: ra.customer_trx_id,
2988: ps.customer_trx_id NOWAIT
2989: )
2990: LOOP
2991: l_record_found := lock_rec.record_found ;

Line 3052: FROM ra_customer_trx ct,

3048: l_commitment_transactions NUMBER;
3049: BEGIN
3050: SELECT COUNT(*)
3051: INTO l_commitment_transactions
3052: FROM ra_customer_trx ct,
3053: ra_cust_trx_types ctt
3054: WHERE ct.customer_trx_id = p_entity_id
3055: AND ctt.cust_trx_type_id = ct.cust_trx_type_id
3056: AND

Line 3075: l_initial_customer_trx_id ra_customer_trx.initial_customer_trx_id%TYPE;

3071: -- bug2472294 start
3072: -- Handle non post to gl transaction
3073: DECLARE
3074: l_type ra_cust_trx_types.type%TYPE ;
3075: l_initial_customer_trx_id ra_customer_trx.initial_customer_trx_id%TYPE;
3076: l_post_to_gl ra_cust_trx_types.post_to_gl%TYPE;
3077: l_trx_date ra_customer_trx.trx_date%TYPE;
3078:
3079: BEGIN

Line 3077: l_trx_date ra_customer_trx.trx_date%TYPE;

3073: DECLARE
3074: l_type ra_cust_trx_types.type%TYPE ;
3075: l_initial_customer_trx_id ra_customer_trx.initial_customer_trx_id%TYPE;
3076: l_post_to_gl ra_cust_trx_types.post_to_gl%TYPE;
3077: l_trx_date ra_customer_trx.trx_date%TYPE;
3078:
3079: BEGIN
3080:
3081: SELECT ctt.type,

Line 3089: FROM ra_customer_trx ct,

3085: INTO l_type,
3086: l_initial_customer_trx_id,
3087: l_post_to_gl,
3088: l_trx_date
3089: FROM ra_customer_trx ct,
3090: ra_cust_trx_types ctt
3091: WHERE ct.customer_trx_id = p_entity_id
3092: AND ctt.cust_trx_type_id = ct.cust_trx_type_id ;
3093:

Line 3215: FROM ra_customer_trx

3211:
3212: BEGIN
3213: SELECT 'Y'
3214: INTO l_same_customer
3215: FROM ra_customer_trx
3216: WHERE customer_trx_id = p_entity_id
3217: AND bill_to_customer_id = p_customer_id ;
3218:
3219: EXCEPTION

Line 3259: FROM ra_customer_trx_lines

3255: l_autorule_incomplete_count NUMBER;
3256: BEGIN
3257: SELECT COUNT(*)
3258: INTO l_autorule_incomplete_count
3259: FROM ra_customer_trx_lines
3260: WHERE customer_trx_id = p_entity_id
3261: AND line_type = 'LINE'
3262: AND autorule_complete_flag = 'N';
3263: IF l_autorule_incomplete_count > 0

Line 3440: ra_customer_trx trx

3436: --
3437: SELECT bat.batch_id
3438: INTO l_batch_id
3439: FROM ra_batches bat,
3440: ra_customer_trx trx
3441: WHERE trx.customer_trx_id = p_entity_id
3442: AND trx.batch_id = bat.batch_id (+)
3443: FOR UPDATE OF bat.batch_id NOWAIT ;
3444: --

Line 3451: from ra_customer_trx

3447: --
3448: /* bug3873165 added two tables for line rev */
3449: DELETE FROM ar_line_conts
3450: WHERE customer_trx_line_id in ( select customer_trx_line_id
3451: from ra_customer_trx
3452: where customer_trx_id = p_entity_id );
3453: --
3454: DELETE FROM ar_deferred_lines
3455: WHERE customer_trx_id = p_entity_id;

Line 3457: DELETE FROM ra_customer_trx_lines

3453: --
3454: DELETE FROM ar_deferred_lines
3455: WHERE customer_trx_id = p_entity_id;
3456: --
3457: DELETE FROM ra_customer_trx_lines
3458: WHERE customer_trx_id = p_entity_id;
3459: --
3460: DELETE FROM ra_cust_trx_line_gl_dist
3461: WHERE customer_trx_id = p_entity_id

Line 3478: -- delete from RA_CUSTOMER_TRX

3474: p_key_value_list => l_gl_dist_key_value_list);*/
3475:
3476: --
3477: -- bug 1404679 : to prevent ORA-1403 error when client uses AX,
3478: -- delete from RA_CUSTOMER_TRX
3479: -- after lines and dist table are done
3480: --
3481: -- DELETE FROM ra_customer_trx
3482: -- WHERE customer_trx_id = p_entity_id;

Line 3481: -- DELETE FROM ra_customer_trx

3477: -- bug 1404679 : to prevent ORA-1403 error when client uses AX,
3478: -- delete from RA_CUSTOMER_TRX
3479: -- after lines and dist table are done
3480: --
3481: -- DELETE FROM ra_customer_trx
3482: -- WHERE customer_trx_id = p_entity_id;
3483: --
3484:
3485: -- Call table handler instead of doing direct delete to

Line 3486: -- ra_customer_Trx

3482: -- WHERE customer_trx_id = p_entity_id;
3483: --
3484:
3485: -- Call table handler instead of doing direct delete to
3486: -- ra_customer_Trx
3487:
3488: arp_ct_pkg.delete_p(p_entity_id);
3489:
3490: DELETE FROM ra_batches

Line 3493: FROM ra_customer_trx t

3489:
3490: DELETE FROM ra_batches
3491: WHERE batch_id = l_batch_id
3492: AND NOT EXISTS ( SELECT 'x'
3493: FROM ra_customer_trx t
3494: WHERE t.batch_id = l_batch_id )
3495: RETURNING batch_id
3496: BULK COLLECT INTO l_ra_batch_key_value_list;
3497:

Line 4504: ra_customer_trx ct,

4500: cp_customer_id NUMBER ,
4501: cp_max_trx_id NUMBER) IS
4502: SELECT ct.customer_trx_id customer_trx_id
4503: FROM ra_cust_trx_types ctt,
4504: ra_customer_trx ct,
4505: ar_payment_schedules ps
4506: WHERE ct.initial_customer_trx_id IS NULL
4507: AND ps.customer_trx_id = ct.customer_trx_id
4508: -- bug1199027

Line 4622: FROM RA_CUSTOMER_TRX

4618: -- by another instance when called recursively
4619: --
4620: SELECT 1
4621: INTO l_existence
4622: FROM RA_CUSTOMER_TRX
4623: WHERE customer_trx_id = l_trx_id
4624: FOR UPDATE OF customer_trx_id NOWAIT ;
4625:
4626: -- lock all the corresponding records