DBA Data[Home] [Help]

APPS.BIC_SUMMARY_EXTRACT_PKG dependencies on HZ_CUST_ACCOUNTS

Line 1311: from hz_cust_accounts

1307:
1308: procedure retention_churned is
1309: cursor party_cur is
1310: select party_id, min(nvl(account_established_date,creation_date))
1311: from hz_cust_accounts
1312: group by party_id;
1313: x_party_id hz_cust_accounts.party_id % type;
1314: x_account_established_date hz_cust_accounts.account_established_date % type;
1315: begin

Line 1313: x_party_id hz_cust_accounts.party_id % type;

1309: cursor party_cur is
1310: select party_id, min(nvl(account_established_date,creation_date))
1311: from hz_cust_accounts
1312: group by party_id;
1313: x_party_id hz_cust_accounts.party_id % type;
1314: x_account_established_date hz_cust_accounts.account_established_date % type;
1315: begin
1316: g_proc_name_old := g_proc_name;
1317: g_proc_name := 'Retention_churned';

Line 1314: x_account_established_date hz_cust_accounts.account_established_date % type;

1310: select party_id, min(nvl(account_established_date,creation_date))
1311: from hz_cust_accounts
1312: group by party_id;
1313: x_party_id hz_cust_accounts.party_id % type;
1314: x_account_established_date hz_cust_accounts.account_established_date % type;
1315: begin
1316: g_proc_name_old := g_proc_name;
1317: g_proc_name := 'Retention_churned';
1318: debug(' entered +');

Line 1378: from hz_cust_accounts

1374:
1375: procedure retention_retained is
1376: cursor party_cur is
1377: select party_id, min(nvl(account_established_date,creation_date))
1378: from hz_cust_accounts
1379: group by party_id;
1380: x_party_id hz_cust_accounts.party_id % type;
1381: x_account_established_date hz_cust_accounts.account_established_date % type;
1382: begin

Line 1380: x_party_id hz_cust_accounts.party_id % type;

1376: cursor party_cur is
1377: select party_id, min(nvl(account_established_date,creation_date))
1378: from hz_cust_accounts
1379: group by party_id;
1380: x_party_id hz_cust_accounts.party_id % type;
1381: x_account_established_date hz_cust_accounts.account_established_date % type;
1382: begin
1383: g_proc_name_old := g_proc_name;
1384: g_proc_name := 'retention_retained';

Line 1381: x_account_established_date hz_cust_accounts.account_established_date % type;

1377: select party_id, min(nvl(account_established_date,creation_date))
1378: from hz_cust_accounts
1379: group by party_id;
1380: x_party_id hz_cust_accounts.party_id % type;
1381: x_account_established_date hz_cust_accounts.account_established_date % type;
1382: begin
1383: g_proc_name_old := g_proc_name;
1384: g_proc_name := 'retention_retained';
1385:

Line 1437: hz_cust_accounts hca

