DBA Data[Home] [Help]

APPS.FLM_KANBAN_PLANNING_UTIL dependencies on MRP_CALENDAR

Line 556: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,

552: v_repl_no_of_cards
553: from (select plan.pull_sequence_id pull_seq,
554: mkc.kanban_card_id card,
555: mkc.kanban_size qty,
556: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,
557: case when trunc(mkca.creation_date+mkps.replenishment_lead_time) < l_plan_start_date then l_plan_start_date
558: else trunc(mkca.creation_date+mkps.replenishment_lead_time) end )) expected_date,
559: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,trunc(mkca.creation_date))) replenished_date
560: from mtl_kanban_card_activity mkca,

Line 559: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,trunc(mkca.creation_date))) replenished_date

555: mkc.kanban_size qty,
556: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,
557: case when trunc(mkca.creation_date+mkps.replenishment_lead_time) < l_plan_start_date then l_plan_start_date
558: else trunc(mkca.creation_date+mkps.replenishment_lead_time) end )) expected_date,
559: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,trunc(mkca.creation_date))) replenished_date
560: from mtl_kanban_card_activity mkca,
561: mtl_kanban_cards mkc,
562: mtl_kanban_pull_sequences mkps,
563: mtl_kanban_pull_sequences plan

Line 675: l_new_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_new_date+1);

671: l_exp_receipt := l_temp_onhand-l_already_receipt;
672: end if;
673: l_new_date := v_planning_temp_tbl(l_counter).plan_date;
674: for i in 1..nvl(v_planning_temp_tbl(l_counter).REPLENISHMENT_LEAD_TIME,0) loop
675: l_new_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_new_date+1);
676: end loop;
677: if l_new_date <= l_plan_end_date then
678: l_new_counter := l_counter + v_planning_temp_tbl(l_counter).REPLENISHMENT_LEAD_TIME;
679: v_planning_temp_tbl(l_new_counter).EXPECTED_RECEIPTS := l_exp_receipt+nvl(v_planning_temp_tbl(l_new_counter).EXPECTED_RECEIPTS,0);

Line 1390: l_start_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,trunc(sysdate));

1386: p_request_id := l_value;
1387: return;
1388: end if;
1389: if l_kanban_plan_id = 0 then
1390: l_start_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,trunc(sysdate));
1391: l_end_date := l_start_date;
1392: for i in 1..30 loop
1393: l_end_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_end_date+1);
1394: end loop;

Line 1393: l_end_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_end_date+1);

1389: if l_kanban_plan_id = 0 then
1390: l_start_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,trunc(sysdate));
1391: l_end_date := l_start_date;
1392: for i in 1..30 loop
1393: l_end_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_end_date+1);
1394: end loop;
1395: else
1396: select mrp_calendar.NEXT_WORK_DAY(organization_id,1,nvl(greatest(trunc(plan_start_date),trunc(sysdate)),trunc(sysdate))),
1397: mrp_calendar.NEXT_WORK_DAY(organization_id,1,trunc(plan_cutoff_date))

Line 1396: select mrp_calendar.NEXT_WORK_DAY(organization_id,1,nvl(greatest(trunc(plan_start_date),trunc(sysdate)),trunc(sysdate))),

1392: for i in 1..30 loop
1393: l_end_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_end_date+1);
1394: end loop;
1395: else
1396: select mrp_calendar.NEXT_WORK_DAY(organization_id,1,nvl(greatest(trunc(plan_start_date),trunc(sysdate)),trunc(sysdate))),
1397: mrp_calendar.NEXT_WORK_DAY(organization_id,1,trunc(plan_cutoff_date))
1398: into l_start_date,l_end_date
1399: from mrp_kanban_plans where kanban_plan_id = l_kanban_plan_id;
1400: end if;

Line 1397: mrp_calendar.NEXT_WORK_DAY(organization_id,1,trunc(plan_cutoff_date))

1393: l_end_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_end_date+1);
1394: end loop;
1395: else
1396: select mrp_calendar.NEXT_WORK_DAY(organization_id,1,nvl(greatest(trunc(plan_start_date),trunc(sysdate)),trunc(sysdate))),
1397: mrp_calendar.NEXT_WORK_DAY(organization_id,1,trunc(plan_cutoff_date))
1398: into l_start_date,l_end_date
1399: from mrp_kanban_plans where kanban_plan_id = l_kanban_plan_id;
1400: end if;
1401: v_exp_date.delete;

