DBA Data[Home] [Help]

APPS.ARPT_SQL_FUNC_UTIL dependencies on RA_CUSTOMER_TRX

Line 35: l_inv_trx_number ra_customer_trx.trx_number%type;

31: FUNCTION get_cb_invoice( p_customer_trx_id IN number,
32: p_class IN varchar2)
33: RETURN VARCHAR2 IS
34:
35: l_inv_trx_number ra_customer_trx.trx_number%type;
36:
37: BEGIN
38:
39: IF ( p_class <> 'CB' )

Line 45: FROM ra_customer_trx ct,

41: ELSE
42:
43: SELECT MAX( ct.trx_number )
44: INTO l_inv_trx_number
45: FROM ra_customer_trx ct,
46: ar_adjustments_all aa --anuj
47: WHERE aa.chargeback_customer_trx_id = p_customer_trx_id
48: and ct.org_id = aa.org_id
49: AND aa.customer_trx_id = ct.customer_trx_id;

Line 400: FROM ra_customer_trx

396: Check if it is a credit memo
397:
398: SELECT decode(previous_customer_trx_id,NULL,'N','Y')
399: INTO l_cm_flag
400: FROM ra_customer_trx
401: WHERE customer_trx_id = p_customer_trx_id;
402:
403: IF ( l_cm_flag ='Y')
404: THEN

Line 411: FROM ra_customer_trx trx,

407: SELECT decode( max(d.customer_trx_id),
408: null, 'N',
409: 'Y')
410: INTO l_rule_flag
411: FROM ra_customer_trx trx,
412: ra_cust_trx_line_gl_dist d
413: WHERE trx.customer_trx_id = p_customer_trx_id
414: and trx.previous_customer_trx_id = d.customer_trx_id
415: and d.account_class in ('UNEARN', 'UNBILL')

Line 443: FROM ra_customer_trx_lines

439: INTO l_temp_flag
440: FROM DUAL
441: WHERE EXISTS (
442: SELECT 'Revenue recognition has been run'
443: FROM ra_customer_trx_lines
444: WHERE customer_trx_id = p_customer_trx_id
445: AND autorule_duration_processed <> 0
446: );
447:

Line 758: FROM ra_customer_trx ct,

754: SELECT DECODE(ctt.type,
755: 'GUAR', 'Y',
756: 'N')
757: INTO l_activity_flag
758: FROM ra_customer_trx ct,
759: ra_cust_trx_types ctt
760: WHERE ct.cust_trx_type_id = ctt.cust_trx_type_id
761: AND ct.customer_trx_id = p_initial_customer_trx_id
762: --begin anuj

Line 794: FROM ra_customer_trx ct

790: SELECT DECODE( MAX(ct.customer_trx_id),
791: NULL, 'N',
792: 'Y')
793: INTO l_activity_flag
794: FROM ra_customer_trx ct
795: WHERE ct.initial_customer_trx_id = p_customer_trx_id;
796:
797: IF (l_activity_flag = 'Y')
798: THEN RETURN('Y');

Line 901: ra_customer_trx other_ct

897: 'Y')
898: INTO l_activity_flag
899: FROM ar_payment_schedules this_ps,
900: ar_payment_schedules other_ps,
901: ra_customer_trx other_ct
902: WHERE this_ps.customer_trx_id = p_customer_trx_id
903: AND other_ct.previous_customer_trx_id =
904: p_previous_customer_trx_id
905: AND other_ct.customer_trx_id = other_ps.customer_trx_id

Line 986: FROM ra_customer_trx_lines ctl

982: SELECT DECODE( MAX(customer_trx_line_id),
983: NULL, 'N',
984: 'Y')
985: INTO l_activity_flag
986: FROM ra_customer_trx_lines ctl
987: WHERE br_ref_customer_trx_id = p_customer_trx_id;
988:
989: IF (l_activity_flag = 'Y')
990: THEN RETURN('Y');

Line 1028: FROM ra_customer_trx

1024: /* bug 2207354 - Check if the transaction has an incomplete
1025: credit memo against it */
1026: SELECT decode (MAX(previous_customer_trx_id), NULL, 'N', 'Y')
1027: INTO l_activity_flag
1028: FROM ra_customer_trx
1029: WHERE previous_customer_trx_id = p_customer_trx_id;
1030:
1031: IF (l_activity_flag = 'Y')
1032: THEN RETURN('Y');

Line 1100: FROM ra_customer_trx ct,

1096: '14', ct.interface_header_attribute14,
1097: '15', ct.interface_header_attribute15,
1098: NULL )
1099: INTO l_temp
1100: FROM ra_customer_trx ct,
1101: ra_batch_sources bs
1102: WHERE ct.rowid = p_trx_rowid and
1103: bs.batch_source_id = ct.batch_source_id;
1104: END IF;

Line 1165: FROM ra_customer_trx_lines ctl,

1161: '14', ctl.interface_line_attribute14,
1162: '15', ctl.interface_line_attribute15,
1163: NULL )
1164: INTO l_line_temp
1165: FROM ra_customer_trx_lines ctl,
1166: ra_customer_trx ct,
1167: ra_batch_sources bs
1168: WHERE bs.batch_source_id = ct.batch_source_id and
1169: ctl.customer_trx_id = ct.customer_trx_id and