1433: between trunc(add_months(g_period_start_date,g_attrition_period*-1)) and trunc(g_period_end_date)
1434: and x_account_established_date
1435: <= add_months(bdt.act_period_end_date, g_attrition_period*-1)
1436: and exists (select 'x' from oe_order_headers_all oeh,
1437: hz_cust_accounts hca
1438: where oeh.sold_to_org_id = hca.cust_account_id
1439: and hca.party_id = x_party_id
1440: and ordered_date between add_months(bdt.act_period_end_date,
1441: g_attrition_period*-1)+1

Line 1446: hz_cust_accounts hca

1442: and bdt.act_period_end_date
1443: )
1444: and (exists
1445: (select 'x' from oe_order_headers_all oeh,
1446: hz_cust_accounts hca
1447: where oeh.sold_to_org_id = hca.cust_account_id
1448: and hca.party_id = x_party_id
1449: and ordered_date between add_months(bdt.act_period_end_date,
1450: g_attrition_period*-2)+1

Line 1477: from hz_cust_accounts

1473: -- This procedure inserts reactivated customers
1474: procedure retention_reactivated is
1475: cursor party_cur is
1476: select party_id, min(nvl(account_established_date,creation_date))
1477: from hz_cust_accounts
1478: group by party_id;
1479: x_party_id hz_cust_accounts.party_id % type;
1480: x_account_established_date hz_cust_accounts.account_established_date % type;
1481: begin

Line 1479: x_party_id hz_cust_accounts.party_id % type;

1475: cursor party_cur is
1476: select party_id, min(nvl(account_established_date,creation_date))
1477: from hz_cust_accounts
1478: group by party_id;
1479: x_party_id hz_cust_accounts.party_id % type;
1480: x_account_established_date hz_cust_accounts.account_established_date % type;
1481: begin
1482: g_proc_name_old := g_proc_name;
1483: g_proc_name := 'retention_reactivated';

Line 1480: x_account_established_date hz_cust_accounts.account_established_date % type;

1476: select party_id, min(nvl(account_established_date,creation_date))
1477: from hz_cust_accounts
1478: group by party_id;
1479: x_party_id hz_cust_accounts.party_id % type;
1480: x_account_established_date hz_cust_accounts.account_established_date % type;
1481: begin
1482: g_proc_name_old := g_proc_name;
1483: g_proc_name := 'retention_reactivated';
1484: write_log('retention_reactivated entered');

Line 1544: hz_cust_accounts hca

1540: -- 30-jun-99 minus 3 months will return 31-mar-99
1541: --
1542: -- for same reasons 1 is added while comparing ordered_date
1543: and exists (select 'x' from oe_order_headers_all oeh,
1544: hz_cust_accounts hca
1545: where oeh.sold_to_org_id = hca.cust_account_id
1546: and hca.party_id = x_party_id
1547: and ordered_date between add_months(bdt.act_period_end_date,
1548: g_attrition_period*-1)+1

Line 1553: hz_cust_accounts hca

1549: and bdt.act_period_end_date
1550: )
1551: and not exists
1552: (select 'x' from oe_order_headers_all oeh,
1553: hz_cust_accounts hca
1554: where oeh.sold_to_org_id = hca.cust_account_id
1555: and hca.party_id = x_party_id
1556: and ordered_date between add_months(bdt.act_period_end_date,
1557: g_attrition_period*-2)+1

Line 1577: from hz_cust_accounts

1573: -- This procedure inserts New customers for Retention measure code
1574: procedure retention_new is
1575: cursor party_cur is
1576: select party_id, min(nvl(account_established_date,creation_date))
1577: from hz_cust_accounts
1578: group by party_id
1579: having min(nvl(account_established_date,creation_date)) >=
1580: add_months(g_period_start_date,g_attrition_period*-1+1)
1581: -- 1 month is added so that you can compare with

Line 1586: x_party_id hz_cust_accounts.party_id % type;

1582: -- first period end date. Ex: g_period_start_date=1-aug-98, attrition
1583: -- period = 3 month and above expression will return you 1-jun-98.
1584: -- You want to know who was NEW on 31-aug-98
1585: ;
1586: x_party_id hz_cust_accounts.party_id % type;
1587: x_account_established_date hz_cust_accounts.account_established_date % type;
1588: begin
1589: g_proc_name_old := g_proc_name;
1590: g_proc_name := 'Retention_new';

Line 1587: x_account_established_date hz_cust_accounts.account_established_date % type;

1583: -- period = 3 month and above expression will return you 1-jun-98.
1584: -- You want to know who was NEW on 31-aug-98
1585: ;
1586: x_party_id hz_cust_accounts.party_id % type;
1587: x_account_established_date hz_cust_accounts.account_established_date % type;
1588: begin
1589: g_proc_name_old := g_proc_name;
1590: g_proc_name := 'Retention_new';
1591: debug(' entered +');

Line 1808: from hz_cust_accounts hca,

1804: g_program_application_id,
1805: g_program_id,
1806: g_last_update_login,
1807: 'SALES'
1808: from hz_cust_accounts hca,
1809: bic_temp_periods bdt,
1810: bic_measures_all bma,
1811: ra_customer_trx_all trx,
1812: ra_customer_trx_lines_all lines,

Line 1920: from hz_cust_accounts hca,

1916: g_program_application_id,
1917: g_program_id,
1918: g_last_update_login,
1919: 'COGS'
1920: from hz_cust_accounts hca,
1921: bic_temp_periods bdt,
1922: bic_measures_all bma,
1923: cst_bis_margin_summary cmt,
1924: hr_organization_information hoi,

Line 1968: from hz_cust_accounts

1964: procedure extract_acquisition_data
1965: is
1966: cursor party_cur is
1967: select party_id, min(nvl(account_established_date,creation_date))
1968: from hz_cust_accounts
1969: group by party_id;
1970: x_party_id hz_cust_accounts.party_id % type;
1971: x_account_established_date hz_cust_accounts.account_established_date % type;
1972: rec_count number;

Line 1970: x_party_id hz_cust_accounts.party_id % type;

1966: cursor party_cur is
1967: select party_id, min(nvl(account_established_date,creation_date))
1968: from hz_cust_accounts
1969: group by party_id;
1970: x_party_id hz_cust_accounts.party_id % type;
1971: x_account_established_date hz_cust_accounts.account_established_date % type;
1972: rec_count number;
1973: activation_id_not_found Exception;
1974: acquisition_not_found Exception;

Line 1971: x_account_established_date hz_cust_accounts.account_established_date % type;

1967: select party_id, min(nvl(account_established_date,creation_date))
1968: from hz_cust_accounts
1969: group by party_id;
1970: x_party_id hz_cust_accounts.party_id % type;
1971: x_account_established_date hz_cust_accounts.account_established_date % type;
1972: rec_count number;
1973: activation_id_not_found Exception;
1974: acquisition_not_found Exception;
1975: activation_period_not_found Exception;

Line 2119: hz_cust_accounts acct

2115: g_last_update_login,
2116: 'ACTIVATION'
2117: from oe_order_headers_all aoh, --4434468 replaced aso_i_oe_order_headers_v with oe_order_headers_all
2118: bic_party_summary bcs,
2119: hz_cust_accounts acct
2120: where bcs.measure_id = g_measure_id_for_acqu
2121:
2122: --and to_date(bcs.value + g_activation_period ,'J') >= g_period_start_date
2123:

Line 2345: hz_cust_accounts hca

2341: null)) return_qty
2342: FROM aso_i_oe_order_lines_v ool,
2343: aso_i_oe_order_headers_v ooh,
2344: bic_dimv_time bdt,
2345: hz_cust_accounts hca
2346: WHERE ooh.header_id = ool.header_id
2347: AND ooh.sold_to_org_id is not null
2348: AND ooh.ordered_date between bdt.start_date and act_period_end_date
2349: AND trunc(bdt.start_date)

Line 2416: hz_cust_accounts hca,

2412: )) ontime_val
2413: from
2414: aso_i_oe_order_headers_v ooh,
2415: aso_i_oe_order_lines_v ool,
2416: hz_cust_accounts hca,
2417: bic_dimv_time bdt
2418: where
2419: trunc(bdt.start_date)
2420: BETWEEN trunc(g_period_start_date)AND trunc(g_period_end_date)