DBA Data[Home] [Help]

APPS.CSP_AUTO_ASLMSL_PVT dependencies on CSP_USAGE_HISTORIES

Line 265: DELETE FROM csp_usage_histories

261: Where cpp.level_id like p_Level_Id || '%' And cpp.node_type in ('ORGANIZATION_WH','SUBINVENTORY'));
262: End If;
263: commit;
264: If p_Level_Id = '1' Then
265: DELETE FROM csp_usage_histories
266: WHERE history_data_type IN (2,5);
267: Else
268: Delete from csp_usage_histories cuh
269: Where history_data_type in (2,5)

Line 268: Delete from csp_usage_histories cuh

264: If p_Level_Id = '1' Then
265: DELETE FROM csp_usage_histories
266: WHERE history_data_type IN (2,5);
267: Else
268: Delete from csp_usage_histories cuh
269: Where history_data_type in (2,5)
270: And (cuh.organization_id,cuh.subinventory_code) in
271: (select cpp.organization_id ,nvl(cpp.secondary_inventory,'-')
272: from csp_planning_parameters cpp

Line 748: from csp_usage_histories cuh_fcst,

744: cuh_fcst.organization_id,
745: cuh_fcst.subinventory_code,
746: cuh_fcst.quantity - sum(cuh_usg.quantity) diff,
747: cfrb.forecast_periods
748: from csp_usage_histories cuh_fcst,
749: csp_planning_parameters cpp,
750: csp_forecast_rules_b cfrb,
751: csp_usage_histories cuh_usg
752: where cuh_fcst.history_data_type = 5

Line 751: csp_usage_histories cuh_usg

747: cfrb.forecast_periods
748: from csp_usage_histories cuh_fcst,
749: csp_planning_parameters cpp,
750: csp_forecast_rules_b cfrb,
751: csp_usage_histories cuh_usg
752: where cuh_fcst.history_data_type = 5
753: and cuh_fcst.period_start_date between (trunc(sysdate) - cfrb.forecast_periods * cfrb.period_size * cfrb.tracking_signal_cycle) and trunc(sysdate)
754: and cuh_fcst.organization_id = cpp.organization_id
755: and cuh_fcst.subinventory_code = cpp.secondary_inventory

Line 793: from csp_usage_histories cuh_fcst,

789: select cuh_fcst.inventory_item_id,
790: cuh_fcst.organization_id,
791: cuh_fcst.quantity - sum(cuh_usg.quantity) diff,
792: cfrb.forecast_periods
793: from csp_usage_histories cuh_fcst,
794: csp_planning_parameters cpp,
795: csp_forecast_rules_b cfrb,
796: csp_usage_orgs cuh_usg
797: where cuh_fcst.history_data_type = 5

Line 964: -- Delete from Csp_Usage_Histories

960: -- Delete from Csp_Usage_Headers
961: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_USAGE_HEADERS';
962:
963:
964: -- Delete from Csp_Usage_Histories
965: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_USAGE_HISTORIES';
966:
967: -- Delete from Csp_Supply_Chain
968: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_SUPPLY_CHAIN';

Line 965: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_USAGE_HISTORIES';

961: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_USAGE_HEADERS';
962:
963:
964: -- Delete from Csp_Usage_Histories
965: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_USAGE_HISTORIES';
966:
967: -- Delete from Csp_Supply_Chain
968: EXECUTE IMMEDIATE 'TRUNCATE TABLE '||l_oracle_schema||'.CSP_SUPPLY_CHAIN';
969:

Line 1160: from csp_usage_histories cuh ,

1156: quantity)
1157: select cuh.organization_id, cuh.inventory_item_id,
1158: cuh.period_start_date,
1159: sum(cuh.quantity)
1160: from csp_usage_histories cuh ,
1161: csp_planning_parameters cpp
1162: where cuh.History_Data_type = 1
1163: and cpp.organization_id = cuh.organization_id
1164: and cpp.secondary_inventory is null

Line 1284: CSP_USAGE_HISTORIES cuh,

1280: cfrb.WEIGHTED_AVG_PERIOD11,
1281: cfrb.WEIGHTED_AVG_PERIOD12,
1282: cpp.RECOMMEND_METHOD
1283: From CSP_PLANNING_PARAMETERS cpp,
1284: CSP_USAGE_HISTORIES cuh,
1285: CSP_SUPERSEDE_ITEMS csi,
1286: CSP_FORECAST_RULES_B cfrb
1287: Where cpp.level_id like P_Level_Id || '%'
1288: And cpp.node_type = 'SUBINVENTORY'

Line 1530: INSERT INTO CSP_USAGE_HISTORIES (Usage_Id,

1526: X_Forecast_Quantities =>l_Forecast_Qty_Tbl);
1527:
1528: End If;
1529: FOR l_Index in 1..l_Forecast_Qty_Tbl.COUNT LOOP
1530: INSERT INTO CSP_USAGE_HISTORIES (Usage_Id,
1531: created_by,
1532: creation_date,
1533: last_updated_by,
1534: last_update_date,

Line 1542: VALUES ( csp_usage_histories_s1.nextval,

1538: period_type,
1539: period_start_date,
1540: quantity,
1541: history_data_type)
1542: VALUES ( csp_usage_histories_s1.nextval,
1543: fnd_global.user_id, sysdate,
1544: fnd_global.user_id,sysdate,
1545: l_Prev_Rec.Inventory_Item_id,
1546: l_Prev_Rec.Organization_id,

Line 2627: insert into csp_usage_histories(

2623: --
2624: -- API body
2625: --
2626: -- Create Usage History for Engineering subinventories
2627: insert into csp_usage_histories(
2628: organization_id,
2629: subinventory_code,
2630: inventory_item_id,
2631: period_start_date,

Line 2673: insert into csp_usage_histories(

2669:
2670: -- Rollup Usage History through Supply Chain
2671: loop
2672: l_supply_level := l_supply_level + 1;
2673: insert into csp_usage_histories(
2674: organization_id,
2675: subinventory_code,
2676: inventory_item_id,
2677: period_start_date,

Line 2700: csp_usage_histories cuh

2696: sysdate,
2697: fnd_global.user_id,
2698: sysdate
2699: from csp_supply_chain csc,
2700: csp_usage_histories cuh
2701: where cuh.history_data_type = 1
2702: and cuh.period_start_date > G_LAST_RUN_DATE
2703: and cuh.organization_id = csc.organization_id
2704: and cuh.subinventory_code = csc.secondary_inventory

Line 3059: csp_usage_histories cuh

3055: sum(cuh.quantity),
3056: cuh.period_start_date,
3057: substr(cpp.level_id,1,instr(cpp.level_id,'.',-1,1) - 1)
3058: from csp_planning_parameters cpp,
3059: csp_usage_histories cuh
3060: Where cpp.node_type = 'SUBINVENTORY'
3061: and cuh.history_data_type = 1
3062: and cuh.organization_id = cpp.organization_id
3063: and cuh.subinventory_code = cpp.secondary_inventory