Line 1166: ra_customer_trx ct,

1162: '15', ctl.interface_line_attribute15,
1163: NULL )
1164: INTO l_line_temp
1165: FROM ra_customer_trx_lines ctl,
1166: ra_customer_trx ct,
1167: ra_batch_sources bs
1168: WHERE bs.batch_source_id = ct.batch_source_id and
1169: ctl.customer_trx_id = ct.customer_trx_id and
1170: ctl.rowid = p_line_trx_rowid ;

Line 1351: | This function is used in view ra_customer_trx_partial_v |

1347: | payment schedule record for the first due installment. If there is no |
1348: | payment schedule record, it calculates the first due date by calling |
1349: | the function Get_First_Due_Date in this package. |
1350: | |
1351: | This function is used in view ra_customer_trx_partial_v |
1352: | and was created in response to bug 486822. |
1353: | |
1354: | SCOPE - PUBLIC |
1355: | |

Line 1387: ra_customer_trx ct

1383: SELECT NVL(MIN(ps.due_date),
1384: arpt_sql_func_util.get_first_due_date(p_term_id, nvl(ct.billing_date, p_trx_date)))
1385: INTO l_term_due_date
1386: FROM ar_payment_schedules ps,
1387: ra_customer_trx ct
1388: WHERE ct.customer_trx_id=ps.customer_trx_id(+)
1389: AND ct.customer_trx_id = p_customer_trx_id
1390: group by ct.billing_date;
1391:

Line 1508: | Used by the ra_customer_trx_cr_trx_v view. |

1504: | get_territory |
1505: | |
1506: | DESCRIPTION |
1507: | Gets the territory name based on the incoming address id. |
1508: | Used by the ra_customer_trx_cr_trx_v view. |
1509: | |
1510: | SCOPE - PUBLIC |
1511: | |
1512: | EXETERNAL PROCEDURES/FUNCTIONS ACCESSED |

Line 1562: | Used by the ra_customer_trx_cm_v view. |

1558: | get_territory_rowid |
1559: | |
1560: | DESCRIPTION |
1561: | Gets the territory row id based on the incoming address id. |
1562: | Used by the ra_customer_trx_cm_v view. |
1563: | |
1564: | SCOPE - PUBLIC |
1565: | |
1566: | EXETERNAL PROCEDURES/FUNCTIONS ACCESSED |

Line 1685: FROM ra_customer_trx

1681: )
1682: THEN
1683: SELECT MAX(initial_customer_trx_id)
1684: INTO l_ct_prev_initial_cust_trx_id
1685: FROM ra_customer_trx
1686: WHERE customeR_trx_id = p_previous_customer_trx_id;
1687: ELSE
1688: l_ct_prev_initial_cust_trx_id := p_ct_prev_initial_cust_trx_id;
1689: END IF;

Line 1706: ra_customer_trx trx

1702: so_agreements soa,
1703: hz_cust_acct_sites acct_site,
1704: ra_cust_trx_types inv_type,
1705: ra_cust_trx_types type,
1706: ra_customer_trx trx
1707: WHERE trx.cust_trx_type_id = type.cust_trx_type_id
1708: AND trx.bill_to_customer_id = cust_acct.cust_account_id
1709: AND trx.remit_to_address_id = acct_site.cust_acct_site_id(+)
1710: AND 'A' = acct_site.status(+)

Line 1922: l_customer_trx_id ra_customer_trx.customer_trx_id%type;

1918: )
1919: RETURN VARCHAR2 is
1920:
1921: l_bs_name ra_batch_sources.name%type;
1922: l_customer_trx_id ra_customer_trx.customer_trx_id%type;
1923:
1924: BEGIN
1925:
1926: IF ( p_class <> 'CB' ) THEN

Line 1937: from ra_customer_trx ct,

1933: +------------------------------------------------------------------------------------*/
1934:
1935: select bs.name
1936: into l_bs_name
1937: from ra_customer_trx ct,
1938: ra_batch_sources bs
1939: where ct.batch_source_id = bs.batch_source_id
1940: and ct.org_id = bs.org_id --anuj
1941: and ct.customer_trx_id = (select max(ctt.customer_trx_id)

Line 1942: from ra_customer_trx ctt,

1938: ra_batch_sources bs
1939: where ct.batch_source_id = bs.batch_source_id
1940: and ct.org_id = bs.org_id --anuj
1941: and ct.customer_trx_id = (select max(ctt.customer_trx_id)
1942: from ra_customer_trx ctt,
1943: ar_adjustments aa
1944: where aa.chargeback_customer_trx_id = p_customer_trx_id
1945: and aa.org_id = ctt.org_id --anuj
1946: and aa.customer_trx_id = ctt.customer_trx_id

Line 2617: FROM ra_customer_trx_lines

2613: BEGIN
2614:
2615: SELECT NVL(SUM(extended_amount),0)
2616: INTO l_total
2617: FROM ra_customer_trx_lines
2618: WHERE line_type = p_line_type
2619: AND customer_trx_id = p_customer_trx_id;
2620:
2621: return l_total;