Line 1419: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,

1415: v_repl_no_of_cards
1416: from (select plan.pull_sequence_id pull_seq,
1417: mkc.kanban_card_id card,
1418: mkc.kanban_size qty,
1419: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,
1420: case when trunc(mkca.creation_date+mkps.replenishment_lead_time) < l_start_date then l_start_date
1421: else trunc(mkca.creation_date+mkps.replenishment_lead_time) end)) expected_date,
1422: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,trunc(mkca.creation_date))) replenished_date
1423: from mtl_kanban_card_activity mkca,

Line 1422: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,trunc(mkca.creation_date))) replenished_date

1418: mkc.kanban_size qty,
1419: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,
1420: case when trunc(mkca.creation_date+mkps.replenishment_lead_time) < l_start_date then l_start_date
1421: else trunc(mkca.creation_date+mkps.replenishment_lead_time) end)) expected_date,
1422: min(mrp_calendar.NEXT_WORK_DAY(mkps.organization_id,1,trunc(mkca.creation_date))) replenished_date
1423: from mtl_kanban_card_activity mkca,
1424: mtl_kanban_cards mkc,
1425: mtl_kanban_pull_sequences mkps,
1426: mtl_kanban_pull_sequences plan

Line 1459: mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date)),

1455: v_demand_date.delete;
1456: v_demand_qty.delete;
1457: -- This SQL gets item demand at a day level.
1458: select plan.pull_sequence_id,
1459: mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date)),
1460: sum(nvl(demand_quantity,0))
1461: bulk collect into v_dem_pull_seq_id,
1462: v_demand_date,
1463: v_demand_qty

Line 1472: and mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date)) between l_start_date and l_end_date

1468: and mkd.inventory_item_id = plan.inventory_item_id
1469: and mkd.subinventory = plan.subinventory_name
1470: and nvl(mkd.locator_id,-100) = nvl(plan.locator_id,-100)
1471: and plan.UPDATED_FLAG = l_value and plan.kanban_plan_id = mkd.kanban_plan_id
1472: and mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date)) between l_start_date and l_end_date
1473: group by plan.pull_sequence_id,mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date));
1474: v_demand_quantity.delete;
1475: l_temp := v_dem_pull_seq_id.first;
1476: if l_temp is not null then

Line 1473: group by plan.pull_sequence_id,mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date));

1469: and mkd.subinventory = plan.subinventory_name
1470: and nvl(mkd.locator_id,-100) = nvl(plan.locator_id,-100)
1471: and plan.UPDATED_FLAG = l_value and plan.kanban_plan_id = mkd.kanban_plan_id
1472: and mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date)) between l_start_date and l_end_date
1473: group by plan.pull_sequence_id,mrp_calendar.NEXT_WORK_DAY(plan.organization_id,1,trunc(demand_date));
1474: v_demand_quantity.delete;
1475: l_temp := v_dem_pull_seq_id.first;
1476: if l_temp is not null then
1477: while l_temp <= v_dem_pull_seq_id.last loop

Line 1585: l_new_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_new_date+1);

1581: l_exp_receipt := l_temp_onhand-l_already_receipt;
1582: end if;
1583: l_new_date := l_start_date;
1584: for i in 1..nvl(v_plan_pull_seq_tbl(l_plan_pull_seq).replenishment_lead_time,0) loop
1585: l_new_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_new_date+1);
1586: end loop;
1587: if l_new_date <= l_end_date then
1588: l_new_counter := l_counter+v_plan_pull_seq_tbl(l_plan_pull_seq).replenishment_lead_time;
1589: if v_flm_kanban_planning_temp.exists(l_new_counter) then

Line 1615: l_start_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_start_date +1);

1611: end if;
1612: v_flm_kanban_planning_temp(l_counter).inventory_value := v_flm_kanban_planning_temp(l_counter).Available_Onhand * l_item_unit_cost;
1613: v_flm_kanban_planning_temp(l_counter).safety_stock_target := nvl(v_flm_kanban_planning_temp(l_counter).Safety_stock_days,0)*
1614: nvl(v_flm_kanban_planning_temp(l_counter).Daily_Demand,0);
1615: l_start_date := mrp_calendar.NEXT_WORK_DAY(l_org_id,1,l_start_date +1);
1616: END LOOP;
1617: l_plan_pull_seq := v_plan_pull_seq_tbl.next(l_plan_pull_seq);
1618: end loop;
1619: end if;