DBA Data[Home] [Help]

APPS.MSC_ATP_REQ dependencies on MSC_SCH_WB

Line 20: msc_sch_wb.atp_debug('date: ' || p_atp_dates(i) ||

16: ) IS
17: BEGIN
18: IF PG_DEBUG in ('Y', 'C') THEN
19: for i in 1..p_atp_dates.count loop
20: msc_sch_wb.atp_debug('date: ' || p_atp_dates(i) ||
21: ' qty: ' || p_atp_qtys(i));
22: end loop;
23: END IF;
24: END Print_Dates_Qtys;

Line 44: msc_sch_wb.atp_debug('Integer Scaling');

40:
41: BEGIN
42:
43: IF PG_DEBUG in ('Y', 'C') THEN
44: msc_sch_wb.atp_debug('Integer Scaling');
45: msc_sch_wb.atp_debug('Integer Scaling : p_scale_qty ' || p_scale_qty);
46: msc_sch_wb.atp_debug('Integer Scaling : p_scale_multiple ' || p_scale_multiple);
47: msc_sch_wb.atp_debug('Integer Scaling : p_scale_rounding_variance ' || p_scale_rounding_variance);
48: msc_sch_wb.atp_debug('Integer Scaling : p_rounding_direction ' || p_rounding_direction);

Line 45: msc_sch_wb.atp_debug('Integer Scaling : p_scale_qty ' || p_scale_qty);

41: BEGIN
42:
43: IF PG_DEBUG in ('Y', 'C') THEN
44: msc_sch_wb.atp_debug('Integer Scaling');
45: msc_sch_wb.atp_debug('Integer Scaling : p_scale_qty ' || p_scale_qty);
46: msc_sch_wb.atp_debug('Integer Scaling : p_scale_multiple ' || p_scale_multiple);
47: msc_sch_wb.atp_debug('Integer Scaling : p_scale_rounding_variance ' || p_scale_rounding_variance);
48: msc_sch_wb.atp_debug('Integer Scaling : p_rounding_direction ' || p_rounding_direction);
49: END IF;

Line 46: msc_sch_wb.atp_debug('Integer Scaling : p_scale_multiple ' || p_scale_multiple);

42:
43: IF PG_DEBUG in ('Y', 'C') THEN
44: msc_sch_wb.atp_debug('Integer Scaling');
45: msc_sch_wb.atp_debug('Integer Scaling : p_scale_qty ' || p_scale_qty);
46: msc_sch_wb.atp_debug('Integer Scaling : p_scale_multiple ' || p_scale_multiple);
47: msc_sch_wb.atp_debug('Integer Scaling : p_scale_rounding_variance ' || p_scale_rounding_variance);
48: msc_sch_wb.atp_debug('Integer Scaling : p_rounding_direction ' || p_rounding_direction);
49: END IF;
50:

Line 47: msc_sch_wb.atp_debug('Integer Scaling : p_scale_rounding_variance ' || p_scale_rounding_variance);

43: IF PG_DEBUG in ('Y', 'C') THEN
44: msc_sch_wb.atp_debug('Integer Scaling');
45: msc_sch_wb.atp_debug('Integer Scaling : p_scale_qty ' || p_scale_qty);
46: msc_sch_wb.atp_debug('Integer Scaling : p_scale_multiple ' || p_scale_multiple);
47: msc_sch_wb.atp_debug('Integer Scaling : p_scale_rounding_variance ' || p_scale_rounding_variance);
48: msc_sch_wb.atp_debug('Integer Scaling : p_rounding_direction ' || p_rounding_direction);
49: END IF;
50:
51: l_scale_qty := p_scale_qty;

Line 48: msc_sch_wb.atp_debug('Integer Scaling : p_rounding_direction ' || p_rounding_direction);

44: msc_sch_wb.atp_debug('Integer Scaling');
45: msc_sch_wb.atp_debug('Integer Scaling : p_scale_qty ' || p_scale_qty);
46: msc_sch_wb.atp_debug('Integer Scaling : p_scale_multiple ' || p_scale_multiple);
47: msc_sch_wb.atp_debug('Integer Scaling : p_scale_rounding_variance ' || p_scale_rounding_variance);
48: msc_sch_wb.atp_debug('Integer Scaling : p_rounding_direction ' || p_rounding_direction);
49: END IF;
50:
51: l_scale_qty := p_scale_qty;
52:

Line 57: msc_sch_wb.atp_debug('Integer Scaling: : var ' || var);

53: --variance
54: var := p_scale_rounding_variance * l_scale_qty/100;
55:
56: IF PG_DEBUG in ('Y', 'C') THEN
57: msc_sch_wb.atp_debug('Integer Scaling: : var ' || var);
58: END IF;
59: --variance remainder
60: rem_var := l_scale_qty / p_scale_multiple;
61:

Line 75: msc_sch_wb.atp_debug('Integer Scaling: Rounding direction: UP, l_scale_qty: ' || l_scale_qty);

71: IF (var >= ceil_deviation AND ceil_qty <> 0) THEN
72: l_scale_qty := ceil_qty;
73: END IF;
74: IF PG_DEBUG in ('Y', 'C') THEN
75: msc_sch_wb.atp_debug('Integer Scaling: Rounding direction: UP, l_scale_qty: ' || l_scale_qty);
76: END IF;
77: ELSIF ( P_ROUNDING_DIRECTION = 0 )THEN --0 for Both
78: IF PG_DEBUG in ('Y', 'C') THEN
79: msc_sch_wb.atp_debug('Integer Scaling: Rounding direction: BOTH');

Line 79: msc_sch_wb.atp_debug('Integer Scaling: Rounding direction: BOTH');

75: msc_sch_wb.atp_debug('Integer Scaling: Rounding direction: UP, l_scale_qty: ' || l_scale_qty);
76: END IF;
77: ELSIF ( P_ROUNDING_DIRECTION = 0 )THEN --0 for Both
78: IF PG_DEBUG in ('Y', 'C') THEN
79: msc_sch_wb.atp_debug('Integer Scaling: Rounding direction: BOTH');
80: END IF;
81: floor_qty := floor(rem_var) * p_scale_multiple;
82: floor_deviation := l_scale_qty - floor_qty;
83: ceil_qty := ceil(rem_var) * p_scale_multiple;

Line 88: msc_sch_wb.atp_debug('retaining the value');

84: ceil_deviation := ceil_qty - l_scale_qty;
85: IF ( floor_qty = 0 OR ceil_qty = 0 ) THEN
86: --retain the value
87: IF PG_DEBUG in ('Y', 'C') THEN
88: msc_sch_wb.atp_debug('retaining the value');
89: END IF;
90: ELSIF (var >= ceil_deviation AND ceil_qty <> 0) THEN --4904094, changed the cindition from var > ceil_deviation to var >= ceil_deviation
91: l_scale_qty := ceil_qty;
92: IF PG_DEBUG in ('Y', 'C') THEN

Line 93: msc_sch_wb.atp_debug('Integer Scaling: Qty CEILed, l_scale_qty: ' || l_scale_qty);

89: END IF;
90: ELSIF (var >= ceil_deviation AND ceil_qty <> 0) THEN --4904094, changed the cindition from var > ceil_deviation to var >= ceil_deviation
91: l_scale_qty := ceil_qty;
92: IF PG_DEBUG in ('Y', 'C') THEN
93: msc_sch_wb.atp_debug('Integer Scaling: Qty CEILed, l_scale_qty: ' || l_scale_qty);
94: END IF;
95: ELSIF (var >= floor_deviation AND floor_qty <> 0) THEN
96: l_scale_qty := floor_qty;
97: IF PG_DEBUG in ('Y', 'C') THEN

Line 98: msc_sch_wb.atp_debug('Integer Scaling: Qty FLOORed, l_scale_qty: ' || l_scale_qty);

94: END IF;
95: ELSIF (var >= floor_deviation AND floor_qty <> 0) THEN
96: l_scale_qty := floor_qty;
97: IF PG_DEBUG in ('Y', 'C') THEN
98: msc_sch_wb.atp_debug('Integer Scaling: Qty FLOORed, l_scale_qty: ' || l_scale_qty);
99: END IF;
100: END IF;
101: END IF;
102: IF PG_DEBUG in ('Y', 'C') THEN

Line 103: msc_sch_wb.atp_debug('Integer Scaling :l_scale_qty ' || l_scale_qty);

99: END IF;
100: END IF;
101: END IF;
102: IF PG_DEBUG in ('Y', 'C') THEN
103: msc_sch_wb.atp_debug('Integer Scaling :l_scale_qty ' || l_scale_qty);
104: END IF;
105:
106: return l_scale_qty;
107:

Line 111: msc_sch_wb.atp_debug('Integer Scaling: Division by Zero');

107:
108: EXCEPTION
109: WHEN ZERO_DIVIDE THEN
110: IF PG_DEBUG in ('Y', 'C') THEN
111: msc_sch_wb.atp_debug('Integer Scaling: Division by Zero');
112: END IF;
113: l_scale_qty := p_scale_multiple;
114: return l_scale_qty;
115: END integer_scaling;

Line 139: msc_sch_wb.atp_debug('get_res_avail_opt');

135: l_null_char VARCHAR2(1);
136: l_sysdate DATE := trunc(sysdate); --4135752
137: BEGIN
138: IF PG_DEBUG in ('Y', 'C') THEN
139: msc_sch_wb.atp_debug('get_res_avail_opt');
140: END IF;
141:
142: SELECT SD_DATE,
143: SUM(SD_QTY)

Line 249: msc_sch_wb.atp_debug('get_res_avail_unopt');

245: l_null_char VARCHAR2(1);
246: l_sysdate DATE := trunc(sysdate); --4135752
247: BEGIN
248: IF PG_DEBUG in ('Y', 'C') THEN
249: msc_sch_wb.atp_debug('get_res_avail_unopt');
250: END IF;
251:
252: SELECT SD_DATE,
253: SUM(SD_QTY)

Line 358: msc_sch_wb.atp_debug('get_res_avail_opt_bat');

354: l_null_char VARCHAR2(1);
355: l_sysdate DATE := trunc(sysdate);--4135752
356: BEGIN
357: IF PG_DEBUG in ('Y', 'C') THEN
358: msc_sch_wb.atp_debug('get_res_avail_opt_bat');
359: END IF;
360:
361: SELECT SD_DATE,
362: SUM(SD_QTY)

Line 488: msc_sch_wb.atp_debug('get_res_avail_unopt_bat');

484: l_null_char VARCHAR2(1);
485: l_sysdate DATE := trunc(sysdate);--4135752
486: BEGIN
487: IF PG_DEBUG in ('Y', 'C') THEN
488: msc_sch_wb.atp_debug('get_res_avail_unopt_bat');
489: END IF;
490:
491: SELECT SD_DATE,
492: SUM(SD_QTY)

Line 613: msc_sch_wb.atp_debug('get_res_avail_opt_dtls');

609: l_null_char VARCHAR2(1);
610: l_sysdate DATE := trunc(sysdate); --4135752
611: BEGIN
612: IF PG_DEBUG in ('Y', 'C') THEN
613: msc_sch_wb.atp_debug('get_res_avail_opt_dtls');
614: END IF;
615:
616: INSERT INTO msc_atp_sd_details_temp (
617: ATP_Level,

Line 821: msc_sch_wb.atp_debug('get_res_avail_unopt_dtls');

817: l_null_char VARCHAR2(1);
818: l_sysdate DATE := trunc(sysdate); --4135752
819: BEGIN
820: IF PG_DEBUG in ('Y', 'C') THEN
821: msc_sch_wb.atp_debug('get_res_avail_unopt_dtls');
822: END IF;
823:
824: INSERT INTO msc_atp_sd_details_temp (
825: ATP_Level,

Line 1031: msc_sch_wb.atp_debug('get_res_avail_opt_bat_dtls');

1027: l_null_char VARCHAR2(1);
1028: l_sysdate DATE := trunc(sysdate); --4135752
1029: BEGIN
1030: IF PG_DEBUG in ('Y', 'C') THEN
1031: msc_sch_wb.atp_debug('get_res_avail_opt_bat_dtls');
1032: END IF;
1033:
1034: INSERT INTO msc_atp_sd_details_temp (
1035: ATP_Level,

Line 1253: msc_sch_wb.atp_debug('get_res_avail_unopt_bat_dtls');

1249: l_null_char VARCHAR2(1);
1250: l_sysdate DATE := trunc(sysdate); --4135752
1251: BEGIN
1252: IF PG_DEBUG in ('Y', 'C') THEN
1253: msc_sch_wb.atp_debug('get_res_avail_unopt_bat_dtls');
1254: END IF;
1255:
1256: INSERT INTO msc_atp_sd_details_temp (
1257: ATP_Level,

Line 1470: msc_sch_wb.atp_debug('get_res_avail_summ');

1466: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
1467: ) IS
1468: BEGIN
1469: IF PG_DEBUG in ('Y', 'C') THEN
1470: msc_sch_wb.atp_debug('get_res_avail_summ');
1471: END IF;
1472:
1473: SELECT SD_DATE,
1474: SUM(SD_QTY)

Line 1560: msc_sch_wb.atp_debug('get_res_avail');

1556: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
1557: ) IS
1558: BEGIN
1559: IF PG_DEBUG in ('Y', 'C') THEN
1560: msc_sch_wb.atp_debug('get_res_avail');
1561: END IF;
1562:
1563: IF nvl(p_batching_flag, 0) = 1 THEN
1564: IF nvl(p_optimized_flag, 0) = 1 THEN

Line 1872: msc_sch_wb.atp_debug('Begin get_mat_avail_ods_summ');

1868: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
1869: ) IS
1870: BEGIN
1871: IF PG_DEBUG in ('Y', 'C') THEN
1872: msc_sch_wb.atp_debug('Begin get_mat_avail_ods_summ');
1873: END IF;
1874:
1875: SELECT SD_DATE, sum(SD_QTY)
1876: BULK COLLECT INTO x_atp_dates, x_atp_qtys

Line 1943: msc_sch_wb.atp_debug('Begin get_mat_avail_summ');

1939: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
1940: ) IS
1941: BEGIN
1942: IF PG_DEBUG in ('Y', 'C') THEN
1943: msc_sch_wb.atp_debug('Begin get_mat_avail_summ');
1944: END IF;
1945:
1946: -- SQL changed for summary enhancement
1947: SELECT SD_DATE, SUM(SD_QTY)

Line 2036: msc_sch_wb.atp_debug('Begin get_mat_avail_ods');

2032: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
2033: ) IS
2034: BEGIN
2035: IF PG_DEBUG in ('Y', 'C') THEN
2036: msc_sch_wb.atp_debug('Begin get_mat_avail_ods');
2037: END IF;
2038:
2039: -- SQL Query changes Begin 2640489
2040: SELECT SD_DATE, SUM(SD_QTY)

Line 2267: msc_sch_wb.atp_debug('Begin get_mat_avail_opt');

2263: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
2264: ) IS
2265: BEGIN
2266: IF PG_DEBUG in ('Y', 'C') THEN
2267: msc_sch_wb.atp_debug('Begin get_mat_avail_opt');
2268: END IF;
2269:
2270: -- 2859130 repetitive schedule demands (4) not supported
2271: -- remove join to msc_calendar_dates

Line 2359: msc_sch_wb.atp_debug('Begin get_mat_avail_unopt');

2355: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
2356: ) IS
2357: BEGIN
2358: IF PG_DEBUG in ('Y', 'C') THEN
2359: msc_sch_wb.atp_debug('Begin get_mat_avail_unopt');
2360: END IF;
2361:
2362: SELECT SD_DATE, SUM(SD_QTY)
2363: BULK COLLECT INTO x_atp_dates, x_atp_qtys

Line 2475: msc_sch_wb.atp_debug('Begin get_mat_avail_ods_dtls');

2471: l_null_date DATE; --bug3814584
2472: l_sysdate DATE := sysdate;
2473: BEGIN
2474: IF PG_DEBUG in ('Y', 'C') THEN
2475: msc_sch_wb.atp_debug('Begin get_mat_avail_ods_dtls');
2476: END IF;
2477:
2478: -- dsting: S/D details changes
2479: INSERT INTO msc_atp_sd_details_temp (

Line 2870: msc_sch_wb.atp_debug('Begin get_mat_avail_opt_dtls');

2866: l_null_date DATE; --bug3814584
2867: l_sysdate DATE := sysdate;
2868: BEGIN
2869: IF PG_DEBUG in ('Y', 'C') THEN
2870: msc_sch_wb.atp_debug('Begin get_mat_avail_opt_dtls');
2871: END IF;
2872:
2873: INSERT INTO msc_atp_sd_details_temp (
2874: ATP_Level,

Line 3082: msc_sch_wb.atp_debug('Begin get_mat_avail_unopt_dtls');

3078: l_null_date DATE; --bug3814584
3079: l_sysdate DATE := sysdate;
3080: BEGIN
3081: IF PG_DEBUG in ('Y', 'C') THEN
3082: msc_sch_wb.atp_debug('Begin get_mat_avail_unopt_dtls');
3083: END IF;
3084:
3085: INSERT INTO msc_atp_sd_details_temp (
3086: ATP_Level,

Line 3314: msc_sch_wb.atp_debug('Begin get_mat_avail');

3310: x_atp_qtys OUT NoCopy MRP_ATP_PUB.number_arr
3311: ) IS
3312: BEGIN
3313: IF PG_DEBUG in ('Y', 'C') THEN
3314: msc_sch_wb.atp_debug('Begin get_mat_avail');
3315: END IF;
3316:
3317: IF MSC_ATP_PVT.G_INV_CTP = 5 THEN
3318: -- ODS atp

Line 3446: msc_sch_wb.atp_debug('Begin get_mat_avail_dtls');

3442: p_identifier IN NUMBER
3443: ) IS
3444: BEGIN
3445: IF PG_DEBUG in ('Y', 'C') THEN
3446: msc_sch_wb.atp_debug('Begin get_mat_avail_dtls');
3447: END IF;
3448:
3449: IF MSC_ATP_PVT.G_INV_CTP = 5 THEN
3450: -- ODS atp

Line 3545: msc_sch_wb.atp_debug('********** Calculate_Atp_Dates_Qtys **********');

3541: l_next_period DATE;
3542:
3543: BEGIN
3544: IF PG_DEBUG in ('Y', 'C') THEN
3545: msc_sch_wb.atp_debug('********** Calculate_Atp_Dates_Qtys **********');
3546: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date: '|| to_char(p_requested_date));
3547: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3548: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_sys_next_date: '|| to_char(p_sys_next_date));
3549: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_round_flag: '|| to_char(p_round_flag));

Line 3546: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date: '|| to_char(p_requested_date));

3542:
3543: BEGIN
3544: IF PG_DEBUG in ('Y', 'C') THEN
3545: msc_sch_wb.atp_debug('********** Calculate_Atp_Dates_Qtys **********');
3546: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date: '|| to_char(p_requested_date));
3547: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3548: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_sys_next_date: '|| to_char(p_sys_next_date));
3549: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_round_flag: '|| to_char(p_round_flag));
3550: END IF;

Line 3547: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));

3543: BEGIN
3544: IF PG_DEBUG in ('Y', 'C') THEN
3545: msc_sch_wb.atp_debug('********** Calculate_Atp_Dates_Qtys **********');
3546: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date: '|| to_char(p_requested_date));
3547: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3548: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_sys_next_date: '|| to_char(p_sys_next_date));
3549: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_round_flag: '|| to_char(p_round_flag));
3550: END IF;
3551:

Line 3548: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_sys_next_date: '|| to_char(p_sys_next_date));

3544: IF PG_DEBUG in ('Y', 'C') THEN
3545: msc_sch_wb.atp_debug('********** Calculate_Atp_Dates_Qtys **********');
3546: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date: '|| to_char(p_requested_date));
3547: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3548: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_sys_next_date: '|| to_char(p_sys_next_date));
3549: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_round_flag: '|| to_char(p_round_flag));
3550: END IF;
3551:
3552: -- initialize API return status to success

Line 3549: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_round_flag: '|| to_char(p_round_flag));

3545: msc_sch_wb.atp_debug('********** Calculate_Atp_Dates_Qtys **********');
3546: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date: '|| to_char(p_requested_date));
3547: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3548: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_sys_next_date: '|| to_char(p_sys_next_date));
3549: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_round_flag: '|| to_char(p_round_flag));
3550: END IF;
3551:
3552: -- initialize API return status to success
3553: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 3581: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_quantity_this_level);

3577: x_atp_date_quantity_this_level := p_atp_qty_tab(k);
3578: END IF;
3579: x_atp_date_this_level := GREATEST(p_atp_period_tab(k), MSC_ATP_PVT.G_PTF_DATE);
3580: IF PG_DEBUG in ('Y', 'C') THEN
3581: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_quantity_this_level);
3582: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_this_level);
3583: END IF;
3584:
3585: END IF;

Line 3582: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_this_level);

3578: END IF;
3579: x_atp_date_this_level := GREATEST(p_atp_period_tab(k), MSC_ATP_PVT.G_PTF_DATE);
3580: IF PG_DEBUG in ('Y', 'C') THEN
3581: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_quantity_this_level);
3582: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_this_level);
3583: END IF;
3584:
3585: END IF;
3586: EXIT;

Line 3598: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_quantity_this_level);

3594: x_atp_date_quantity_this_level := p_atp_qty_tab(k);
3595: END IF;
3596: x_atp_date_this_level := GREATEST(p_atp_period_tab(k), MSC_ATP_PVT.G_PTF_DATE);
3597: IF PG_DEBUG in ('Y', 'C') THEN
3598: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_quantity_this_level);
3599: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_this_level);
3600: END IF;
3601: EXIT;
3602: END IF;

Line 3599: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_this_level);

3595: END IF;
3596: x_atp_date_this_level := GREATEST(p_atp_period_tab(k), MSC_ATP_PVT.G_PTF_DATE);
3597: IF PG_DEBUG in ('Y', 'C') THEN
3598: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_quantity_this_level);
3599: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || x_atp_date_this_level);
3600: END IF;
3601: EXIT;
3602: END IF;
3603: END LOOP; -- end of k loop

Line 3614: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'I am here 1');

3610: -- date. if requested date is eariler than sysdate, we should set
3611: -- the x_requested_date_quantity = 0, and find the atp date and
3612: -- quantity from sysdate.
3613: IF PG_DEBUG in ('Y', 'C') THEN
3614: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'I am here 1');
3615: END IF;
3616: FOR j IN 1..p_atp_period_tab.COUNT LOOP
3617:
3618: -- time_phased_atp changes begin

Line 3621: msc_sch_wb.atp_debug('*********************');

3617:
3618: -- time_phased_atp changes begin
3619: IF (x_atf_date_quantity is null) and (p_atf_date is not null) THEN
3620: IF PG_DEBUG in ('Y', 'C') THEN
3621: msc_sch_wb.atp_debug('*********************');
3622: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(j): ' || p_atp_period_tab(j));
3623: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3624: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j): ' || p_atp_qty_tab(j));
3625: END IF;

Line 3622: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(j): ' || p_atp_period_tab(j));

3618: -- time_phased_atp changes begin
3619: IF (x_atf_date_quantity is null) and (p_atf_date is not null) THEN
3620: IF PG_DEBUG in ('Y', 'C') THEN
3621: msc_sch_wb.atp_debug('*********************');
3622: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(j): ' || p_atp_period_tab(j));
3623: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3624: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j): ' || p_atp_qty_tab(j));
3625: END IF;
3626: IF p_atp_period_tab(j) = p_atf_date THEN

Line 3623: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);

3619: IF (x_atf_date_quantity is null) and (p_atf_date is not null) THEN
3620: IF PG_DEBUG in ('Y', 'C') THEN
3621: msc_sch_wb.atp_debug('*********************');
3622: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(j): ' || p_atp_period_tab(j));
3623: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3624: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j): ' || p_atp_qty_tab(j));
3625: END IF;
3626: IF p_atp_period_tab(j) = p_atf_date THEN
3627: x_atf_date_quantity := p_atp_qty_tab(j);

Line 3624: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j): ' || p_atp_qty_tab(j));

3620: IF PG_DEBUG in ('Y', 'C') THEN
3621: msc_sch_wb.atp_debug('*********************');
3622: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(j): ' || p_atp_period_tab(j));
3623: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3624: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j): ' || p_atp_qty_tab(j));
3625: END IF;
3626: IF p_atp_period_tab(j) = p_atf_date THEN
3627: x_atf_date_quantity := p_atp_qty_tab(j);
3628: ELSIF p_atp_period_tab(j) > p_atf_date THEN

Line 3633: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j-1): ' || p_atp_qty_tab(j-1));

3629: IF j = 1 THEN
3630: x_atf_date_quantity := 0;
3631: ELSE
3632: IF PG_DEBUG in ('Y', 'C') THEN
3633: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(j-1): ' || p_atp_qty_tab(j-1));
3634: END IF;
3635: x_atf_date_quantity := p_atp_qty_tab(j-1);
3636: END IF;
3637: END IF;

Line 3640: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: x_atf_date_quantity: ' || x_atf_date_quantity);

3636: END IF;
3637: END IF;
3638:
3639: IF PG_DEBUG in ('Y', 'C') THEN
3640: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: x_atf_date_quantity: ' || x_atf_date_quantity);
3641: END IF;
3642: END IF;
3643: -- time_phased_atp changes end
3644:

Line 3660: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'I am here 2');

3656: ELSE
3657: l_next_period := l_atp_requested_date + 1;
3658: END IF;
3659: IF PG_DEBUG in ('Y', 'C') THEN
3660: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'I am here 2');
3661: END IF;
3662:
3663: --- bug 1819638: If sysdate is non-work day then we want to check the request on
3664: --- next working day (p_sys_next_date)

Line 3672: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'I am here 3');

3668:
3669:
3670: --IF p_requested_date < l_atp_requested_date THEN
3671: IF PG_DEBUG in ('Y', 'C') THEN
3672: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'I am here 3');
3673: END IF;
3674: -- Bug 3512996 - For request before PTF return 0 as request date quantity
3675: -- IF (p_requested_date < l_atp_requested_date) THEN
3676: -- IF (p_requested_date < GREATEST(l_atp_requested_date,MSC_ATP_PVT.G_PTF_DATE)) THEN

Line 3679: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date < l_atp_requested_date');

3675: -- IF (p_requested_date < l_atp_requested_date) THEN
3676: -- IF (p_requested_date < GREATEST(l_atp_requested_date,MSC_ATP_PVT.G_PTF_DATE)) THEN
3677: IF (p_requested_date < l_atp_requested_date) THEN -- Bug 3828469 - Undo the regression introduced by Bug 3512996
3678: IF PG_DEBUG in ('Y', 'C') THEN
3679: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date < l_atp_requested_date');
3680: END IF;
3681: x_requested_date_quantity := 0;
3682: ELSE
3683: IF (p_round_flag = 1) THEN --- bug 1774959

Line 3689: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date > l_atp_requested_date');

3685: ELSE
3686: x_requested_date_quantity := p_atp_qty_tab(j);
3687: END IF;
3688: IF PG_DEBUG in ('Y', 'C') THEN
3689: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date > l_atp_requested_date');
3690: END IF;
3691: END IF;
3692: IF PG_DEBUG in ('Y', 'C') THEN
3693: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_requested_date_quantity: '|| to_char(x_requested_date_quantity));

Line 3693: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_requested_date_quantity: '|| to_char(x_requested_date_quantity));

3689: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_requested_date > l_atp_requested_date');
3690: END IF;
3691: END IF;
3692: IF PG_DEBUG in ('Y', 'C') THEN
3693: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_requested_date_quantity: '|| to_char(x_requested_date_quantity));
3694: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'test line p_atp_qty_tab(j): '|| to_char(p_atp_qty_tab(j)));
3695: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3696: END IF;
3697:

Line 3694: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'test line p_atp_qty_tab(j): '|| to_char(p_atp_qty_tab(j)));

3690: END IF;
3691: END IF;
3692: IF PG_DEBUG in ('Y', 'C') THEN
3693: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_requested_date_quantity: '|| to_char(x_requested_date_quantity));
3694: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'test line p_atp_qty_tab(j): '|| to_char(p_atp_qty_tab(j)));
3695: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3696: END IF;
3697:
3698: -- now find the atp_date_quantity and atp_date at this level

Line 3695: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));

3691: END IF;
3692: IF PG_DEBUG in ('Y', 'C') THEN
3693: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_requested_date_quantity: '|| to_char(x_requested_date_quantity));
3694: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'test line p_atp_qty_tab(j): '|| to_char(p_atp_qty_tab(j)));
3695: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'p_quantity_ordered: '|| to_char(p_quantity_ordered));
3696: END IF;
3697:
3698: -- now find the atp_date_quantity and atp_date at this level
3699: IF p_atp_qty_tab(j) >= p_quantity_ordered AND

Line 3709: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Checkpoint 1');

3705: END IF;
3706: -- bug 1560255
3707: --x_atp_date_quantity_this_level := p_quantity_ordered;
3708: IF PG_DEBUG in ('Y', 'C') THEN
3709: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Checkpoint 1');
3710: END IF;
3711: x_atp_date_this_level := GREATEST(l_atp_requested_date, p_sys_next_date);
3712:
3713: IF PG_DEBUG in ('Y', 'C') THEN

Line 3714: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_atp_date_this_level: '|| to_char(x_atp_date_this_level));

3710: END IF;
3711: x_atp_date_this_level := GREATEST(l_atp_requested_date, p_sys_next_date);
3712:
3713: IF PG_DEBUG in ('Y', 'C') THEN
3714: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_atp_date_this_level: '|| to_char(x_atp_date_this_level));
3715: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_atp_date_quantity_this_level: '|| to_char(x_atp_date_quantity_this_level));
3716: END IF;
3717:
3718:

Line 3715: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_atp_date_quantity_this_level: '|| to_char(x_atp_date_quantity_this_level));

3711: x_atp_date_this_level := GREATEST(l_atp_requested_date, p_sys_next_date);
3712:
3713: IF PG_DEBUG in ('Y', 'C') THEN
3714: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_atp_date_this_level: '|| to_char(x_atp_date_this_level));
3715: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'x_atp_date_quantity_this_level: '|| to_char(x_atp_date_quantity_this_level));
3716: END IF;
3717:
3718:
3719: ELSE

Line 3745: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Checkpoint 3');

3741: END IF;
3742: -- bug 1560255
3743: --x_atp_date_quantity_this_level := p_quantity_ordered;
3744: IF PG_DEBUG in ('Y', 'C') THEN
3745: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Checkpoint 3');
3746: END IF;
3747: x_atp_date_this_level := GREATEST(NVL(MSC_ATP_PVT.G_PTF_DATE,p_sys_next_date)
3748: , p_atp_period_tab(j));
3749: ELSE

Line 3751: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Checkpoint 2');

3747: x_atp_date_this_level := GREATEST(NVL(MSC_ATP_PVT.G_PTF_DATE,p_sys_next_date)
3748: , p_atp_period_tab(j));
3749: ELSE
3750: IF PG_DEBUG in ('Y', 'C') THEN
3751: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Checkpoint 2');
3752: END IF;
3753: FOR k IN j+1..p_atp_period_tab.COUNT LOOP
3754:
3755: -- time_phased_atp changes begin

Line 3758: msc_sch_wb.atp_debug('*********************');

3754:
3755: -- time_phased_atp changes begin
3756: IF (x_atf_date_quantity is null) and (p_atf_date is not null) THEN
3757: IF PG_DEBUG in ('Y', 'C') THEN
3758: msc_sch_wb.atp_debug('*********************');
3759: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(k): ' || p_atp_period_tab(k));
3760: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3761: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k): ' || p_atp_qty_tab(k));
3762: END IF;

Line 3759: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(k): ' || p_atp_period_tab(k));

3755: -- time_phased_atp changes begin
3756: IF (x_atf_date_quantity is null) and (p_atf_date is not null) THEN
3757: IF PG_DEBUG in ('Y', 'C') THEN
3758: msc_sch_wb.atp_debug('*********************');
3759: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(k): ' || p_atp_period_tab(k));
3760: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3761: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k): ' || p_atp_qty_tab(k));
3762: END IF;
3763: IF p_atp_period_tab(k) = p_atf_date THEN

Line 3760: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);

3756: IF (x_atf_date_quantity is null) and (p_atf_date is not null) THEN
3757: IF PG_DEBUG in ('Y', 'C') THEN
3758: msc_sch_wb.atp_debug('*********************');
3759: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(k): ' || p_atp_period_tab(k));
3760: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3761: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k): ' || p_atp_qty_tab(k));
3762: END IF;
3763: IF p_atp_period_tab(k) = p_atf_date THEN
3764: x_atf_date_quantity := p_atp_qty_tab(k);

Line 3761: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k): ' || p_atp_qty_tab(k));

3757: IF PG_DEBUG in ('Y', 'C') THEN
3758: msc_sch_wb.atp_debug('*********************');
3759: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_period_tab(k): ' || p_atp_period_tab(k));
3760: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atf_date: ' || p_atf_date);
3761: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k): ' || p_atp_qty_tab(k));
3762: END IF;
3763: IF p_atp_period_tab(k) = p_atf_date THEN
3764: x_atf_date_quantity := p_atp_qty_tab(k);
3765: ELSIF p_atp_period_tab(k) > p_atf_date THEN

Line 3770: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k-1): ' || p_atp_qty_tab(k-1));

3766: IF k = 1 THEN
3767: x_atf_date_quantity := 0;
3768: ELSE
3769: IF PG_DEBUG in ('Y', 'C') THEN
3770: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: p_atp_qty_tab(k-1): ' || p_atp_qty_tab(k-1));
3771: END IF;
3772: x_atf_date_quantity := p_atp_qty_tab(k-1);
3773: END IF;
3774: END IF;

Line 3777: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: x_atf_date_quantity: ' || x_atf_date_quantity);

3773: END IF;
3774: END IF;
3775:
3776: IF PG_DEBUG in ('Y', 'C') THEN
3777: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: x_atf_date_quantity: ' || x_atf_date_quantity);
3778: END IF;
3779: END IF;
3780: -- time_phased_atp changes end
3781:

Line 3819: msc_sch_wb.atp_debug('x_atp_date_this_level '||x_atp_date_this_level);

3815: NVL(MSC_ATP_PVT.G_PTF_DATE, p_sys_next_date) THEN
3816:
3817: x_atp_date_this_level := NVL(MSC_ATP_PVT.G_PTF_DATE, p_sys_next_date);
3818: IF PG_DEBUG in ('Y', 'C') THEN
3819: msc_sch_wb.atp_debug('x_atp_date_this_level '||x_atp_date_this_level);
3820: END IF;
3821: IF(p_round_flag = 1) THEN --- bug 1774959
3822: x_atp_date_quantity_this_level := FLOOR(p_atp_qty_tab(k));
3823: ELSE

Line 3841: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Encountered error = ' || sqlerrm);

3837:
3838: EXCEPTION
3839: WHEN OTHERS THEN
3840: IF PG_DEBUG in ('Y', 'C') THEN
3841: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Encountered error = ' || sqlerrm);
3842: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Error Code = ' || sqlcode);
3843: END IF;
3844: x_return_status := FND_API.G_RET_STS_ERROR;
3845:

Line 3842: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Error Code = ' || sqlcode);

3838: EXCEPTION
3839: WHEN OTHERS THEN
3840: IF PG_DEBUG in ('Y', 'C') THEN
3841: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Encountered error = ' || sqlerrm);
3842: msc_sch_wb.atp_debug('Calculate_Atp_Dates_Qtys: ' || 'Error Code = ' || sqlcode);
3843: END IF;
3844: x_return_status := FND_API.G_RET_STS_ERROR;
3845:
3846: END Calculate_Atp_Dates_Qtys;

Line 4060: msc_sch_wb.atp_debug('**********Begin Check_Substitutes Procedure************');

4056: -- l_item_info_rec MSC_ATP_PVT.item_attribute_rec;
4057: BEGIN
4058:
4059: IF PG_DEBUG in ('Y', 'C') THEN
4060: msc_sch_wb.atp_debug('**********Begin Check_Substitutes Procedure************');
4061: END IF;
4062:
4063: IF PG_DEBUG in ('Y', 'C') THEN
4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');

Line 4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');

4060: msc_sch_wb.atp_debug('**********Begin Check_Substitutes Procedure************');
4061: END IF;
4062:
4063: IF PG_DEBUG in ('Y', 'C') THEN
4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');
4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));
4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));

Line 4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));

4061: END IF;
4062:
4063: IF PG_DEBUG in ('Y', 'C') THEN
4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');
4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));
4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));

Line 4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));

4062:
4063: IF PG_DEBUG in ('Y', 'C') THEN
4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');
4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));
4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));

Line 4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));

4063: IF PG_DEBUG in ('Y', 'C') THEN
4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');
4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));
4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));

Line 4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));

4064: msc_sch_wb.atp_debug('********** INPUT DATA:Check_Substitutes **********');
4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));
4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));
4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));

Line 4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));

4065: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_parent_pegging_id: '|| to_char(p_parent_pegging_id));
4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));
4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));
4073: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_quantity: '|| to_char(p_quantity));

Line 4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));

4066: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_instance_id: '|| to_char(p_instance_id));
4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));
4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));
4073: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_quantity: '|| to_char(p_quantity));
4074: END IF;

Line 4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));

4067: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_scenario_id: '|| to_char(p_scenario_id));
4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));
4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));
4073: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_quantity: '|| to_char(p_quantity));
4074: END IF;
4075: -- Loop through the substitutes and do a single level check for each of them

Line 4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));

4068: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_level: '|| to_char(p_level));
4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));
4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));
4073: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_quantity: '|| to_char(p_quantity));
4074: END IF;
4075: -- Loop through the substitutes and do a single level check for each of them
4076: -- If partial quantity is available, insert that into the details and also

Line 4073: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_quantity: '|| to_char(p_quantity));

4069: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_search: '|| to_char(p_search));
4070: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_plan_id: '|| to_char(p_plan_id));
4071: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_inventory_item_id: '|| to_char(p_inventory_item_id));
4072: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_organization_id: '|| to_char(p_organization_id));
4073: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_quantity: '|| to_char(p_quantity));
4074: END IF;
4075: -- Loop through the substitutes and do a single level check for each of them
4076: -- If partial quantity is available, insert that into the details and also
4077: -- set the flag that the component is substitute so that UI can check that

Line 4081: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Opening the substitute cursor:' || to_char(MSC_ATP_PVT.G_SESSION_ID) || ':' ||

4077: -- set the flag that the component is substitute so that UI can check that
4078: -- Keep decrementing the net_demand and exit if it is <= 0
4079: -- If the net_demand is still > 0, pass that back to the calling routing
4080: IF PG_DEBUG in ('Y', 'C') THEN
4081: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Opening the substitute cursor:' || to_char(MSC_ATP_PVT.G_SESSION_ID) || ':' ||
4082: to_char(p_parent_pegging_id) || ':' || to_char(p_plan_id) || ':'
4083: || to_char(p_instance_id) || ':' || p_inventory_item_id || ':' || p_atp_record.bill_seq_id); --4741012
4084: END IF;
4085: --bug3583705

Line 4106: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.requested_ship_date: ' || p_atp_record.requested_ship_date);

4102: /* rajjain 3008611 select component substitutes for which:
4103: * effective date is greater than or equal to greatest of PTF date, sysdate and component due date
4104: * disable date is less than or equal to greatest of PTF date, sysdate and component due date*/
4105: IF PG_DEBUG in ('Y', 'C') THEN
4106: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.requested_ship_date: ' || p_atp_record.requested_ship_date);
4107: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.shipping_cal_code: ' || p_atp_record.shipping_cal_code);
4108: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Date passed to cursor: ' ||
4109: GREATEST(p_atp_record.requested_ship_date, sysdate, MSC_ATP_PVT.G_PTF_DATE));
4110: END IF;

Line 4107: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.shipping_cal_code: ' || p_atp_record.shipping_cal_code);

4103: * effective date is greater than or equal to greatest of PTF date, sysdate and component due date
4104: * disable date is less than or equal to greatest of PTF date, sysdate and component due date*/
4105: IF PG_DEBUG in ('Y', 'C') THEN
4106: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.requested_ship_date: ' || p_atp_record.requested_ship_date);
4107: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.shipping_cal_code: ' || p_atp_record.shipping_cal_code);
4108: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Date passed to cursor: ' ||
4109: GREATEST(p_atp_record.requested_ship_date, sysdate, MSC_ATP_PVT.G_PTF_DATE));
4110: END IF;
4111:

Line 4108: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Date passed to cursor: ' ||

4104: * disable date is less than or equal to greatest of PTF date, sysdate and component due date*/
4105: IF PG_DEBUG in ('Y', 'C') THEN
4106: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.requested_ship_date: ' || p_atp_record.requested_ship_date);
4107: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'p_atp_record.shipping_cal_code: ' || p_atp_record.shipping_cal_code);
4108: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Date passed to cursor: ' ||
4109: GREATEST(p_atp_record.requested_ship_date, sysdate, MSC_ATP_PVT.G_PTF_DATE));
4110: END IF;
4111:
4112: --5216528/5216528 Start First should be having the main item.

Line 4158: msc_sch_wb.atp_debug('Check_Substitutes: ' || '**Substitute:' || to_char(l_substitute_id) || ':'

4154: x_substitutes_rec.inventory_item_id(l_index) := l_substitute_id;
4155: --5216528/5216528 End
4156: end if;
4157: IF PG_DEBUG in ('Y', 'C') THEN
4158: msc_sch_wb.atp_debug('Check_Substitutes: ' || '**Substitute:' || to_char(l_substitute_id) || ':'
4159: || to_char(l_usage) || ':' || l_atp_flag || ':' ||
4160: to_char(l_primary_comp_usage));
4161: --4570421
4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);

Line 4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);

4158: msc_sch_wb.atp_debug('Check_Substitutes: ' || '**Substitute:' || to_char(l_substitute_id) || ':'
4159: || to_char(l_usage) || ':' || l_atp_flag || ':' ||
4160: to_char(l_primary_comp_usage));
4161: --4570421
4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);
4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);
4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);
4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);
4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);

Line 4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);

4159: || to_char(l_usage) || ':' || l_atp_flag || ':' ||
4160: to_char(l_primary_comp_usage));
4161: --4570421
4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);
4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);
4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);
4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);
4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);
4167: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_usage_qty: ' || l_usage_qty);

Line 4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);

4160: to_char(l_primary_comp_usage));
4161: --4570421
4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);
4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);
4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);
4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);
4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);
4167: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_usage_qty: ' || l_usage_qty);
4168:

Line 4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);

4161: --4570421
4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);
4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);
4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);
4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);
4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);
4167: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_usage_qty: ' || l_usage_qty);
4168:
4169:

Line 4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);

4162: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scaling_type: ' || l_scaling_type);
4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);
4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);
4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);
4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);
4167: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_usage_qty: ' || l_usage_qty);
4168:
4169:
4170: END IF;

Line 4167: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_usage_qty: ' || l_usage_qty);

4163: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_multiple: ' || l_scale_multiple);
4164: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_scale_rounding_variance: ' || l_scale_rounding_variance);
4165: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_rounding_direction: ' || l_rounding_direction);
4166: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_component_yield_factor: ' || l_component_yield_factor);
4167: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_usage_qty: ' || l_usage_qty);
4168:
4169:
4170: END IF;
4171: -- Setup new g_atp_record during each loop, we should not resue the

Line 4239: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Before calling subs atp info');

4235: l_requested_ship_date := g_atp_record.requested_ship_date;
4236:
4237:
4238: IF PG_DEBUG in ('Y', 'C') THEN
4239: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Before calling subs atp info');
4240: END IF;
4241:
4242: -- bug 1665483:
4243: --IF (MSC_ATP_PVT.G_HIERARCHY_PROFILE = 2) AND ((MSC_ATP_PVT.G_ALLOCATED_ATP = 'Y')

Line 4280: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Error encountered in call to Get_PF_Plan_Info');

4276: );
4277:
4278: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
4279: IF PG_DEBUG in ('Y', 'C') THEN
4280: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'Error encountered in call to Get_PF_Plan_Info');
4281: END IF;
4282: END IF;
4283: /* time_phased_atp changes end*/
4284:

Line 4303: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'ATP Downtime Encountered');

4299: END IF;
4300:
4301: if (l_plan_id = -300) then
4302: IF PG_DEBUG in ('Y', 'C') THEN
4303: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'ATP Downtime Encountered');
4304: END IF;
4305: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;
4306: end if;
4307:

Line 4317: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

4313: -- To handle case where family item id is different re-set it.
4314: g_atp_record.inventory_item_id := g_atp_record.request_item_id;
4315: l_pf_item_id := l_inv_item_id;
4316: IF PG_DEBUG in ('Y', 'C') THEN
4317: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
4318: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'PF and Allocated ATP not applicable for DRP plans');
4319: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.inventory_item_id' ||
4320: g_atp_record.inventory_item_id);
4321: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.request_item_id' ||

Line 4318: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'PF and Allocated ATP not applicable for DRP plans');

4314: g_atp_record.inventory_item_id := g_atp_record.request_item_id;
4315: l_pf_item_id := l_inv_item_id;
4316: IF PG_DEBUG in ('Y', 'C') THEN
4317: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
4318: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'PF and Allocated ATP not applicable for DRP plans');
4319: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.inventory_item_id' ||
4320: g_atp_record.inventory_item_id);
4321: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.request_item_id' ||
4322: g_atp_record.request_item_id);

Line 4319: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.inventory_item_id' ||

4315: l_pf_item_id := l_inv_item_id;
4316: IF PG_DEBUG in ('Y', 'C') THEN
4317: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
4318: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'PF and Allocated ATP not applicable for DRP plans');
4319: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.inventory_item_id' ||
4320: g_atp_record.inventory_item_id);
4321: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.request_item_id' ||
4322: g_atp_record.request_item_id);
4323: END IF;

Line 4321: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.request_item_id' ||

4317: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
4318: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'PF and Allocated ATP not applicable for DRP plans');
4319: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.inventory_item_id' ||
4320: g_atp_record.inventory_item_id);
4321: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'g_atp_record.request_item_id' ||
4322: g_atp_record.request_item_id);
4323: END IF;
4324: ELSE
4325: -- time_phased_atp changes begin

Line 4409: msc_sch_wb.atp_debug('Check_Substitutes: Lot Based or Fixed Scaling ');

4405: ElSE
4406: l_net_demand := 0;
4407: END IF;
4408: IF PG_DEBUG in ('Y', 'C') THEN
4409: msc_sch_wb.atp_debug('Check_Substitutes: Lot Based or Fixed Scaling ');
4410: msc_sch_wb.atp_debug('Check_Substitutes: l_lot_fail : '|| to_char(l_lot_fail));
4411: END IF;
4412: ELSIF (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.OPM_ORG AND nvl(l_scaling_type,1) IN (4,5)) THEN --Integer Scaling
4413: l_net_demand := (g_atp_record.quantity_ordered -

Line 4410: msc_sch_wb.atp_debug('Check_Substitutes: l_lot_fail : '|| to_char(l_lot_fail));

4406: l_net_demand := 0;
4407: END IF;
4408: IF PG_DEBUG in ('Y', 'C') THEN
4409: msc_sch_wb.atp_debug('Check_Substitutes: Lot Based or Fixed Scaling ');
4410: msc_sch_wb.atp_debug('Check_Substitutes: l_lot_fail : '|| to_char(l_lot_fail));
4411: END IF;
4412: ELSIF (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.OPM_ORG AND nvl(l_scaling_type,1) IN (4,5)) THEN --Integer Scaling
4413: l_net_demand := (g_atp_record.quantity_ordered -
4414: FLOOR(greatest(l_requested_date_quantity, 0)/l_scale_multiple) *l_scale_multiple);

Line 4416: msc_sch_wb.atp_debug('Check_Substitutes: Integer_scaling ');

4412: ELSIF (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.OPM_ORG AND nvl(l_scaling_type,1) IN (4,5)) THEN --Integer Scaling
4413: l_net_demand := (g_atp_record.quantity_ordered -
4414: FLOOR(greatest(l_requested_date_quantity, 0)/l_scale_multiple) *l_scale_multiple);
4415: IF PG_DEBUG in ('Y', 'C') THEN
4416: msc_sch_wb.atp_debug('Check_Substitutes: Integer_scaling ');
4417: END IF;
4418: ELSE
4419: l_net_demand := (g_atp_record.quantity_ordered -
4420: greatest(l_requested_date_quantity, 0)) *

Line 4430: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_net_demand : '|| to_char(l_net_demand));

4426: (1/l_usage); */
4427:
4428: -- print the net_demand
4429: IF PG_DEBUG in ('Y', 'C') THEN
4430: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'l_net_demand : '|| to_char(l_net_demand));
4431: END IF;
4432:
4433: -- if we don't have atp for this sub component , don't bother
4434: -- generate pegging tree, demand record.

Line 4473: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'DRP origination_type ='|| l_atp_insert_rec.origination_type);

4469: -- for DRP plans.
4470: IF NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_type,1) = 5 THEN
4471: l_atp_insert_rec.origination_type := 47;
4472: IF PG_DEBUG in ('Y', 'C') THEN
4473: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'DRP origination_type ='|| l_atp_insert_rec.origination_type);
4474: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
4475: END IF;
4476: ELSE
4477: l_atp_insert_rec.origination_type := 1;

Line 4474: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

4470: IF NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_type,1) = 5 THEN
4471: l_atp_insert_rec.origination_type := 47;
4472: IF PG_DEBUG in ('Y', 'C') THEN
4473: msc_sch_wb.atp_debug('Check_Substitutes: ' || 'DRP origination_type ='|| l_atp_insert_rec.origination_type);
4474: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
4475: END IF;
4476: ELSE
4477: l_atp_insert_rec.origination_type := 1;
4478: END IF;

Line 4670: msc_sch_wb.atp_debug ('Check Substitutes : Plan Downtime encountered');

4666: EXCEPTION
4667: -- 24x7
4668: WHEN MSC_ATP_PVT.EXC_NO_PLAN_FOUND THEN
4669: IF PG_DEBUG in ('Y', 'C') THEN
4670: msc_sch_wb.atp_debug ('Check Substitutes : Plan Downtime encountered');
4671: END IF;
4672: MSC_ATP_PVT.G_DOWNTIME_HIT := 'Y';
4673: MSC_ATP_PVT.G_SUMMARY_FLAG := l_summary_flag;
4674: l_return_status := FND_API.G_RET_STS_ERROR;

Line 4680: msc_sch_wb.atp_debug ('Check Substitutes : NO_MATCHING_DATE_IN_CAL');

4676: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;
4677:
4678: WHEN MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL THEN --bug3583705
4679: IF PG_DEBUG in ('Y', 'C') THEN
4680: msc_sch_wb.atp_debug ('Check Substitutes : NO_MATCHING_DATE_IN_CAL');
4681: END IF;
4682: MSC_ATP_PVT.G_SUMMARY_FLAG := l_summary_flag;
4683: l_return_status := FND_API.G_RET_STS_ERROR;
4684: CLOSE substitute;

Line 4751: msc_sch_wb.atp_debug('**********Begin Get_Material_Atp_Info Procedure************');

4747:
4748: BEGIN
4749:
4750: IF PG_DEBUG in ('Y', 'C') THEN
4751: msc_sch_wb.atp_debug('**********Begin Get_Material_Atp_Info Procedure************');
4752: END IF;
4753:
4754: -- initialize API return status to success
4755: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 4758: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Material_Atp_Info **********');

4754: -- initialize API return status to success
4755: x_return_status := FND_API.G_RET_STS_SUCCESS;
4756:
4757: IF PG_DEBUG in ('Y', 'C') THEN
4758: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Material_Atp_Info **********');
4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));
4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));

Line 4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));

4755: x_return_status := FND_API.G_RET_STS_SUCCESS;
4756:
4757: IF PG_DEBUG in ('Y', 'C') THEN
4758: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Material_Atp_Info **********');
4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));
4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));

Line 4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));

4756:
4757: IF PG_DEBUG in ('Y', 'C') THEN
4758: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Material_Atp_Info **********');
4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));
4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));

Line 4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));

4757: IF PG_DEBUG in ('Y', 'C') THEN
4758: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Material_Atp_Info **********');
4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));
4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));

Line 4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));

4758: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Material_Atp_Info **********');
4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));
4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));

Line 4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));

4759: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.inventory_item_id: '|| to_char(p_mat_atp_info_rec.inventory_item_id));
4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);

Line 4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));

4760: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.request_item_id: '|| to_char(p_mat_atp_info_rec.request_item_id));
4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);

Line 4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));

4761: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.organization_id: '|| to_char(p_mat_atp_info_rec.organization_id));
4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);
4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);

Line 4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));

4762: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);
4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);
4770: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.shipping_cal_code: '|| p_mat_atp_info_rec.shipping_cal_code);

Line 4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);

4763: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.instance_id: '|| to_char(p_mat_atp_info_rec.instance_id));
4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);
4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);
4770: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.shipping_cal_code: '|| p_mat_atp_info_rec.shipping_cal_code);
4771: END IF;

Line 4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);

4764: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.plan_id: '|| to_char(p_mat_atp_info_rec.plan_id));
4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);
4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);
4770: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.shipping_cal_code: '|| p_mat_atp_info_rec.shipping_cal_code);
4771: END IF;
4772: /* time_phased_atp changes begin*/

Line 4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);

4765: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.quantity_ordered: '|| to_char(p_mat_atp_info_rec.quantity_ordered));
4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);
4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);
4770: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.shipping_cal_code: '|| p_mat_atp_info_rec.shipping_cal_code);
4771: END IF;
4772: /* time_phased_atp changes begin*/
4773: IF (MSC_ATP_PVT.G_INV_CTP = 4)

Line 4770: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.shipping_cal_code: '|| p_mat_atp_info_rec.shipping_cal_code);

4766: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.insert_flag: '|| to_char(p_mat_atp_info_rec.insert_flag));
4767: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.demand_class: '|| p_mat_atp_info_rec.demand_class);
4768: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.substitution_window := '|| p_mat_atp_info_rec.substitution_window);
4769: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atf_date: '|| p_mat_atp_info_rec.atf_date);
4770: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.shipping_cal_code: '|| p_mat_atp_info_rec.shipping_cal_code);
4771: END IF;
4772: /* time_phased_atp changes begin*/
4773: IF (MSC_ATP_PVT.G_INV_CTP = 4)
4774: and (p_mat_atp_info_rec.inventory_item_id <> p_mat_atp_info_rec.request_item_id)

Line 4789: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_request_item_id := ' || l_request_item_id);

4785: l_request_item_id := p_mat_atp_info_rec.request_item_id;
4786: END IF;
4787:
4788: IF PG_DEBUG in ('Y', 'C') THEN
4789: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_request_item_id := ' || l_request_item_id);
4790: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Time Phased ATP = ' || l_time_phased_atp);
4791: END IF;
4792: /* time_phased_atp changes end*/
4793:

Line 4790: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Time Phased ATP = ' || l_time_phased_atp);

4786: END IF;
4787:
4788: IF PG_DEBUG in ('Y', 'C') THEN
4789: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_request_item_id := ' || l_request_item_id);
4790: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Time Phased ATP = ' || l_time_phased_atp);
4791: END IF;
4792: /* time_phased_atp changes end*/
4793:
4794: -- get the infinite time fence date if it exists

Line 4808: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' ATP Rule := ' || p_mat_atp_info_rec.atp_rule_name);

4804:
4805: p_mat_atp_info_rec.infinite_time_fence_date := l_infinite_time_fence_date;
4806: l_get_mat_in_rec.infinite_time_fence_date := l_infinite_time_fence_date;
4807: IF PG_DEBUG in ('Y', 'C') THEN
4808: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' ATP Rule := ' || p_mat_atp_info_rec.atp_rule_name);
4809: END IF;
4810:
4811: -- 2859130 get if this is a constrained plan or not
4812: IF p_mat_atp_info_rec.plan_id <> -1 THEN

Line 4838: msc_sch_wb.atp_debug('Optimized plan: ' || MSC_ATP_PVT.G_OPTIMIZED_PLAN);

4834: END IF;
4835: l_get_mat_in_rec.optimized_plan := MSC_ATP_PVT.G_OPTIMIZED_PLAN; -- 2859130
4836:
4837: IF PG_DEBUG in ('Y', 'C') THEN
4838: msc_sch_wb.atp_debug('Optimized plan: ' || MSC_ATP_PVT.G_OPTIMIZED_PLAN);
4839: END IF;
4840:
4841: --- bug 1819638: get next working day.
4842:

Line 4861: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' RAISING EXCEPTION for NO ATP RULE ');

4857: IF (MSC_ATP_PVT.G_INV_CTP = 5) AND
4858: (l_default_atp_rule_id IS NULL) AND -- no default rule at org level
4859: (MSC_ATP_PVT.G_ATP_RULE_FLAG = 'N') THEN
4860: IF PG_DEBUG in ('Y', 'C') THEN
4861: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' RAISING EXCEPTION for NO ATP RULE ');
4862: END IF;
4863: RAISE MSC_ATP_PVT.EXC_NO_ATP_RULE; -- ATPeable item has no rule
4864: ELSE
4865: IF PG_DEBUG in ('Y', 'C') THEN

Line 4866: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'ATP RULE EXISTS at Item or Org level ' ||

4862: END IF;
4863: RAISE MSC_ATP_PVT.EXC_NO_ATP_RULE; -- ATPeable item has no rule
4864: ELSE
4865: IF PG_DEBUG in ('Y', 'C') THEN
4866: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'ATP RULE EXISTS at Item or Org level ' ||
4867: 'ORG LEVEL Default Rule: '||l_default_atp_rule_id);
4868: END IF;
4869: MSC_ATP_PVT.G_ATP_RULE_FLAG := 'Y'; -- Item has an applicable ATP rule
4870: END IF;

Line 4902: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sysdate_seq_num = ' || l_sysdate_seq_num);

4898: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
4899: END;
4900:
4901: IF PG_DEBUG in ('Y', 'C') THEN
4902: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sysdate_seq_num = ' || l_sysdate_seq_num);
4903: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_date = ' || l_sys_next_date);
4904: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_osc_date = ' || l_sys_next_osc_date);
4905: END IF;
4906: -- in case we want to support flex date

Line 4903: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_date = ' || l_sys_next_date);

4899: END;
4900:
4901: IF PG_DEBUG in ('Y', 'C') THEN
4902: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sysdate_seq_num = ' || l_sysdate_seq_num);
4903: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_date = ' || l_sys_next_date);
4904: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_osc_date = ' || l_sys_next_osc_date);
4905: END IF;
4906: -- in case we want to support flex date
4907: l_requested_date := p_mat_atp_info_rec.requested_date;

Line 4904: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_osc_date = ' || l_sys_next_osc_date);

4900:
4901: IF PG_DEBUG in ('Y', 'C') THEN
4902: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sysdate_seq_num = ' || l_sysdate_seq_num);
4903: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_date = ' || l_sys_next_date);
4904: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_sys_next_osc_date = ' || l_sys_next_osc_date);
4905: END IF;
4906: -- in case we want to support flex date
4907: l_requested_date := p_mat_atp_info_rec.requested_date;
4908:

Line 4910: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_infinite_time_fence_date: '|| to_char(l_infinite_time_fence_date));

4906: -- in case we want to support flex date
4907: l_requested_date := p_mat_atp_info_rec.requested_date;
4908:
4909: IF PG_DEBUG in ('Y', 'C') THEN
4910: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_infinite_time_fence_date: '|| to_char(l_infinite_time_fence_date));
4911: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4912: END IF;
4913:
4914: IF (l_requested_date >=

Line 4911: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));

4907: l_requested_date := p_mat_atp_info_rec.requested_date;
4908:
4909: IF PG_DEBUG in ('Y', 'C') THEN
4910: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_infinite_time_fence_date: '|| to_char(l_infinite_time_fence_date));
4911: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_requested_date: '|| to_char(p_mat_atp_info_rec.requested_date));
4912: END IF;
4913:
4914: IF (l_requested_date >=
4915: NVL(l_infinite_time_fence_date, l_requested_date +1)) THEN

Line 4942: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'MSC_ATP_PVT.G_SUMMARY_FLAG := ' || MSC_ATP_PVT.G_SUMMARY_FLAG);

4938: -- if we need the detail information, we will get individual s/d rows
4939: -- and do the sum ourselves. if we don't need the detail infomation,
4940: -- we will do a group by and select the sum in the sql statement.
4941: IF PG_DEBUG in ('Y', 'C') THEN
4942: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'MSC_ATP_PVT.G_SUMMARY_FLAG := ' || MSC_ATP_PVT.G_SUMMARY_FLAG);
4943: END IF;
4944:
4945: -- 2859130 replace sql stmts with calls to procedures containing the sql stmts
4946: IF nvl(p_mat_atp_info_rec.insert_flag, 0) = 0 THEN

Line 4992: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Get_Mat_Avail_Pf');

4988: l_return_status
4989: );
4990: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
4991: IF PG_DEBUG in ('Y', 'C') THEN
4992: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Get_Mat_Avail_Pf');
4993: END IF;
4994: RAISE FND_API.G_EXC_ERROR;
4995: END IF;
4996: END IF;

Line 4999: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'after getting netted qtys');

4995: END IF;
4996: END IF;
4997:
4998: IF PG_DEBUG in ('Y', 'C') THEN
4999: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'after getting netted qtys');
5000: END IF;
5001:
5002: -- time_phased_atp
5003: IF l_time_phased_atp = 'Y' THEN

Line 5012: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Pf_Atp_Consume');

5008: MSC_ATP_PF.Bw_Fw_Cum, --b/w, f/w consumption and accumulation
5009: p_mat_atp_info_rec.atf_date);
5010: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
5011: IF PG_DEBUG in ('Y', 'C') THEN
5012: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Pf_Atp_Consume');
5013: END IF;
5014: RAISE FND_API.G_EXC_ERROR;
5015: END IF;
5016: ELSE

Line 5020: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'after atp_consume');

5016: ELSE
5017: MSC_ATP_PROC.atp_consume(l_atp_qty_tab, l_atp_qty_tab.count);
5018: END IF;
5019: IF PG_DEBUG in ('Y', 'C') THEN
5020: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'after atp_consume');
5021: END IF;
5022:
5023: /* Cum drop issue changes begin*/
5024: MSC_AATP_PROC.Atp_Remove_Negatives(l_atp_qty_tab, l_return_status);

Line 5027: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');

5023: /* Cum drop issue changes begin*/
5024: MSC_AATP_PROC.Atp_Remove_Negatives(l_atp_qty_tab, l_return_status);
5025: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
5026: IF PG_DEBUG in ('Y', 'C') THEN
5027: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');
5028: END IF;
5029: RAISE FND_API.G_EXC_ERROR;
5030: END IF;
5031: /* Cum drop issue changes end*/

Line 5037: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'adding itf');

5033: IF l_infinite_time_fence_date IS NOT NULL THEN
5034: -- add one more entry to indicate infinite time fence date
5035: -- and quantity.
5036: IF PG_DEBUG in ('Y', 'C') THEN
5037: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'adding itf');
5038: END IF;
5039: l_atp_period_tab.EXTEND;
5040: l_atp_qty_tab.EXTEND;
5041: l_atp_period_tab(l_atp_period_tab.count) := l_infinite_time_fence_date;

Line 5070: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'after Insert_Details');

5066: l_get_mat_in_rec,
5067: p_mat_atp_info_rec.atf_date); -- For time_phased_atp
5068:
5069: IF PG_DEBUG in ('Y', 'C') THEN
5070: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'after Insert_Details');
5071: END IF;
5072:
5073: l_atp_period_tab := x_atp_period.Period_Start_Date;
5074: l_atp_qty_tab := x_atp_period.Cumulative_Quantity;

Line 5094: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);

5090: l_org_code := MSC_ATP_PVT.G_ORG_INFO_REC.org_code;
5091: /*Modularize Item and Org Info */
5092:
5093: IF PG_DEBUG in ('Y', 'C') THEN
5094: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5095: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
5096: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5097: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_demand_class'|| l_default_demand_class);
5098: END IF;

Line 5095: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);

5091: /*Modularize Item and Org Info */
5092:
5093: IF PG_DEBUG in ('Y', 'C') THEN
5094: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5095: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
5096: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5097: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_demand_class'|| l_default_demand_class);
5098: END IF;
5099: IF MSC_ATP_PVT.G_ALLOCATION_METHOD = 1 AND MSC_ATP_PVT.G_HIERARCHY_PROFILE = 1 THEN

Line 5096: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);

5092:
5093: IF PG_DEBUG in ('Y', 'C') THEN
5094: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5095: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
5096: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5097: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_demand_class'|| l_default_demand_class);
5098: END IF;
5099: IF MSC_ATP_PVT.G_ALLOCATION_METHOD = 1 AND MSC_ATP_PVT.G_HIERARCHY_PROFILE = 1 THEN
5100: IF PG_DEBUG in ('Y', 'C') THEN

Line 5097: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_demand_class'|| l_default_demand_class);

5093: IF PG_DEBUG in ('Y', 'C') THEN
5094: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5095: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
5096: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5097: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_demand_class'|| l_default_demand_class);
5098: END IF;
5099: IF MSC_ATP_PVT.G_ALLOCATION_METHOD = 1 AND MSC_ATP_PVT.G_HIERARCHY_PROFILE = 1 THEN
5100: IF PG_DEBUG in ('Y', 'C') THEN
5101: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Pre-alllocated demand class AATP');

Line 5101: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Pre-alllocated demand class AATP');

5097: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_default_demand_class'|| l_default_demand_class);
5098: END IF;
5099: IF MSC_ATP_PVT.G_ALLOCATION_METHOD = 1 AND MSC_ATP_PVT.G_HIERARCHY_PROFILE = 1 THEN
5100: IF PG_DEBUG in ('Y', 'C') THEN
5101: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Pre-alllocated demand class AATP');
5102: END IF;
5103:
5104: --diag_atp: pass infinite time fence as in parameter so that we dont need to recalculate it
5105: l_get_mat_in_rec.infinite_time_fence_date := l_infinite_time_fence_date;

Line 5135: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Customer class or Allocation based demand class AATP');

5131: -- rajjain 02/20/2003 Bug 2813095 End
5132: ELSE
5133:
5134: IF PG_DEBUG in ('Y', 'C') THEN
5135: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Customer class or Allocation based demand class AATP');
5136: END IF;
5137: --diag_atp: pass infinite time fence as in parameter so that we dont need to recalculate it
5138: l_get_mat_in_rec.infinite_time_fence_date := l_infinite_time_fence_date;
5139: l_get_mat_in_rec.dest_inv_item_id := p_mat_atp_info_rec.dest_inv_item_id;

Line 5176: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_period.count = '||l_atp_info.atp_period.COUNT);

5172: END IF;
5173: --Bug2471377 End Changes.
5174:
5175: IF PG_DEBUG in ('Y', 'C') THEN
5176: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_period.count = '||l_atp_info.atp_period.COUNT);
5177: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_qty.count = '||l_atp_info.atp_qty.COUNT);
5178: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.limit_qty.count = '||l_atp_info.limit_qty.COUNT);
5179: END IF;
5180:

Line 5177: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_qty.count = '||l_atp_info.atp_qty.COUNT);

5173: --Bug2471377 End Changes.
5174:
5175: IF PG_DEBUG in ('Y', 'C') THEN
5176: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_period.count = '||l_atp_info.atp_period.COUNT);
5177: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_qty.count = '||l_atp_info.atp_qty.COUNT);
5178: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.limit_qty.count = '||l_atp_info.limit_qty.COUNT);
5179: END IF;
5180:
5181: END IF; -- end of G_ALLOCATED_ATP

Line 5178: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.limit_qty.count = '||l_atp_info.limit_qty.COUNT);

5174:
5175: IF PG_DEBUG in ('Y', 'C') THEN
5176: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_period.count = '||l_atp_info.atp_period.COUNT);
5177: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.atp_qty.count = '||l_atp_info.atp_qty.COUNT);
5178: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_info.limit_qty.count = '||l_atp_info.limit_qty.COUNT);
5179: END IF;
5180:
5181: END IF; -- end of G_ALLOCATED_ATP
5182:

Line 5184: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_period_tabl.count = '||l_atp_period_tab.COUNT);

5180:
5181: END IF; -- end of G_ALLOCATED_ATP
5182:
5183: IF PG_DEBUG in ('Y', 'C') THEN
5184: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_atp_period_tabl.count = '||l_atp_period_tab.COUNT);
5185: END IF;
5186:
5187: IF l_atp_period_tab.COUNT = 0 THEN
5188: -- need to add error message

Line 5218: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level :=' || p_mat_atp_info_rec.atp_date_this_level);

5214: END IF; --end if l_requested_date > l_infinite_time_fence_date
5215: --- subst
5216: --- IF future date is after substitution window then we will move atp date to infinite time fence date
5217: IF PG_DEBUG in ('Y', 'C') THEN
5218: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level :=' || p_mat_atp_info_rec.atp_date_this_level);
5219: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_infinite_time_fence_date := ' || l_infinite_time_fence_date);
5220: END IF;
5221:
5222: IF MSC_ATP_PVT.G_SUBSTITUTION_FLAG = 'Y' AND NVL(p_mat_atp_info_rec.substitution_window,0) > 0

Line 5219: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_infinite_time_fence_date := ' || l_infinite_time_fence_date);

5215: --- subst
5216: --- IF future date is after substitution window then we will move atp date to infinite time fence date
5217: IF PG_DEBUG in ('Y', 'C') THEN
5218: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level :=' || p_mat_atp_info_rec.atp_date_this_level);
5219: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_infinite_time_fence_date := ' || l_infinite_time_fence_date);
5220: END IF;
5221:
5222: IF MSC_ATP_PVT.G_SUBSTITUTION_FLAG = 'Y' AND NVL(p_mat_atp_info_rec.substitution_window,0) > 0
5223: AND p_mat_atp_info_rec.atp_date_this_level is not null THEN

Line 5225: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'we have substitution window');

5221:
5222: IF MSC_ATP_PVT.G_SUBSTITUTION_FLAG = 'Y' AND NVL(p_mat_atp_info_rec.substitution_window,0) > 0
5223: AND p_mat_atp_info_rec.atp_date_this_level is not null THEN
5224: IF PG_DEBUG in ('Y', 'C') THEN
5225: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'we have substitution window');
5226: END IF;
5227: IF l_infinite_time_fence_date is not null and p_mat_atp_info_rec.atp_date_this_level = l_infinite_time_fence_date THEN
5228: IF PG_DEBUG in ('Y', 'C') THEN
5229: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level = infinite supply, dont move the date');

Line 5229: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level = infinite supply, dont move the date');

5225: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'we have substitution window');
5226: END IF;
5227: IF l_infinite_time_fence_date is not null and p_mat_atp_info_rec.atp_date_this_level = l_infinite_time_fence_date THEN
5228: IF PG_DEBUG in ('Y', 'C') THEN
5229: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level = infinite supply, dont move the date');
5230: END IF;
5231: ELSE
5232: IF PG_DEBUG in ('Y', 'C') THEN
5233: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Do substitution check');

Line 5233: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Do substitution check');

5229: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level = infinite supply, dont move the date');
5230: END IF;
5231: ELSE
5232: IF PG_DEBUG in ('Y', 'C') THEN
5233: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Do substitution check');
5234: END IF;
5235: l_subst_limit_date := MSC_CALENDAR.DATE_OFFSET(
5236: p_mat_atp_info_rec.organization_id,
5237: p_mat_atp_info_rec.instance_id,

Line 5242: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_subst_limit_date := ' || l_subst_limit_date);

5238: 1,
5239: p_mat_atp_info_rec.requested_date,
5240: p_mat_atp_info_rec.substitution_window);
5241: IF PG_DEBUG in ('Y', 'C') THEN
5242: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_subst_limit_date := ' || l_subst_limit_date);
5243: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level := ' || p_mat_atp_info_rec.atp_date_this_level);
5244: END IF;
5245: IF p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date THEN
5246: IF PG_DEBUG in ('Y', 'C') THEN

Line 5243: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level := ' || p_mat_atp_info_rec.atp_date_this_level);

5239: p_mat_atp_info_rec.requested_date,
5240: p_mat_atp_info_rec.substitution_window);
5241: IF PG_DEBUG in ('Y', 'C') THEN
5242: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'l_subst_limit_date := ' || l_subst_limit_date);
5243: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level := ' || p_mat_atp_info_rec.atp_date_this_level);
5244: END IF;
5245: IF p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date THEN
5246: IF PG_DEBUG in ('Y', 'C') THEN
5247: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date');

Line 5247: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date');

5243: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'p_mat_atp_info_rec.atp_date_this_level := ' || p_mat_atp_info_rec.atp_date_this_level);
5244: END IF;
5245: IF p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date THEN
5246: IF PG_DEBUG in ('Y', 'C') THEN
5247: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date');
5248: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'moving p_mat_atp_info_rec.atp_date_this_level to infinite time fence');
5249: END IF;
5250: p_mat_atp_info_rec.atp_date_this_level := l_infinite_time_fence_date;
5251: p_mat_atp_info_rec.atp_date_quantity_this_level := MSC_ATP_PVT.INFINITE_NUMBER;

Line 5248: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'moving p_mat_atp_info_rec.atp_date_this_level to infinite time fence');

5244: END IF;
5245: IF p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date THEN
5246: IF PG_DEBUG in ('Y', 'C') THEN
5247: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || ' p_mat_atp_info_rec.atp_date_this_level > l_subst_limit_date');
5248: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'moving p_mat_atp_info_rec.atp_date_this_level to infinite time fence');
5249: END IF;
5250: p_mat_atp_info_rec.atp_date_this_level := l_infinite_time_fence_date;
5251: p_mat_atp_info_rec.atp_date_quantity_this_level := MSC_ATP_PVT.INFINITE_NUMBER;
5252: END IF;

Line 5257: msc_sch_wb.atp_debug('**********End Get_Material_Atp_Info Procedure************');

5253: END IF;
5254: END IF;
5255:
5256: IF PG_DEBUG in ('Y', 'C') THEN
5257: msc_sch_wb.atp_debug('**********End Get_Material_Atp_Info Procedure************');
5258: END IF;
5259:
5260: EXCEPTION
5261:

Line 5279: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'No match for sysdate in cal');

5275: --- we are using exceptions
5276: WHEN MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL THEN
5277: p_mat_atp_info_rec.requested_date_quantity := 0.0;
5278: IF PG_DEBUG in ('Y', 'C') THEN
5279: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'No match for sysdate in cal');
5280: END IF;
5281: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
5282:
5283: /************ Bug 1510853 ATP Rule Check ************/

Line 5287: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'No Applicable ATP rule in Get Material ATP Info');

5283: /************ Bug 1510853 ATP Rule Check ************/
5284: WHEN MSC_ATP_PVT.EXC_NO_ATP_RULE THEN
5285: p_mat_atp_info_rec.requested_date_quantity := 0.0;
5286: IF PG_DEBUG in ('Y', 'C') THEN
5287: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'No Applicable ATP rule in Get Material ATP Info');
5288: END IF;
5289: RAISE MSC_ATP_PVT.EXC_NO_ATP_RULE;
5290:
5291: -- rajjain 02/20/2003 Bug 2813095

Line 5294: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' ||

5290:
5291: -- rajjain 02/20/2003 Bug 2813095
5292: WHEN MSC_ATP_PVT.ALLOC_ATP_INVALID_PROFILE THEN
5293: IF PG_DEBUG in ('Y', 'C') THEN
5294: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' ||
5295: 'Incompatible setup of MSC: ATP Allocation Method and MSC: Class Hierarchy');
5296: END IF;
5297: RAISE MSC_ATP_PVT.ALLOC_ATP_INVALID_PROFILE;
5298:

Line 5303: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Get_Mater, sqlcode= '||temp);

5299: WHEN OTHERS THEN
5300: temp := SQLCODE;
5301: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5302: IF PG_DEBUG in ('Y', 'C') THEN
5303: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Get_Mater, sqlcode= '||temp);
5304: msc_sch_wb.atp_debug ('Get_Material_Atp_Info: IN Exception Block in others');
5305: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
5306: END IF;
5307: --bug3583705 commenting this out as this resets the FND_MESSAGE.SET_NAME

Line 5304: msc_sch_wb.atp_debug ('Get_Material_Atp_Info: IN Exception Block in others');

5300: temp := SQLCODE;
5301: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5302: IF PG_DEBUG in ('Y', 'C') THEN
5303: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Get_Mater, sqlcode= '||temp);
5304: msc_sch_wb.atp_debug ('Get_Material_Atp_Info: IN Exception Block in others');
5305: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
5306: END IF;
5307: --bug3583705 commenting this out as this resets the FND_MESSAGE.SET_NAME
5308: /*IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN

Line 5305: msc_sch_wb.atp_debug ('error := ' || SQLERRM);

5301: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5302: IF PG_DEBUG in ('Y', 'C') THEN
5303: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Get_Mater, sqlcode= '||temp);
5304: msc_sch_wb.atp_debug ('Get_Material_Atp_Info: IN Exception Block in others');
5305: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
5306: END IF;
5307: --bug3583705 commenting this out as this resets the FND_MESSAGE.SET_NAME
5308: /*IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
5309: FND_MSG_PUB.Add_Exc_Msg (G_PKG_NAME , 'Get_Material_Atp_Info');

Line 5368: msc_sch_wb.atp_debug('***** Begin Insert_Details Procedure *****');

5364:
5365: Begin
5366:
5367: IF PG_DEBUG in ('Y', 'C') THEN
5368: msc_sch_wb.atp_debug('***** Begin Insert_Details Procedure *****');
5369: END IF;
5370:
5371: x_return_status := FND_API.G_RET_STS_SUCCESS;
5372:

Line 5377: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_atf_date := ' || p_atf_date);

5373: IF p_insert_flag >0 THEN
5374:
5375: /* time_phased_atp changes begin*/
5376: IF PG_DEBUG in ('Y', 'C') THEN
5377: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_atf_date := ' || p_atf_date);
5378: END IF;
5379: IF (MSC_ATP_PVT.G_INV_CTP = 4) and (p_inventory_item_id <> p_request_item_id) and (p_atf_date is null) THEN
5380: l_request_item_id := p_inventory_item_id;
5381: ELSIF (MSC_ATP_PVT.G_INV_CTP = 4) and (p_inventory_item_id <> p_request_item_id) and (p_atf_date is not null) THEN

Line 5388: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_request_item_id := ' || p_request_item_id);

5384: ELSE
5385: l_request_item_id := p_request_item_id;
5386: END IF;
5387: IF PG_DEBUG in ('Y', 'C') THEN
5388: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_request_item_id := ' || p_request_item_id);
5389: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_inventory_item_id := ' || p_inventory_item_id);
5390: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_request_item_id := ' || l_request_item_id);
5391: msc_sch_wb.atp_debug('Insert_Details: ' || 'Time Phased ATP = ' || l_time_phased_atp);
5392: END IF;

Line 5389: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_inventory_item_id := ' || p_inventory_item_id);

5385: l_request_item_id := p_request_item_id;
5386: END IF;
5387: IF PG_DEBUG in ('Y', 'C') THEN
5388: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_request_item_id := ' || p_request_item_id);
5389: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_inventory_item_id := ' || p_inventory_item_id);
5390: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_request_item_id := ' || l_request_item_id);
5391: msc_sch_wb.atp_debug('Insert_Details: ' || 'Time Phased ATP = ' || l_time_phased_atp);
5392: END IF;
5393: /* time_phased_atp changes end*/

Line 5390: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_request_item_id := ' || l_request_item_id);

5386: END IF;
5387: IF PG_DEBUG in ('Y', 'C') THEN
5388: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_request_item_id := ' || p_request_item_id);
5389: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_inventory_item_id := ' || p_inventory_item_id);
5390: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_request_item_id := ' || l_request_item_id);
5391: msc_sch_wb.atp_debug('Insert_Details: ' || 'Time Phased ATP = ' || l_time_phased_atp);
5392: END IF;
5393: /* time_phased_atp changes end*/
5394:

Line 5391: msc_sch_wb.atp_debug('Insert_Details: ' || 'Time Phased ATP = ' || l_time_phased_atp);

5387: IF PG_DEBUG in ('Y', 'C') THEN
5388: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_request_item_id := ' || p_request_item_id);
5389: msc_sch_wb.atp_debug('Insert_Details: ' || 'p_inventory_item_id := ' || p_inventory_item_id);
5390: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_request_item_id := ' || l_request_item_id);
5391: msc_sch_wb.atp_debug('Insert_Details: ' || 'Time Phased ATP = ' || l_time_phased_atp);
5392: END IF;
5393: /* time_phased_atp changes end*/
5394:
5395: --diag_atp

Line 5420: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);

5416: l_org_code := MSC_ATP_PVT.G_ORG_INFO_REC.org_code;
5417: /*Modularize Item and Org Info */
5418:
5419: IF PG_DEBUG in ('Y', 'C') THEN
5420: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5421: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_code='||l_calendar_code);
5422: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5423: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_demand_class'|| l_default_demand_class);
5424: END IF;

Line 5421: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_code='||l_calendar_code);

5417: /*Modularize Item and Org Info */
5418:
5419: IF PG_DEBUG in ('Y', 'C') THEN
5420: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5421: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_code='||l_calendar_code);
5422: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5423: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_demand_class'|| l_default_demand_class);
5424: END IF;
5425:

Line 5422: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);

5418:
5419: IF PG_DEBUG in ('Y', 'C') THEN
5420: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5421: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_code='||l_calendar_code);
5422: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5423: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_demand_class'|| l_default_demand_class);
5424: END IF;
5425:
5426: --Bug 2287148

Line 5423: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_demand_class'|| l_default_demand_class);

5419: IF PG_DEBUG in ('Y', 'C') THEN
5420: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_atp_rule_id='|| l_default_atp_rule_id);
5421: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_code='||l_calendar_code);
5422: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_calendar_exception_set_id'|| l_calendar_exception_set_id);
5423: msc_sch_wb.atp_debug('Insert_Details: ' || 'l_default_demand_class'|| l_default_demand_class);
5424: END IF;
5425:
5426: --Bug 2287148
5427: BEGIN

Line 5442: msc_sch_wb.atp_debug('Insert_Details: ' || 'System Next Date is : '|| l_sys_next_date);

5438: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
5439:
5440: END;
5441: IF PG_DEBUG in ('Y', 'C') THEN
5442: msc_sch_wb.atp_debug('Insert_Details: ' || 'System Next Date is : '|| l_sys_next_date);
5443: msc_sch_wb.atp_debug('Insert_Details: ' || 'Sequence Number Is :'|| l_sysdate_seq_num);
5444: msc_sch_wb.atp_debug('Insert_Details: ' || 'before select');
5445: END IF;
5446:

Line 5443: msc_sch_wb.atp_debug('Insert_Details: ' || 'Sequence Number Is :'|| l_sysdate_seq_num);

5439:
5440: END;
5441: IF PG_DEBUG in ('Y', 'C') THEN
5442: msc_sch_wb.atp_debug('Insert_Details: ' || 'System Next Date is : '|| l_sys_next_date);
5443: msc_sch_wb.atp_debug('Insert_Details: ' || 'Sequence Number Is :'|| l_sysdate_seq_num);
5444: msc_sch_wb.atp_debug('Insert_Details: ' || 'before select');
5445: END IF;
5446:
5447: MSC_ATP_DB_UTILS.Clear_SD_Details_temp();

Line 5444: msc_sch_wb.atp_debug('Insert_Details: ' || 'before select');

5440: END;
5441: IF PG_DEBUG in ('Y', 'C') THEN
5442: msc_sch_wb.atp_debug('Insert_Details: ' || 'System Next Date is : '|| l_sys_next_date);
5443: msc_sch_wb.atp_debug('Insert_Details: ' || 'Sequence Number Is :'|| l_sysdate_seq_num);
5444: msc_sch_wb.atp_debug('Insert_Details: ' || 'before select');
5445: END IF;
5446:
5447: MSC_ATP_DB_UTILS.Clear_SD_Details_temp();
5448:

Line 5494: msc_sch_wb.atp_debug('Insert_Details: ' || 'Error occured in procedure Get_Mat_Avail_Pf_Dtls');

5490: l_return_status
5491: );
5492: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
5493: IF PG_DEBUG in ('Y', 'C') THEN
5494: msc_sch_wb.atp_debug('Insert_Details: ' || 'Error occured in procedure Get_Mat_Avail_Pf_Dtls');
5495: END IF;
5496: RAISE FND_API.G_EXC_ERROR;
5497: END IF;
5498: END IF;

Line 5501: msc_sch_wb.atp_debug('Insert_Details: ' || 'after inserting into msc_atp_sd_details_temp');

5497: END IF;
5498: END IF;
5499:
5500: IF PG_DEBUG in ('Y', 'C') THEN
5501: msc_sch_wb.atp_debug('Insert_Details: ' || 'after inserting into msc_atp_sd_details_temp');
5502: msc_sch_wb.atp_debug('Insert_Details: ' || 'Total Supply/Demand Recs : '|| SQL%ROWCOUNT);
5503: END IF;
5504:
5505: -- time_phased_atp

Line 5502: msc_sch_wb.atp_debug('Insert_Details: ' || 'Total Supply/Demand Recs : '|| SQL%ROWCOUNT);

5498: END IF;
5499:
5500: IF PG_DEBUG in ('Y', 'C') THEN
5501: msc_sch_wb.atp_debug('Insert_Details: ' || 'after inserting into msc_atp_sd_details_temp');
5502: msc_sch_wb.atp_debug('Insert_Details: ' || 'Total Supply/Demand Recs : '|| SQL%ROWCOUNT);
5503: END IF;
5504:
5505: -- time_phased_atp
5506: IF l_time_phased_atp = 'Y' THEN

Line 5510: msc_sch_wb.atp_debug('Insert_Details: ' || 'Error occured in procedure Get_Period_Data_From_Sd_Temp');

5506: IF l_time_phased_atp = 'Y' THEN
5507: MSC_ATP_PF.get_period_data_from_SD_temp(x_atp_period, l_return_status);
5508: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
5509: IF PG_DEBUG in ('Y', 'C') THEN
5510: msc_sch_wb.atp_debug('Insert_Details: ' || 'Error occured in procedure Get_Period_Data_From_Sd_Temp');
5511: END IF;
5512: RAISE FND_API.G_EXC_ERROR;
5513: END IF;
5514: ELSE

Line 5521: msc_sch_wb.atp_debug('Insert_Details: ' || 'before atp_consume');

5517:
5518: x_atp_period.Cumulative_Quantity := x_atp_period.Period_Quantity;
5519:
5520: IF PG_DEBUG in ('Y', 'C') THEN
5521: msc_sch_wb.atp_debug('Insert_Details: ' || 'before atp_consume');
5522: END IF;
5523:
5524: -- time_phased_atp changes begin
5525: Print_Dates_Qtys(x_atp_period.Period_Start_Date, x_atp_period.Cumulative_Quantity);

Line 5536: msc_sch_wb.atp_debug('Insert_Details: ' || 'Error occured in procedure pf_atp_consume');

5532: MSC_ATP_PF.Bw_Fw_Cum, --b/w, f/w consumption and accumulation
5533: p_atf_date);
5534: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
5535: IF PG_DEBUG in ('Y', 'C') THEN
5536: msc_sch_wb.atp_debug('Insert_Details: ' || 'Error occured in procedure pf_atp_consume');
5537: END IF;
5538: RAISE FND_API.G_EXC_ERROR;
5539: END IF;
5540: -- time_phased_atp changes end

Line 5547: msc_sch_wb.atp_debug('Insert_Details: ' || 'after atp_consume');

5543: x_atp_period.Cumulative_Quantity.COUNT);
5544: END IF;
5545:
5546: IF PG_DEBUG in ('Y', 'C') THEN
5547: msc_sch_wb.atp_debug('Insert_Details: ' || 'after atp_consume');
5548: END IF;
5549:
5550: /* Cum drop issue changes begin*/
5551: MSC_AATP_PROC.Atp_Remove_Negatives(x_atp_period.Cumulative_Quantity, l_return_status);

Line 5554: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');

5550: /* Cum drop issue changes begin*/
5551: MSC_AATP_PROC.Atp_Remove_Negatives(x_atp_period.Cumulative_Quantity, l_return_status);
5552: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
5553: IF PG_DEBUG in ('Y', 'C') THEN
5554: msc_sch_wb.atp_debug('Get_Material_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');
5555: END IF;
5556: RAISE FND_API.G_EXC_ERROR;
5557: END IF;
5558: /* Cum drop issue changes end*/

Line 5578: msc_sch_wb.atp_debug('***** End Insert_Details Procedure *****');

5574:
5575: END IF;
5576:
5577: IF PG_DEBUG in ('Y', 'C') THEN
5578: msc_sch_wb.atp_debug('***** End Insert_Details Procedure *****');
5579: END IF;
5580:
5581: END Insert_Details;
5582:

Line 5732: msc_sch_wb.atp_debug('***** Begin Get_Res_Requirements Procedure *****');

5728: l_touch_time NUMBER; --5093604
5729:
5730: BEGIN
5731: IF PG_DEBUG in ('Y', 'C') THEN
5732: msc_sch_wb.atp_debug('***** Begin Get_Res_Requirements Procedure *****');
5733: END IF;
5734: -- initialize API return status to success
5735: x_return_status := FND_API.G_RET_STS_SUCCESS;
5736: l_uom_code := NVL(fnd_profile.value('MSC:HOUR_UOM_CODE'),

Line 5740: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'mso batchable flag := ' || l_MSO_Batch_flag );

5736: l_uom_code := NVL(fnd_profile.value('MSC:HOUR_UOM_CODE'),
5737: fnd_profile.value('BOM:HOUR_UOM_CODE'));
5738: l_MSO_Batch_flag := NVL(fnd_profile.value('MSO_BATCHABLE_FLAG'),'N');
5739: IF PG_DEBUG in ('Y', 'C') THEN
5740: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'mso batchable flag := ' || l_MSO_Batch_flag );
5741: END IF;
5742:
5743: -- 3027711
5744: -- for performance reason, we need to get the following info and

Line 5836: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_bor = '||l_use_bor);

5832: l_constraint_plan := 0;
5833: END;
5834:
5835: IF PG_DEBUG in ('Y', 'C') THEN
5836: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_bor = '||l_use_bor);
5837: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_OPTIMIZED_PLAN = '||MSC_ATP_PVT.G_OPTIMIZED_PLAN);
5838: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_constaint_plan =' || l_constraint_plan);
5839: END IF;
5840: IF (l_MSO_Batch_Flag = 'Y') and (l_use_bor = 0) and (l_constraint_plan = 1) THEN

Line 5837: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_OPTIMIZED_PLAN = '||MSC_ATP_PVT.G_OPTIMIZED_PLAN);

5833: END;
5834:
5835: IF PG_DEBUG in ('Y', 'C') THEN
5836: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_bor = '||l_use_bor);
5837: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_OPTIMIZED_PLAN = '||MSC_ATP_PVT.G_OPTIMIZED_PLAN);
5838: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_constaint_plan =' || l_constraint_plan);
5839: END IF;
5840: IF (l_MSO_Batch_Flag = 'Y') and (l_use_bor = 0) and (l_constraint_plan = 1) THEN
5841: IF PG_DEBUG in ('Y', 'C') THEN

Line 5838: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_constaint_plan =' || l_constraint_plan);

5834:
5835: IF PG_DEBUG in ('Y', 'C') THEN
5836: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_bor = '||l_use_bor);
5837: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_OPTIMIZED_PLAN = '||MSC_ATP_PVT.G_OPTIMIZED_PLAN);
5838: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_constaint_plan =' || l_constraint_plan);
5839: END IF;
5840: IF (l_MSO_Batch_Flag = 'Y') and (l_use_bor = 0) and (l_constraint_plan = 1) THEN
5841: IF PG_DEBUG in ('Y', 'C') THEN
5842: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Do Batching');

Line 5842: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Do Batching');

5838: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_constaint_plan =' || l_constraint_plan);
5839: END IF;
5840: IF (l_MSO_Batch_Flag = 'Y') and (l_use_bor = 0) and (l_constraint_plan = 1) THEN
5841: IF PG_DEBUG in ('Y', 'C') THEN
5842: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Do Batching');
5843: END IF;
5844: l_use_batching := 1;
5845: ELSE
5846: IF PG_DEBUG in ('Y', 'C') THEN

Line 5847: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'No Batching');

5843: END IF;
5844: l_use_batching := 1;
5845: ELSE
5846: IF PG_DEBUG in ('Y', 'C') THEN
5847: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'No Batching');
5848: END IF;
5849: l_use_batching := 0;
5850: END IF;
5851: IF PG_DEBUG in ('Y', 'C') THEN

Line 5852: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching =' || l_use_batching);

5848: END IF;
5849: l_use_batching := 0;
5850: END IF;
5851: IF PG_DEBUG in ('Y', 'C') THEN
5852: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching =' || l_use_batching);
5853: END IF;
5854:
5855: -- Check if full summary has been run - for summary enhancement
5856: IF MSC_ATP_PVT.G_SUMMARY_FLAG = 'Y' AND

Line 5869: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_uom_code = ' || l_uom_code);

5865:
5866: l_null_atp_period := x_atp_period;
5867: l_null_atp_supply_demand := x_atp_supply_demand;
5868: IF PG_DEBUG in ('Y', 'C') THEN
5869: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_uom_code = ' || l_uom_code);
5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);
5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);

Line 5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);

5866: l_null_atp_period := x_atp_period;
5867: l_null_atp_supply_demand := x_atp_supply_demand;
5868: IF PG_DEBUG in ('Y', 'C') THEN
5869: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_uom_code = ' || l_uom_code);
5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);
5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);

Line 5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);

5867: l_null_atp_supply_demand := x_atp_supply_demand;
5868: IF PG_DEBUG in ('Y', 'C') THEN
5869: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_uom_code = ' || l_uom_code);
5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);
5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);

Line 5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);

5868: IF PG_DEBUG in ('Y', 'C') THEN
5869: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_uom_code = ' || l_uom_code);
5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);
5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);

Line 5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);

5869: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_uom_code = ' || l_uom_code);
5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);
5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);

Line 5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);

5870: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_insert_flag = '||p_insert_flag);
5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);

Line 5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);

5871: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_instance_id = '||p_instance_id);
5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);

Line 5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);

5872: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_plan_id = '||p_plan_id);
5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);

Line 5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);

5873: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_level = '||p_level);
5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);

Line 5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);

5874: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter

Line 5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);

5875: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);

Line 5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);

5876: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_organization_id = '||p_organization_id);
5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);
5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);

Line 5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);

5877: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
5878: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);
5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);
5885: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_line_identifier = '|| p_line_identifier);

Line 5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);

5879: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_requested_date = '||p_requested_date);
5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);
5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);
5885: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_line_identifier = '|| p_line_identifier);
5886: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
5887: 'MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type= '||

Line 5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);

5880: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_refresh_number = '||p_refresh_number);
5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);
5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);
5885: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_line_identifier = '|| p_line_identifier);
5886: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
5887: 'MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type= '||
5888: MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type);

Line 5885: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_line_identifier = '|| p_line_identifier);

5881: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_search = '||p_search);
5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);
5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);
5885: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_line_identifier = '|| p_line_identifier);
5886: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
5887: 'MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type= '||
5888: MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type);
5889: --bug3601223

Line 5886: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||

5882: -- Then add the latest parameter
5883: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_bill_seq_id = '|| p_bill_seq_id);
5884: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_parent_ship_date = '|| p_parent_ship_date);
5885: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'p_line_identifier = '|| p_line_identifier);
5886: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
5887: 'MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type= '||
5888: MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type);
5889: --bug3601223
5890: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);

Line 5890: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);

5886: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
5887: 'MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type= '||
5888: MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type);
5889: --bug3601223
5890: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);
5891: -- End Bug 2814872
5892: END IF;
5893: --- get msc_lead_time factor
5894: l_mso_lead_time_factor := MSC_ATP_PVT.G_MSO_LEAD_TIME_FACTOR;

Line 5911: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_fixed_lt = '

5907: --l_item_wt_uom := MSC_ATP_PVT.G_ITEM_INFO_REC.unit_weight;
5908: l_item_vol_uom := MSC_ATP_PVT.G_ITEM_INFO_REC.volume_uom;
5909: l_item_wt_uom := MSC_ATP_PVT.G_ITEM_INFO_REC.weight_uom;
5910: IF PG_DEBUG in ('Y', 'C') THEN
5911: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_fixed_lt = '
5912: || l_item_fixed_lt);
5913: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_var_lt = '
5914: || l_item_var_lt);
5915: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_vol = '

Line 5913: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_var_lt = '

5909: l_item_wt_uom := MSC_ATP_PVT.G_ITEM_INFO_REC.weight_uom;
5910: IF PG_DEBUG in ('Y', 'C') THEN
5911: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_fixed_lt = '
5912: || l_item_fixed_lt);
5913: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_var_lt = '
5914: || l_item_var_lt);
5915: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_vol = '
5916: ||l_item_unit_vol);
5917: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_wt = '

Line 5915: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_vol = '

5911: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_fixed_lt = '
5912: || l_item_fixed_lt);
5913: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_var_lt = '
5914: || l_item_var_lt);
5915: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_vol = '
5916: ||l_item_unit_vol);
5917: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_wt = '
5918: ||l_item_unit_wt);
5919: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_wt_uom = '

Line 5917: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_wt = '

5913: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_var_lt = '
5914: || l_item_var_lt);
5915: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_vol = '
5916: ||l_item_unit_vol);
5917: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_wt = '
5918: ||l_item_unit_wt);
5919: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_wt_uom = '
5920: ||l_item_wt_uom);
5921: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_vol_uom = '

Line 5919: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_wt_uom = '

5915: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_vol = '
5916: ||l_item_unit_vol);
5917: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_wt = '
5918: ||l_item_unit_wt);
5919: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_wt_uom = '
5920: ||l_item_wt_uom);
5921: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_vol_uom = '
5922: ||l_item_vol_uom);
5923: END IF;

Line 5921: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_vol_uom = '

5917: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_unit_wt = '
5918: ||l_item_unit_wt);
5919: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_wt_uom = '
5920: ||l_item_wt_uom);
5921: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_vol_uom = '
5922: ||l_item_vol_uom);
5923: END IF;
5924: -- End Bug 3432530
5925: IF MSC_ATP_PVT.G_ITEM_INFO_REC.bom_item_type in (1, 2) THEN

Line 5959: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_parent_line_id= '|| l_parent_line_id);

5955: ELSE
5956: l_routing_seq_id := p_routing_seq_id;
5957: END IF;
5958: IF PG_DEBUG in ('Y', 'C') THEN
5959: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_parent_line_id= '|| l_parent_line_id);
5960: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_inventory_item_id= '|| l_inventory_item_id);
5961: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_routing_sequence_id= '|| l_routing_seq_id);
5962: END IF;
5963: -- End CTO Option Dependent Resources ODR

Line 5960: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_inventory_item_id= '|| l_inventory_item_id);

5956: l_routing_seq_id := p_routing_seq_id;
5957: END IF;
5958: IF PG_DEBUG in ('Y', 'C') THEN
5959: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_parent_line_id= '|| l_parent_line_id);
5960: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_inventory_item_id= '|| l_inventory_item_id);
5961: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_routing_sequence_id= '|| l_routing_seq_id);
5962: END IF;
5963: -- End CTO Option Dependent Resources ODR
5964: -- 3027711 moved getting item/org info to beginning

Line 5961: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_routing_sequence_id= '|| l_routing_seq_id);

5957: END IF;
5958: IF PG_DEBUG in ('Y', 'C') THEN
5959: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_parent_line_id= '|| l_parent_line_id);
5960: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_inventory_item_id= '|| l_inventory_item_id);
5961: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_routing_sequence_id= '|| l_routing_seq_id);
5962: END IF;
5963: -- End CTO Option Dependent Resources ODR
5964: -- 3027711 moved getting item/org info to beginning
5965:

Line 5968: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'not using BOR');

5964: -- 3027711 moved getting item/org info to beginning
5965:
5966: IF (l_use_bor <> 1) THEN
5967: IF PG_DEBUG in ('Y', 'C') THEN
5968: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'not using BOR');
5969: END IF;
5970: -- get resource requirements
5971: -- OSFM changes
5972: l_inventory_item_id := MSC_ATP_PVT.G_ITEM_INFO_REC.dest_inv_item_id;

Line 5994: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'cfm_routing_flag= '|| l_routing_type);

5990: END;
5991:
5992:
5993: IF PG_DEBUG in ('Y', 'C') THEN
5994: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'cfm_routing_flag= '|| l_routing_type);
5995: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'routing sequence id = ' || l_routing_number);
5996: END IF;
5997: IF l_routing_type = 3 THEN --- network routing
5998:

Line 5995: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'routing sequence id = ' || l_routing_number);

5991:
5992:
5993: IF PG_DEBUG in ('Y', 'C') THEN
5994: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'cfm_routing_flag= '|| l_routing_type);
5995: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'routing sequence id = ' || l_routing_number);
5996: END IF;
5997: IF l_routing_type = 3 THEN --- network routing
5998:
5999: -- CTO Option Dependent Resources

Line 7375: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'using BOR');

7371: END IF; ---- If l_routing_flag = 3 THEN
7372: ELSE
7373:
7374: IF PG_DEBUG in ('Y', 'C') THEN
7375: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'using BOR');
7376: END IF;
7377:
7378: -- Added on 01/09/2001 by ngoel for performance improvement
7379: /* Modularize Item and Org Info */

Line 7383: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Modular change l_inv_item_id : '||l_inv_item_id);

7379: /* Modularize Item and Org Info */
7380: l_inv_item_id := MSC_ATP_PVT.G_ITEM_INFO_REC.dest_inv_item_id;
7381: /* Modularize Item and Org Info */
7382: IF PG_DEBUG in ('Y', 'C') THEN
7383: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Modular change l_inv_item_id : '||l_inv_item_id);
7384: END IF;
7385:
7386: SELECT b.department_id,
7387: dr.owning_department_id,

Line 7485: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'After getting resource information');

7481:
7482:
7483: END IF;
7484: IF PG_DEBUG in ('Y', 'C') THEN
7485: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'After getting resource information');
7486: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
7487: 'l_res_requirements.resource_id.COUNT ' || l_res_requirements.resource_id.COUNT);
7488: END IF;
7489: -- go over each resource

Line 7486: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||

7482:
7483: END IF;
7484: IF PG_DEBUG in ('Y', 'C') THEN
7485: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'After getting resource information');
7486: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
7487: 'l_res_requirements.resource_id.COUNT ' || l_res_requirements.resource_id.COUNT);
7488: END IF;
7489: -- go over each resource
7490: j := l_res_requirements.resource_id.FIRST;

Line 7506: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date := ' || x_atp_date);

7502:
7503: -- Initialize l_infinite_time_fence_date, since this is pds,
7504: -- use planning's cutoff date as the infinite time fence date
7505: IF PG_DEBUG in ('Y', 'C') THEN
7506: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date := ' || x_atp_date);
7507: END IF;
7508: IF j IS NOT NULL THEN
7509: ---bug 2341075: read plan start date
7510:

Line 7523: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Start Date := ' || l_plan_start_date );

7519: l_plan_start_date := MSC_ATP_PVT.G_PLAN_INFO_REC.plan_start_date;
7520: --l_infinite_time_fence_date := MSC_ATP_PVT.G_PLAN_INFO_REC.curr_cutoff_date; (ssurendr) Bug 2865389
7521: l_infinite_time_fence_date := MSC_ATP_PVT.G_PLAN_INFO_REC.plan_cutoff_date;
7522: IF PG_DEBUG in ('Y', 'C') THEN
7523: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Start Date := ' || l_plan_start_date );
7524: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Infinite Time Fence := ' ||
7525: l_infinite_time_fence_date );
7526: END IF;
7527: -- End Supplier Capacity and Lead Time Proj

Line 7524: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Infinite Time Fence := ' ||

7520: --l_infinite_time_fence_date := MSC_ATP_PVT.G_PLAN_INFO_REC.curr_cutoff_date; (ssurendr) Bug 2865389
7521: l_infinite_time_fence_date := MSC_ATP_PVT.G_PLAN_INFO_REC.plan_cutoff_date;
7522: IF PG_DEBUG in ('Y', 'C') THEN
7523: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Start Date := ' || l_plan_start_date );
7524: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Infinite Time Fence := ' ||
7525: l_infinite_time_fence_date );
7526: END IF;
7527: -- End Supplier Capacity and Lead Time Proj
7528:

Line 7553: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_assembly_quantity := ' || l_assembly_quantity);

7549: l_assembly_quantity := 1;
7550: END;
7551: END IF;
7552: IF PG_DEBUG in ('Y', 'C') THEN
7553: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_assembly_quantity := ' || l_assembly_quantity);
7554: END IF;
7555:
7556:
7557: --// BUG 2313497, 2126520

Line 7589: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Id := ' ||

7585: l_resource_id,
7586: l_department_id );
7587:
7588: IF PG_DEBUG in ('Y', 'C') THEN
7589: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Id := ' ||
7590: l_resource_id);
7591: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Infinite Time Fence := '
7592: || l_infinite_time_fence_date );
7593: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Cutoff Date := ' ||

Line 7591: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Infinite Time Fence := '

7587:
7588: IF PG_DEBUG in ('Y', 'C') THEN
7589: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Id := ' ||
7590: l_resource_id);
7591: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Infinite Time Fence := '
7592: || l_infinite_time_fence_date );
7593: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Cutoff Date := ' ||
7594: MSC_ATP_PVT.G_PLAN_INFO_REC.plan_cutoff_date);
7595: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ATP RULE NAME for Resource := '

Line 7593: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Cutoff Date := ' ||

7589: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Id := ' ||
7590: l_resource_id);
7591: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Infinite Time Fence := '
7592: || l_infinite_time_fence_date );
7593: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Cutoff Date := ' ||
7594: MSC_ATP_PVT.G_PLAN_INFO_REC.plan_cutoff_date);
7595: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ATP RULE NAME for Resource := '
7596: || l_atp_rule_name );
7597: END IF;

Line 7595: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ATP RULE NAME for Resource := '

7591: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Infinite Time Fence := '
7592: || l_infinite_time_fence_date );
7593: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Plan Cutoff Date := ' ||
7594: MSC_ATP_PVT.G_PLAN_INFO_REC.plan_cutoff_date);
7595: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ATP RULE NAME for Resource := '
7596: || l_atp_rule_name );
7597: END IF;
7598: -- Bug 3036513
7599:

Line 7632: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Setting the Lead time 0 for forward case');

7628: l_requested_date := p_requested_date;
7629: l_lead_time := 0;
7630:
7631: IF PG_DEBUG in ('Y', 'C') THEN
7632: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Setting the Lead time 0 for forward case');
7633: END IF;
7634: ELSE
7635: -- Check the the start date of the next resource and
7636: -- Use it as End date of current resource by

Line 7644: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'h = ' || h);

7640: -- start date is less then current resource's start date.
7641: For h in j+1..res_count
7642: LOOP
7643: IF PG_DEBUG in ('Y', 'C') THEN
7644: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'h = ' || h);
7645: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'J' ||l_res_requirements.requested_date(j));
7646: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'H' ||l_res_requirements.requested_date(h));
7647: END IF;
7648: IF l_res_requirements.requested_date(j)

Line 7645: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'J' ||l_res_requirements.requested_date(j));

7641: For h in j+1..res_count
7642: LOOP
7643: IF PG_DEBUG in ('Y', 'C') THEN
7644: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'h = ' || h);
7645: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'J' ||l_res_requirements.requested_date(j));
7646: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'H' ||l_res_requirements.requested_date(h));
7647: END IF;
7648: IF l_res_requirements.requested_date(j)
7649: < l_res_requirements.requested_date(h) THEN

Line 7646: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'H' ||l_res_requirements.requested_date(h));

7642: LOOP
7643: IF PG_DEBUG in ('Y', 'C') THEN
7644: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'h = ' || h);
7645: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'J' ||l_res_requirements.requested_date(j));
7646: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'H' ||l_res_requirements.requested_date(h));
7647: END IF;
7648: IF l_res_requirements.requested_date(j)
7649: < l_res_requirements.requested_date(h) THEN
7650: -- Bug 3348095

Line 7654: msc_sch_wb.atp_debug('Get_Res_Requirements: Init. l_res_start_date ' ||

7650: -- Bug 3348095
7651: -- Assign the Resource start Date
7652: l_res_start_date := l_res_requirements.requested_date(j);
7653: IF PG_DEBUG in ('Y', 'C') THEN
7654: msc_sch_wb.atp_debug('Get_Res_Requirements: Init. l_res_start_date ' ||
7655: l_res_start_date);
7656: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || l_res_requirements.requested_date(h));
7657: END IF;
7658: -- Bug 3348095

Line 7656: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || l_res_requirements.requested_date(h));

7652: l_res_start_date := l_res_requirements.requested_date(j);
7653: IF PG_DEBUG in ('Y', 'C') THEN
7654: msc_sch_wb.atp_debug('Get_Res_Requirements: Init. l_res_start_date ' ||
7655: l_res_start_date);
7656: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || l_res_requirements.requested_date(h));
7657: END IF;
7658: -- Bug 3348095
7659: l_lead_time := l_res_requirements.lead_time(h);
7660: l_requested_date := l_res_requirements.requested_date(h);

Line 7662: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Next Date found..Exiting');

7658: -- Bug 3348095
7659: l_lead_time := l_res_requirements.lead_time(h);
7660: l_requested_date := l_res_requirements.requested_date(h);
7661: IF PG_DEBUG in ('Y', 'C') THEN
7662: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Next Date found..Exiting');
7663: END IF;
7664: EXIT;
7665: ELSIF h = res_count THEN
7666: l_requested_date := p_requested_date;

Line 7682: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Requested Date: ' ||l_res_requirements.requested_date(j));

7678:
7679: -- Bug 3494178, need to reset l_res_requirements.requested_date(j) same as l_requested_date
7680: l_res_requirements.requested_date(j) := l_requested_date;
7681:
7682: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Requested Date: ' ||l_res_requirements.requested_date(j));
7683:
7684: IF PG_DEBUG in ('Y', 'C') THEN
7685: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Lead time:' || l_lead_time);
7686: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date:'|| l_requested_date);

Line 7685: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Lead time:' || l_lead_time);

7681:
7682: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Requested Date: ' ||l_res_requirements.requested_date(j));
7683:
7684: IF PG_DEBUG in ('Y', 'C') THEN
7685: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Lead time:' || l_lead_time);
7686: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date:'|| l_requested_date);
7687: END IF;
7688:
7689: -- 1610561

Line 7686: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date:'|| l_requested_date);

7682: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New Requested Date: ' ||l_res_requirements.requested_date(j));
7683:
7684: IF PG_DEBUG in ('Y', 'C') THEN
7685: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Resource Lead time:' || l_lead_time);
7686: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date:'|| l_requested_date);
7687: END IF;
7688:
7689: -- 1610561
7690: -- l_resource_id := l_res_requirements.resource_id(j);

Line 7717: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'batch flag back to null');

7713: If (l_batchable_flag <> 1 ) OR (l_use_batching <> 1) THEN
7714: --- if item is not batchable or batching is not done then
7715: -- set the std_op_code back to null
7716: IF PG_DEBUG in ('Y', 'C') THEN
7717: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'batch flag back to null');
7718: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Dont do batching');
7719: END IF;
7720: l_batchable_flag := 2;
7721: --l_use_batching := 0;

Line 7718: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Dont do batching');

7714: --- if item is not batchable or batching is not done then
7715: -- set the std_op_code back to null
7716: IF PG_DEBUG in ('Y', 'C') THEN
7717: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'batch flag back to null');
7718: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Dont do batching');
7719: END IF;
7720: l_batchable_flag := 2;
7721: --l_use_batching := 0;
7722: END IF;

Line 7728: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'j := '||j);

7724: l_atp_period := l_null_atp_period;
7725: l_atp_supply_demand := l_null_atp_supply_demand;
7726:
7727: IF PG_DEBUG in ('Y', 'C') THEN
7728: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'j := '||j);
7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);
7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);

Line 7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);

7725: l_atp_supply_demand := l_null_atp_supply_demand;
7726:
7727: IF PG_DEBUG in ('Y', 'C') THEN
7728: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'j := '||j);
7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);
7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);

Line 7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);

7726:
7727: IF PG_DEBUG in ('Y', 'C') THEN
7728: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'j := '||j);
7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);
7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);

Line 7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);

7727: IF PG_DEBUG in ('Y', 'C') THEN
7728: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'j := '||j);
7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);
7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);

Line 7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);

7728: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'j := '||j);
7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);
7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);

Line 7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);

7729: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_id := '||l_resource_id);
7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);
7737: -- ODR

Line 7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);

7730: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_department_id := '||l_department_id);
7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);
7737: -- ODR
7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);

Line 7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);

7731: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date := '||l_requested_date);
7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);
7737: -- ODR
7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);
7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '

Line 7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);

7732: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_resource_usage := '||l_resource_usage);
7733: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type := '||l_basis_type);
7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);
7737: -- ODR
7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);
7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '
7740: ||l_res_requirements.resource_offset_percent(j));

Line 7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);

7734: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_efficiency := '||l_efficiency);
7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);
7737: -- ODR
7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);
7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '
7740: ||l_res_requirements.resource_offset_percent(j));
7741: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Lead Time := '
7742: ||l_res_requirements.lead_time(j));

Line 7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '

7735: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_utilization := '||l_utilization);
7736: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag := '||l_batchable_flag);
7737: -- ODR
7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);
7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '
7740: ||l_res_requirements.resource_offset_percent(j));
7741: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Lead Time := '
7742: ||l_res_requirements.lead_time(j));
7743: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Actual Resource_Usage := '

Line 7741: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Lead Time := '

7737: -- ODR
7738: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_op_seq_num := '||l_op_seq_num);
7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '
7740: ||l_res_requirements.resource_offset_percent(j));
7741: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Lead Time := '
7742: ||l_res_requirements.lead_time(j));
7743: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Actual Resource_Usage := '
7744: ||l_res_requirements.actual_resource_usage(j));
7745: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Reverse Cum Yield := '

Line 7743: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Actual Resource_Usage := '

7739: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Offset % := '
7740: ||l_res_requirements.resource_offset_percent(j));
7741: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Lead Time := '
7742: ||l_res_requirements.lead_time(j));
7743: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Actual Resource_Usage := '
7744: ||l_res_requirements.actual_resource_usage(j));
7745: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Reverse Cum Yield := '
7746: ||l_res_requirements.reverse_cumulative_yield(j));
7747: END IF;

Line 7745: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Reverse Cum Yield := '

7741: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Lead Time := '
7742: ||l_res_requirements.lead_time(j));
7743: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Actual Resource_Usage := '
7744: ||l_res_requirements.actual_resource_usage(j));
7745: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Reverse Cum Yield := '
7746: ||l_res_requirements.reverse_cumulative_yield(j));
7747: END IF;
7748: --- resource batching
7749: IF PG_DEBUG in ('Y', 'C') THEN

Line 7750: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_max_capacity = '|| l_max_capacity);

7746: ||l_res_requirements.reverse_cumulative_yield(j));
7747: END IF;
7748: --- resource batching
7749: IF PG_DEBUG in ('Y', 'C') THEN
7750: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_max_capacity = '|| l_max_capacity);
7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);
7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);
7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);
7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);

Line 7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);

7747: END IF;
7748: --- resource batching
7749: IF PG_DEBUG in ('Y', 'C') THEN
7750: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_max_capacity = '|| l_max_capacity);
7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);
7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);
7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);
7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);
7755: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_uom := '|| l_res_uom);

Line 7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);

7748: --- resource batching
7749: IF PG_DEBUG in ('Y', 'C') THEN
7750: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_max_capacity = '|| l_max_capacity);
7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);
7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);
7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);
7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);
7755: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_uom := '|| l_res_uom);
7756: END IF;

Line 7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);

7749: IF PG_DEBUG in ('Y', 'C') THEN
7750: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_max_capacity = '|| l_max_capacity);
7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);
7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);
7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);
7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);
7755: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_uom := '|| l_res_uom);
7756: END IF;
7757:

Line 7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);

7750: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_max_capacity = '|| l_max_capacity);
7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);
7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);
7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);
7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);
7755: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_uom := '|| l_res_uom);
7756: END IF;
7757:
7758: --- get conversion rate for resource

Line 7755: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_uom := '|| l_res_uom);

7751: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = '|| l_batchable_flag);
7752: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_unit_capacity = '||l_req_unit_capacity);
7753: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_req_capacity_uom = ' || l_req_capacity_uom);
7754: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'UOM type := ' || l_UOM_type);
7755: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_uom := '|| l_res_uom);
7756: END IF;
7757:
7758: --- get conversion rate for resource
7759: IF ((l_batchable_flag = 1) and (l_use_batching = 1)) THEN

Line 7788: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_conversion_rate := ' || l_item_conversion_rate);

7784: END;
7785:
7786: END IF;
7787: IF PG_DEBUG in ('Y', 'C') THEN
7788: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_conversion_rate := ' || l_item_conversion_rate);
7789: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_conversion_rate := ' || l_res_conversion_rate);
7790: END IF;
7791:
7792: --diag_atp

Line 7789: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_conversion_rate := ' || l_res_conversion_rate);

7785:
7786: END IF;
7787: IF PG_DEBUG in ('Y', 'C') THEN
7788: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_item_conversion_rate := ' || l_item_conversion_rate);
7789: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_conversion_rate := ' || l_res_conversion_rate);
7790: END IF;
7791:
7792: --diag_atp
7793: IF MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 1 and p_search = 1 THEN

Line 7797: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Batching quantity, diagnostic atp');

7793: IF MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 1 and p_search = 1 THEN
7794:
7795: IF ((l_batchable_flag = 1) and (l_use_batching = 1)) then
7796: IF PG_DEBUG in ('Y', 'C') THEN
7797: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Batching quantity, diagnostic atp');
7798: END IF;
7799: l_requested_res_qty := (l_resource_usage * l_req_unit_capacity * p_requested_quantity)
7800: * (l_item_conversion_rate )/(l_efficiency * l_utilization * l_assembly_quantity);
7801: ELSIF l_basis_type in (1,3) THEN --4694958

Line 7803: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 1,3 qty, diagnostic ATP'); --4694958

7799: l_requested_res_qty := (l_resource_usage * l_req_unit_capacity * p_requested_quantity)
7800: * (l_item_conversion_rate )/(l_efficiency * l_utilization * l_assembly_quantity);
7801: ELSIF l_basis_type in (1,3) THEN --4694958
7802: IF PG_DEBUG in ('Y', 'C') THEN
7803: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 1,3 qty, diagnostic ATP'); --4694958
7804: END IF;
7805: l_requested_res_qty := (l_resource_usage * p_requested_quantity)/
7806: (l_efficiency * l_utilization * l_assembly_quantity);
7807: ELSIF l_basis_type = 2 THEN

Line 7809: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 2 qty, diagnostic ATP');

7805: l_requested_res_qty := (l_resource_usage * p_requested_quantity)/
7806: (l_efficiency * l_utilization * l_assembly_quantity);
7807: ELSIF l_basis_type = 2 THEN
7808: IF PG_DEBUG in ('Y', 'C') THEN
7809: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 2 qty, diagnostic ATP');
7810: END IF;
7811: --bug 3766202: do not inflate the resource in case of pure lot base resource
7812: ---(no batching) as ATP doesn't consider batch size
7813: l_requested_res_qty := l_resource_usage/

Line 7821: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Batching quantity');

7817:
7818: ELSE
7819: IF ((l_batchable_flag = 1) and (l_use_batching = 1)) then
7820: IF PG_DEBUG in ('Y', 'C') THEN
7821: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Batching quantity');
7822: END IF;
7823: l_requested_res_qty := (l_resource_usage * l_req_unit_capacity * x_avail_assembly_qty)
7824: * (l_item_conversion_rate )/(l_efficiency * l_utilization * l_assembly_quantity);
7825: ELSIF l_basis_type in (1,3) THEN --4694958

Line 7827: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 1,3 qty'); --4694958

7823: l_requested_res_qty := (l_resource_usage * l_req_unit_capacity * x_avail_assembly_qty)
7824: * (l_item_conversion_rate )/(l_efficiency * l_utilization * l_assembly_quantity);
7825: ELSIF l_basis_type in (1,3) THEN --4694958
7826: IF PG_DEBUG in ('Y', 'C') THEN
7827: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 1,3 qty'); --4694958
7828: END IF;
7829: l_requested_res_qty := (l_resource_usage * x_avail_assembly_qty)/
7830: (l_efficiency * l_utilization * l_assembly_quantity);
7831: ELSIF l_basis_type = 2 THEN

Line 7833: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 2 qty');

7829: l_requested_res_qty := (l_resource_usage * x_avail_assembly_qty)/
7830: (l_efficiency * l_utilization * l_assembly_quantity);
7831: ELSIF l_basis_type = 2 THEN
7832: IF PG_DEBUG in ('Y', 'C') THEN
7833: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Basis type 2 qty');
7834: END IF;
7835: --bug 3766202: do not inflate the resource in case of pure lot base resource
7836: ---(no batching) as ATP doesn't consider batch size
7837: l_requested_res_qty := l_resource_usage/

Line 7844: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_res_qty := '||l_requested_res_qty);

7840: --diag_atp
7841: END IF; --IF MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 1 and p_search = 1 THEN
7842:
7843: IF PG_DEBUG in ('Y', 'C') THEN
7844: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_res_qty := '||l_requested_res_qty);
7845: END IF;
7846:
7847: -- we need to have a branch here for allocated atp
7848: -- Bug 2372577 . Check value of profile option : krajan

Line 7896: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'MSC_ATP_PVT.G_ATP_DEMAND_CLASS := ' || MSC_ATP_PVT.G_ATP_DEMAND_CLASS);

7892: ELSE -- of G_ALLOCATED_ATP
7893: -- we are using allocated atp
7894: -- Begin Bug 2424357
7895: IF PG_DEBUG in ('Y', 'C') THEN
7896: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'MSC_ATP_PVT.G_ATP_DEMAND_CLASS := ' || MSC_ATP_PVT.G_ATP_DEMAND_CLASS);
7897: END IF;
7898: l_demand_Class := MSC_AATP_FUNC.Get_Res_Hierarchy_demand_class(
7899: MSC_ATP_PVT.G_PARTNER_ID,
7900: MSC_ATP_PVT.G_PARTNER_SITE_ID,

Line 7912: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_demand_Class := '|| l_demand_Class);

7908:
7909: --diag_atp
7910: l_allocation_rule_name := MSC_ATP_PVT.G_ALLOCATION_RULE_NAME;
7911: IF PG_DEBUG in ('Y', 'C') THEN
7912: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_demand_Class := '|| l_demand_Class);
7913: END IF;
7914: -- End Bug 2424357
7915:
7916: MSC_AATP_PVT.Res_Alloc_Cum_Atp(p_plan_id,

Line 7944: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_period_tab.count='||l_atp_period_tab.COUNT);

7940:
7941: IF l_atp_period_tab.COUNT > 0 THEN
7942:
7943: IF PG_DEBUG in ('Y', 'C') THEN
7944: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_period_tab.count='||l_atp_period_tab.COUNT);
7945: FOR i in 1..l_atp_period_tab.COUNT LOOP
7946: msc_sch_wb.atp_debug('Date '||l_atp_period_tab(i)||' Qty '||
7947: l_atp_qty_tab(i));
7948: END LOOP;

Line 7946: msc_sch_wb.atp_debug('Date '||l_atp_period_tab(i)||' Qty '||

7942:
7943: IF PG_DEBUG in ('Y', 'C') THEN
7944: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_period_tab.count='||l_atp_period_tab.COUNT);
7945: FOR i in 1..l_atp_period_tab.COUNT LOOP
7946: msc_sch_wb.atp_debug('Date '||l_atp_period_tab(i)||' Qty '||
7947: l_atp_qty_tab(i));
7948: END LOOP;
7949: END IF;
7950: l_res_qty_before_ptf := 0;

Line 7952: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_PTF_DATE_THIS_LEVEL := ' || MSC_ATP_PVT.G_PTF_DATE_THIS_LEVEL);

7948: END LOOP;
7949: END IF;
7950: l_res_qty_before_ptf := 0;
7951: IF PG_DEBUG in ('Y', 'C') THEN
7952: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_PTF_DATE_THIS_LEVEL := ' || MSC_ATP_PVT.G_PTF_DATE_THIS_LEVEL);
7953: END IF;
7954: --bug 2341075: we should not consider any resources available before sysdate.Therefore,
7955: --- we get rid of all the resources availability before sysdate. Before this fix we use to ommit all
7956: --- the resources before pTF. Now we get rid off all resource availability prior to greatest of

Line 7984: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_qty_before_ptf := ' || l_res_qty_before_ptf);

7980: END IF;
7981: END LOOP;
7982: l_res_qty_before_ptf := GREATEST(l_res_qty_before_ptf, 0);
7983: IF PG_DEBUG in ('Y', 'C') THEN
7984: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_qty_before_ptf := ' || l_res_qty_before_ptf);
7985: -- Bug 4108546 Print the value of Index
7986: IF (l_res_ptf_indx IS NOT NULL) THEN
7987: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_ptf_indx := ' || l_res_ptf_indx);
7988: END IF;

Line 7987: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_ptf_indx := ' || l_res_ptf_indx);

7983: IF PG_DEBUG in ('Y', 'C') THEN
7984: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_qty_before_ptf := ' || l_res_qty_before_ptf);
7985: -- Bug 4108546 Print the value of Index
7986: IF (l_res_ptf_indx IS NOT NULL) THEN
7987: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_ptf_indx := ' || l_res_ptf_indx);
7988: END IF;
7989: -- End Bug 4108546
7990: END IF;
7991: IF p_search = 1 THEN -- backward

Line 8005: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);

8001:
8002: ELSE
8003: IF MSC_ATP_PVT.G_RES_CONSUME = 'Y' THEN
8004: IF PG_DEBUG in ('Y', 'C') THEN
8005: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);
8006: END IF;
8007: FOR k IN 1..l_atp_period_tab.COUNT LOOP
8008: IF k < l_atp_period_tab.LAST THEN
8009: l_next_period := l_atp_period_tab(k+1);

Line 8026: msc_sch_wb.atp_debug('Get_Res_Requirements: l_atp_period_tab(k) :' || l_atp_period_tab(k) );

8022: ELSE
8023: l_requested_date_quantity := GREATEST((l_atp_qty_tab(k) - l_res_qty_before_ptf), 0);
8024: END IF;
8025: IF PG_DEBUG in ('Y', 'C') THEN
8026: msc_sch_wb.atp_debug('Get_Res_Requirements: l_atp_period_tab(k) :' || l_atp_period_tab(k) );
8027: msc_sch_wb.atp_debug('Get_Res_Requirements: l_requested_date_quantity :' || l_requested_date_quantity );
8028: END IF;
8029: EXIT;
8030: END IF;

Line 8027: msc_sch_wb.atp_debug('Get_Res_Requirements: l_requested_date_quantity :' || l_requested_date_quantity );

8023: l_requested_date_quantity := GREATEST((l_atp_qty_tab(k) - l_res_qty_before_ptf), 0);
8024: END IF;
8025: IF PG_DEBUG in ('Y', 'C') THEN
8026: msc_sch_wb.atp_debug('Get_Res_Requirements: l_atp_period_tab(k) :' || l_atp_period_tab(k) );
8027: msc_sch_wb.atp_debug('Get_Res_Requirements: l_requested_date_quantity :' || l_requested_date_quantity );
8028: END IF;
8029: EXIT;
8030: END IF;
8031: END LOOP;

Line 8034: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);

8030: END IF;
8031: END LOOP;
8032: ELSE -- IF G_RES_CONSUME = 'N'
8033: IF PG_DEBUG in ('Y', 'C') THEN
8034: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);
8035: END IF;
8036: -- first we initialize the l_requested_date_quantity so that
8037: -- if we cannot find any date that match the requested date,
8038: -- the l_requested_date_quantity is set to 0.

Line 8053: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date_quantity ='||l_requested_date_quantity);

8049:
8050: END IF;
8051:
8052: IF PG_DEBUG in ('Y', 'C') THEN
8053: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date_quantity ='||l_requested_date_quantity);
8054: END IF;
8055:
8056: IF l_requested_date_quantity >= l_requested_res_qty THEN
8057: -- for this resource, we satisfy the resource requirement

Line 8069: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);

8065: --- resource batching: If req_dat_qty < req_qty then we set the avail_qty = 0
8066: IF l_basis_type = 2 OR MSC_ATP_PVT.G_RES_CONSUME = 'N'OR
8067: (l_batchable_flag = 1 AND l_use_batching = 1) THEN
8068: IF PG_DEBUG in ('Y', 'C') THEN
8069: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);
8070: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type = '||l_basis_type);
8071: END IF;
8072: -- this requirement is per lot, so we cannot have any
8073: -- final assembly made

Line 8070: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type = '||l_basis_type);

8066: IF l_basis_type = 2 OR MSC_ATP_PVT.G_RES_CONSUME = 'N'OR
8067: (l_batchable_flag = 1 AND l_use_batching = 1) THEN
8068: IF PG_DEBUG in ('Y', 'C') THEN
8069: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_RES_CONSUME = '||MSC_ATP_PVT.G_RES_CONSUME);
8070: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_basis_type = '||l_basis_type);
8071: END IF;
8072: -- this requirement is per lot, so we cannot have any
8073: -- final assembly made
8074: x_avail_assembly_qty :=0;

Line 8092: msc_sch_wb.atp_debug('avail_assembly_qty: ' ||

8088: l_resource_usage,6)); -- 5598066
8089:
8090: -- 2869830
8091: IF PG_DEBUG in ('Y', 'C') THEN
8092: msc_sch_wb.atp_debug('avail_assembly_qty: ' ||
8093: x_avail_assembly_qty);
8094: END IF;
8095: IF l_rounding_flag = 1 THEN
8096: x_avail_assembly_qty := FLOOR(x_avail_assembly_qty);

Line 8098: msc_sch_wb.atp_debug('rounded avail qty: ' ||

8094: END IF;
8095: IF l_rounding_flag = 1 THEN
8096: x_avail_assembly_qty := FLOOR(x_avail_assembly_qty);
8097: IF PG_DEBUG in ('Y', 'C') THEN
8098: msc_sch_wb.atp_debug('rounded avail qty: ' ||
8099: x_avail_assembly_qty);
8100: END IF;
8101: END IF;
8102:

Line 8118: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward, resource check');

8114: ELSE
8115: -- now this is forward. so what we want to know is the date
8116: -- when whole quantity is available.
8117: IF PG_DEBUG in ('Y', 'C') THEN
8118: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward, resource check');
8119: END IF;
8120:
8121: IF PG_DEBUG in ('Y', 'C') THEN
8122: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date = '||l_requested_date);

Line 8122: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date = '||l_requested_date);

8118: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward, resource check');
8119: END IF;
8120:
8121: IF PG_DEBUG in ('Y', 'C') THEN
8122: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_requested_date = '||l_requested_date);
8123: END IF;
8124:
8125: -- Bug 3450725, requested date must be at least PTF Date + Lead Time w/ offset % from start of job.
8126: -- Lets say, there are 3 resources R1, R2 and R3 with offset % as 0, 50% and 70% respectively,

Line 8148: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New l_requested_date = '||l_requested_date);

8144: ---2178544
8145: --l_requested_date := GREATEST(l_requested_date, MSC_ATP_PVT.G_PTF_DATE);
8146:
8147: IF PG_DEBUG in ('Y', 'C') THEN
8148: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'New l_requested_date = '||l_requested_date);
8149: END IF;
8150:
8151: FOR k IN 1..l_atp_period_tab.COUNT LOOP
8152:

Line 8161: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_period_tab('||k||')='||l_atp_period_tab(k));

8157: l_next_period := l_requested_date + 1;
8158: END IF;
8159:
8160: IF PG_DEBUG in ('Y', 'C') THEN
8161: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_period_tab('||k||')='||l_atp_period_tab(k));
8162: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_qty_tab('||k||')='||l_atp_qty_tab(k));
8163: END IF;
8164:
8165: IF (l_atp_qty_tab(k) -l_res_qty_before_ptf >= l_requested_res_qty) AND

Line 8162: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_qty_tab('||k||')='||l_atp_qty_tab(k));

8158: END IF;
8159:
8160: IF PG_DEBUG in ('Y', 'C') THEN
8161: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_period_tab('||k||')='||l_atp_period_tab(k));
8162: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_atp_qty_tab('||k||')='||l_atp_qty_tab(k));
8163: END IF;
8164:
8165: IF (l_atp_qty_tab(k) -l_res_qty_before_ptf >= l_requested_res_qty) AND
8166: --((l_atp_period_tab(k) >= trunc(sysdate) AND --4198893,4198445

Line 8174: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'inside the loop to find x_atp_date');

8170: (l_atp_period_tab(k) >= l_requested_date
8171: AND MSC_ATP_PVT.G_RES_CONSUME = 'N')) THEN
8172:
8173: IF PG_DEBUG in ('Y', 'C') THEN
8174: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'inside the loop to find x_atp_date');
8175: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);
8176: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||l_res_requirements.lead_time(j));
8177: END IF;
8178:

Line 8175: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);

8171: AND MSC_ATP_PVT.G_RES_CONSUME = 'N')) THEN
8172:
8173: IF PG_DEBUG in ('Y', 'C') THEN
8174: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'inside the loop to find x_atp_date');
8175: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);
8176: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||l_res_requirements.lead_time(j));
8177: END IF;
8178:
8179: -- we need to store this quantity and date somewhere

Line 8176: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||l_res_requirements.lead_time(j));

8172:
8173: IF PG_DEBUG in ('Y', 'C') THEN
8174: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'inside the loop to find x_atp_date');
8175: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);
8176: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||l_res_requirements.lead_time(j));
8177: END IF;
8178:
8179: -- we need to store this quantity and date somewhere
8180: -- so that we can use them to add to pegging tree

Line 8200: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_atp_date = '||l_res_atp_date);

8196: END IF;
8197: -- End BUG found during ODR/CTO-Rearch/ATP_Simplified Pegging.
8198:
8199: IF PG_DEBUG in ('Y', 'C') THEN
8200: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_atp_date = '||l_res_atp_date);
8201: END IF;
8202: --4198893,4198445 First calculate individual availability date. This date will be used to calculate
8203: --start date.
8204: IF nvl(l_lead_time, 0) > 0 THEN

Line 8229: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_lead_time = '||l_lead_time);

8225: l_res_availability_date := l_res_atp_date;
8226: END IF;
8227: x_atp_date := GREATEST(l_res_availability_date, x_atp_date);
8228: IF PG_DEBUG in ('Y', 'C') THEN
8229: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_lead_time = '||l_lead_time);
8230: END IF;
8231: --// BUG 2313497, 2126520
8232: IF PG_DEBUG in ('Y', 'C') THEN
8233: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||

Line 8233: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||

8229: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_lead_time = '||l_lead_time);
8230: END IF;
8231: --// BUG 2313497, 2126520
8232: IF PG_DEBUG in ('Y', 'C') THEN
8233: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||
8234: l_res_requirements.lead_time(j));
8235: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);
8236: END IF;
8237:

Line 8235: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);

8231: --// BUG 2313497, 2126520
8232: IF PG_DEBUG in ('Y', 'C') THEN
8233: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_res_requirements.lead_time(j) = '||
8234: l_res_requirements.lead_time(j));
8235: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_atp_date = '||x_atp_date);
8236: END IF;
8237:
8238: EXIT;
8239: ELSIF k = l_atp_period_tab.last THEN -- bug 1169539

Line 8241: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'end of l_atp_period_tab, setting x_atp_date to null');

8237:
8238: EXIT;
8239: ELSIF k = l_atp_period_tab.last THEN -- bug 1169539
8240: IF PG_DEBUG in ('Y', 'C') THEN
8241: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'end of l_atp_period_tab, setting x_atp_date to null');
8242: END IF;
8243: x_atp_date := null;
8244: END IF;
8245: END LOOP;

Line 8253: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'exiting from resource loop');

8249: -- exit this resource loop then.
8250: -- Bug 1608755, set available qty = 0 in this case.
8251: x_avail_assembly_qty :=0;
8252: IF PG_DEBUG in ('Y', 'C') THEN
8253: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'exiting from resource loop');
8254: END IF;
8255:
8256: EXIT;
8257: END IF;

Line 8262: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_avail_assembly_qty='||x_avail_assembly_qty);

8258:
8259: END IF; -- end if p_search
8260:
8261: IF PG_DEBUG in ('Y', 'C') THEN
8262: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'x_avail_assembly_qty='||x_avail_assembly_qty);
8263: END IF;
8264:
8265: ELSE -- else of 'if l_atp_period_tab.count > 0'
8266:

Line 8378: msc_sch_wb.atp_debug('Get_Res_Requirements: Calc. value-1 l_res_start_date ' ||

8374: -1 * l_res_requirements.lead_time(j)),
8375: l_requested_date);
8376:
8377: IF PG_DEBUG in ('Y', 'C') THEN
8378: msc_sch_wb.atp_debug('Get_Res_Requirements: Calc. value-1 l_res_start_date ' ||
8379: l_res_start_date);
8380: END IF;
8381: END IF;
8382: -- End Bug 3348095

Line 8393: msc_sch_wb.atp_debug('Get_Res_Requirements: l_res_requirements.requested_date(j) '||

8389: MSC_ATP_PVT.G_PTF_DATE_THIS_LEVEL)); --4135752
8390: -- End Bug 3562873.
8391:
8392: IF PG_DEBUG in ('Y', 'C') THEN
8393: msc_sch_wb.atp_debug('Get_Res_Requirements: l_res_requirements.requested_date(j) '||
8394: l_res_requirements.requested_date(j));
8395: msc_sch_wb.atp_debug('Get_Res_Requirements: Calc. value-2 l_res_start_date ' ||
8396: l_res_start_date);
8397: END IF;

Line 8395: msc_sch_wb.atp_debug('Get_Res_Requirements: Calc. value-2 l_res_start_date ' ||

8391:
8392: IF PG_DEBUG in ('Y', 'C') THEN
8393: msc_sch_wb.atp_debug('Get_Res_Requirements: l_res_requirements.requested_date(j) '||
8394: l_res_requirements.requested_date(j));
8395: msc_sch_wb.atp_debug('Get_Res_Requirements: Calc. value-2 l_res_start_date ' ||
8396: l_res_start_date);
8397: END IF;
8398: -- End Bug 3450725
8399:

Line 8422: msc_sch_wb.atp_debug('Out of the ADD RESOURCE DEMAND');

8418: p_refresh_number, -- For summary enhancement
8419: l_transaction_id,
8420: l_return_status);
8421:
8422: msc_sch_wb.atp_debug('Out of the ADD RESOURCE DEMAND');
8423: -- Bug 3348095
8424: -- End date of this resource will be the start date of next resource.
8425: -- Bug 3562873 Comment out this assignment, redundant, done above.
8426: -- l_res_start_date := l_requested_date;

Line 8429: msc_sch_wb.atp_debug('Get_Res_Requirements: Set l_res_start_date for next Res. ' ||

8425: -- Bug 3562873 Comment out this assignment, redundant, done above.
8426: -- l_res_start_date := l_requested_date;
8427: /*
8428: IF PG_DEBUG in ('Y', 'C') THEN
8429: msc_sch_wb.atp_debug('Get_Res_Requirements: Set l_res_start_date for next Res. ' ||
8430: l_res_start_date);
8431: END IF;
8432: */
8433: -- End Bug 3562873

Line 8504: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);

8500: l_pegging_rec.supplier_site_id := NULL;
8501: l_pegging_rec.supplier_site_name := NULL;
8502: --- resource batching
8503: IF PG_DEBUG in ('Y', 'C') THEN
8504: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8505: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8506: END IF;
8507: ---bug 1907419: set batchable_flag =1 for batchable resource
8508: --IF (l_use_batching = 1 and l_batchable_flag = 1) THEN

Line 8505: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);

8501: l_pegging_rec.supplier_site_name := NULL;
8502: --- resource batching
8503: IF PG_DEBUG in ('Y', 'C') THEN
8504: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8505: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8506: END IF;
8507: ---bug 1907419: set batchable_flag =1 for batchable resource
8508: --IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8509: -- add batch flag to pegging

Line 8511: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');

8507: ---bug 1907419: set batchable_flag =1 for batchable resource
8508: --IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8509: -- add batch flag to pegging
8510: IF PG_DEBUG in ('Y', 'C') THEN
8511: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');
8512: END IF;
8513: l_pegging_rec.batchable_flag := l_batchable_flag;
8514: --END IF;
8515:

Line 8521: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_ITEM_INFO_REC.base_item_id ' ||

8517: l_pegging_rec.pegging_type := MSC_ATP_PVT.RESOURCE_DEMAND; --resource demand node
8518:
8519: -- Bug 3348161
8520: IF PG_DEBUG in ('Y', 'C') THEN
8521: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_ITEM_INFO_REC.base_item_id ' ||
8522: MSC_ATP_PVT.G_ITEM_INFO_REC.base_item_id);
8523: END IF;
8524: ---s_cto_rearch and ODR
8525: l_pegging_rec.dest_inv_item_id := l_inventory_item_id;

Line 8531: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Set model_sd_flag');

8527: -- Handle Configuration Items as well.
8528: MSC_ATP_PVT.G_ITEM_INFO_REC.base_item_id is NOT NULL) THEN
8529: l_pegging_rec.model_sd_flag := 1;
8530: IF PG_DEBUG in ('Y', 'C') THEN
8531: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Set model_sd_flag');
8532: END IF;
8533: END IF;
8534: --e_cto_rearch and ODR
8535: -- End Bug 3348161

Line 8597: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);

8593: l_pegging_rec.supplier_site_id := NULL;
8594: l_pegging_rec.supplier_site_name := NULL;
8595: --- resource batching
8596: IF PG_DEBUG in ('Y', 'C') THEN
8597: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8598: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8599: END IF;
8600: --- bug 1907419
8601: ---IF (l_use_batching = 1 and l_batchable_flag = 1) THEN

Line 8598: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);

8594: l_pegging_rec.supplier_site_name := NULL;
8595: --- resource batching
8596: IF PG_DEBUG in ('Y', 'C') THEN
8597: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8598: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8599: END IF;
8600: --- bug 1907419
8601: ---IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8602: IF PG_DEBUG in ('Y', 'C') THEN

Line 8603: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');

8599: END IF;
8600: --- bug 1907419
8601: ---IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8602: IF PG_DEBUG in ('Y', 'C') THEN
8603: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');
8604: END IF;
8605: l_pegging_rec.batchable_flag := l_batchable_flag;
8606: --END IF;
8607:

Line 8716: msc_sch_wb.atp_debug('Get_Res_Requirements: Calculated val-1 l_res_start_date ' || l_res_start_date);

8712: --4198893,4198445: Calculate start date from individual resource's end date
8713: --l_res_atp_date);
8714:
8715: IF PG_DEBUG in ('Y', 'C') THEN
8716: msc_sch_wb.atp_debug('Get_Res_Requirements: Calculated val-1 l_res_start_date ' || l_res_start_date);
8717: END IF;
8718: -- Bug 3450725
8719: -- Ensure SYSDATE/PTF_DATE integrity while calculating start_date
8720: -- for resource_requirements

Line 8728: msc_sch_wb.atp_debug('Get_Res_Requirements: l_res_requirements.requested_date(j) ' ||

8724: MSC_ATP_PVT.G_PTF_DATE_THIS_LEVEL)); --4135752
8725: -- End Bug 3562873.
8726:
8727: IF PG_DEBUG in ('Y', 'C') THEN
8728: msc_sch_wb.atp_debug('Get_Res_Requirements: l_res_requirements.requested_date(j) ' ||
8729: l_res_requirements.requested_date(j));
8730: msc_sch_wb.atp_debug('Get_Res_Requirements: Calculated val-2 l_res_start_date ' || l_res_start_date);
8731: END IF;
8732: -- End Bug 3450725

Line 8730: msc_sch_wb.atp_debug('Get_Res_Requirements: Calculated val-2 l_res_start_date ' || l_res_start_date);

8726:
8727: IF PG_DEBUG in ('Y', 'C') THEN
8728: msc_sch_wb.atp_debug('Get_Res_Requirements: l_res_requirements.requested_date(j) ' ||
8729: l_res_requirements.requested_date(j));
8730: msc_sch_wb.atp_debug('Get_Res_Requirements: Calculated val-2 l_res_start_date ' || l_res_start_date);
8731: END IF;
8732: -- End Bug 3450725
8733: -- End Bug 3348095
8734:

Line 8797: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward piece, adding resource demand pegging');

8793: l_owning_department_code := l_department_code;
8794: END IF;
8795:
8796: IF PG_DEBUG in ('Y', 'C') THEN
8797: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward piece, adding resource demand pegging');
8798: END IF;
8799: l_pegging_rec.session_id:= MSC_ATP_PVT.G_SESSION_ID;
8800: l_pegging_rec.order_line_id:= MSC_ATP_PVT.G_ORDER_LINE_ID;
8801: l_pegging_rec.parent_pegging_id:= p_parent_pegging_id;

Line 8829: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);

8825: l_pegging_rec.supplier_site_name := NULL;
8826:
8827: --- resource batching
8828: IF PG_DEBUG in ('Y', 'C') THEN
8829: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8830: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8831: END IF;
8832: --- bug 1907419
8833: --IF (l_use_batching = 1 and l_batchable_flag = 1) THEN

Line 8830: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);

8826:
8827: --- resource batching
8828: IF PG_DEBUG in ('Y', 'C') THEN
8829: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8830: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8831: END IF;
8832: --- bug 1907419
8833: --IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8834: IF PG_DEBUG in ('Y', 'C') THEN

Line 8835: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');

8831: END IF;
8832: --- bug 1907419
8833: --IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8834: IF PG_DEBUG in ('Y', 'C') THEN
8835: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');
8836: END IF;
8837: l_pegging_rec.batchable_flag := l_batchable_flag;
8838: --END IF;
8839:

Line 8855: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_ITEM_INFO_REC.base_item_id ' ||

8851: l_pegging_rec.actual_supply_demand_date := TRUNC(l_res_atp_date) + MSC_ATP_PVT.G_END_OF_DAY;
8852:
8853: -- Bug 3348161
8854: IF PG_DEBUG in ('Y', 'C') THEN
8855: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'G_ITEM_INFO_REC.base_item_id ' ||
8856: MSC_ATP_PVT.G_ITEM_INFO_REC.base_item_id);
8857: END IF;
8858: ---s_cto_rearch and ODR,
8859: -- Bug 3348161 set model_sd_flag for future case.

Line 8866: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Set model_sd_flag');

8862: -- Handle Configuration Items as well.
8863: MSC_ATP_PVT.G_ITEM_INFO_REC.base_item_id is NOT NULL) THEN
8864: l_pegging_rec.model_sd_flag := 1;
8865: IF PG_DEBUG in ('Y', 'C') THEN
8866: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'Set model_sd_flag');
8867: END IF;
8868: END IF;
8869: --e_cto_rearch and ODR
8870: -- End Bug 3348161

Line 8896: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward piece, adding resource supply pegging');

8892: l_resource_code); */
8893:
8894: -- add pegging info for the supply
8895: IF PG_DEBUG in ('Y', 'C') THEN
8896: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'in forward piece, adding resource supply pegging');
8897: END IF;
8898:
8899:
8900: l_pegging_rec.session_id:= MSC_ATP_PVT.G_SESSION_ID;

Line 8928: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);

8924: l_pegging_rec.supplier_site_name := NULL;
8925:
8926: --- resource batching
8927: IF PG_DEBUG in ('Y', 'C') THEN
8928: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8929: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8930: END IF;
8931: --- bug 1907419
8932: ---IF (l_use_batching = 1 and l_batchable_flag = 1) THEN

Line 8929: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);

8925:
8926: --- resource batching
8927: IF PG_DEBUG in ('Y', 'C') THEN
8928: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_use_batching = ' || l_use_batching);
8929: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'l_batchable_flag = ' || l_batchable_flag);
8930: END IF;
8931: --- bug 1907419
8932: ---IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8933: IF PG_DEBUG in ('Y', 'C') THEN

Line 8934: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');

8930: END IF;
8931: --- bug 1907419
8932: ---IF (l_use_batching = 1 and l_batchable_flag = 1) THEN
8933: IF PG_DEBUG in ('Y', 'C') THEN
8934: msc_sch_wb.atp_debug('Get_Res_Requirements: ' || 'ADD batch flag to pegging');
8935: END IF;
8936: l_pegging_rec.batchable_flag := l_batchable_flag;
8937: ---END IF;
8938: --diag_atp

Line 8971: msc_sch_wb.atp_debug(' Add resource constraint in regular ATP');

8967: --s_cto_rearch
8968: IF l_res_atp_date > l_requested_date THEN
8969: IF PG_DEBUG in ('Y', 'C') THEN
8970:
8971: msc_sch_wb.atp_debug(' Add resource constraint in regular ATP');
8972: END IF;
8973: --l_pegging_rec.constraint_type := 7;
8974: l_pegging_rec.constraint_type := 6; --bug3533073
8975: END IF;

Line 8992: msc_sch_wb.atp_debug('in get_res_requirements we are here 1');

8988: END IF;
8989: END IF;
8990:
8991: IF PG_DEBUG in ('Y', 'C') THEN
8992: msc_sch_wb.atp_debug('in get_res_requirements we are here 1');
8993: END IF;
8994: FOR i in 1..l_atp_period.Level.COUNT LOOP
8995: l_atp_period.Pegging_Id(i) := l_pegging_id;
8996: l_atp_period.End_Pegging_Id(i) := MSC_ATP_PVT.G_DEMAND_PEGGING_ID;

Line 9001: msc_sch_wb.atp_debug('in get_res_requirements we are here 2');

8997:
8998: END LOOP;
8999:
9000: IF PG_DEBUG in ('Y', 'C') THEN
9001: msc_sch_wb.atp_debug('in get_res_requirements we are here 2');
9002: END IF;
9003:
9004: -- dsting supply/demand details pl/sql tables no longer used
9005: /*

Line 9018: msc_sch_wb.atp_debug('in get_res_requirements we are here 3');

9014: MSC_ATP_PVT.G_DEMAND_PEGGING_ID);
9015: END IF;
9016:
9017: IF PG_DEBUG in ('Y', 'C') THEN
9018: msc_sch_wb.atp_debug('in get_res_requirements we are here 3');
9019: END IF;
9020:
9021: -- Bug 4108546
9022: -- Re-set the Period Data for HP Display

Line 9034: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||

9030: l_atp_period.Cumulative_Quantity(k) :=
9031: l_atp_period.Cumulative_Quantity(k) - l_res_qty_before_ptf;
9032: END IF;
9033: IF PG_DEBUG in ('Y', 'C') THEN
9034: msc_sch_wb.atp_debug('Get_Res_Requirements: ' ||
9035: 'l_atp_period.Cumulative_Quantity(' || k || ') := ' ||
9036: l_atp_period.Cumulative_Quantity(k));
9037: END IF;
9038: END IF;

Line 9049: msc_sch_wb.atp_debug('in get_res_requirements we are here 4');

9045: x_atp_supply_demand,
9046: l_return_status);
9047:
9048: IF PG_DEBUG in ('Y', 'C') THEN
9049: msc_sch_wb.atp_debug('in get_res_requirements we are here 4');
9050: END IF;
9051:
9052: -- Bug 2814872
9053: IF (MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 2 AND p_search = 2 AND

Line 9059: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for parent item is better');

9055: -- No need to look at other resources in forward pass as for this resource
9056: -- the availability date is greater than or equal to the parent's ATP date.
9057: -- Note that when p_parent_ship_date is NULL all resources will get visited.
9058: IF PG_DEBUG in ('Y', 'C') THEN
9059: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for parent item is better');
9060: msc_sch_wb.atp_debug('Get_Res_Requirements date for parent item :' ||
9061: p_parent_ship_date);
9062: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for Resource :' ||
9063: l_resource_id || ' is ' || x_atp_date);

Line 9060: msc_sch_wb.atp_debug('Get_Res_Requirements date for parent item :' ||

9056: -- the availability date is greater than or equal to the parent's ATP date.
9057: -- Note that when p_parent_ship_date is NULL all resources will get visited.
9058: IF PG_DEBUG in ('Y', 'C') THEN
9059: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for parent item is better');
9060: msc_sch_wb.atp_debug('Get_Res_Requirements date for parent item :' ||
9061: p_parent_ship_date);
9062: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for Resource :' ||
9063: l_resource_id || ' is ' || x_atp_date);
9064: END IF;

Line 9062: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for Resource :' ||

9058: IF PG_DEBUG in ('Y', 'C') THEN
9059: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for parent item is better');
9060: msc_sch_wb.atp_debug('Get_Res_Requirements date for parent item :' ||
9061: p_parent_ship_date);
9062: msc_sch_wb.atp_debug('Get_Res_Requirements date obtained for Resource :' ||
9063: l_resource_id || ' is ' || x_atp_date);
9064: END IF;
9065: EXIT; -- Exit the loop
9066: ELSE -- diagnostic ATP or resource provides better date.

Line 9074: msc_sch_wb.atp_debug('***** End Get_Res_Requirements Procedure *****');

9070:
9071: END LOOP;
9072:
9073: IF PG_DEBUG in ('Y', 'C') THEN
9074: msc_sch_wb.atp_debug('***** End Get_Res_Requirements Procedure *****');
9075: END IF;
9076: Exception
9077: WHEN MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL THEN --bug3583705
9078: IF PG_DEBUG in ('Y', 'C') THEN

Line 9079: msc_sch_wb.atp_debug('Get_Res_Requirements ' || 'No match for sysdate in cal');

9075: END IF;
9076: Exception
9077: WHEN MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL THEN --bug3583705
9078: IF PG_DEBUG in ('Y', 'C') THEN
9079: msc_sch_wb.atp_debug('Get_Res_Requirements ' || 'No match for sysdate in cal');
9080: END IF;
9081: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
9082: WHEN OTHERS THEN
9083: x_return_status := FND_API.G_RET_STS_ERROR;

Line 9085: msc_sch_wb.atp_debug('Get_Res_Requirements ' || 'inside when others');

9081: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
9082: WHEN OTHERS THEN
9083: x_return_status := FND_API.G_RET_STS_ERROR;
9084: IF PG_DEBUG in ('Y', 'C') THEN --bug3583705
9085: msc_sch_wb.atp_debug('Get_Res_Requirements ' || 'inside when others');
9086: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
9087: END IF;
9088: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
9089: END Get_Res_Requirements;

Line 9086: msc_sch_wb.atp_debug ('error := ' || SQLERRM);

9082: WHEN OTHERS THEN
9083: x_return_status := FND_API.G_RET_STS_ERROR;
9084: IF PG_DEBUG in ('Y', 'C') THEN --bug3583705
9085: msc_sch_wb.atp_debug('Get_Res_Requirements ' || 'inside when others');
9086: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
9087: END IF;
9088: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
9089: END Get_Res_Requirements;
9090:

Line 9612: msc_sch_wb.atp_debug('***** Begin Get_Comp_Requirements *****');

9608: -- initialize API return status to success
9609: x_return_status := FND_API.G_RET_STS_SUCCESS;
9610:
9611: IF PG_DEBUG in ('Y', 'C') THEN
9612: msc_sch_wb.atp_debug('***** Begin Get_Comp_Requirements *****');
9613: END IF;
9614:
9615: -- Now get the material requirement
9616: IF PG_DEBUG in ('Y', 'C') THEN

Line 9617: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_instance_id = '||p_instance_id);

9613: END IF;
9614:
9615: -- Now get the material requirement
9616: IF PG_DEBUG in ('Y', 'C') THEN
9617: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_instance_id = '||p_instance_id);
9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);
9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);

Line 9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);

9614:
9615: -- Now get the material requirement
9616: IF PG_DEBUG in ('Y', 'C') THEN
9617: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_instance_id = '||p_instance_id);
9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);
9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);

Line 9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);

9615: -- Now get the material requirement
9616: IF PG_DEBUG in ('Y', 'C') THEN
9617: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_instance_id = '||p_instance_id);
9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);
9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);

Line 9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);

9616: IF PG_DEBUG in ('Y', 'C') THEN
9617: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_instance_id = '||p_instance_id);
9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);
9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);

Line 9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);

9617: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_instance_id = '||p_instance_id);
9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);
9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);

Line 9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);

9618: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_plan_id = '||p_plan_id);
9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);

Line 9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);

9619: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_level = '||p_level);
9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);

Line 9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);

9620: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_scenario_id = '||p_scenario_id);
9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);

Line 9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);

9621: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_inventory_item_id = '||p_inventory_item_id);
9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);

Line 9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);

9622: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_organization_id = '||p_organization_id);
9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);

Line 9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);

9623: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_parent_pegging_id = '||p_parent_pegging_id);
9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);

Line 9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);

9624: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_demand_class = '||p_demand_class);
9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);

Line 9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);

9625: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_quantity = '||p_requested_quantity);
9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);

Line 9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);

9626: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_requested_date = '||p_requested_date);
9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);

Line 9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);

9627: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '||p_search);
9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);

Line 9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);

9628: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_assign_set_id = '||p_assign_set_id);
9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);

Line 9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);

9629: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_order_number = '||p_order_number);
9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);

Line 9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);

9630: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_routing_seq_id = '||p_routing_seq_id);
9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);

Line 9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);

9631: msc_sch_wb.atp_debug('bom_item_type := ' || p_comp_info_rec.bom_item_type);
9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);

Line 9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);

9632: msc_sch_wb.atp_debug('atp flag := ' || p_comp_info_rec.atp_flag);
9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);

Line 9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);

9633: msc_sch_wb.atp_debug('atp_comp_flag := ' || p_comp_info_rec.atp_comp_flag);
9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);
9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);

Line 9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);

9634: msc_sch_wb.atp_debug('p_bill_seq_id := ' || p_bill_seq_id);
9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);
9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);
9642: --bug 3059305

Line 9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);

9635: msc_sch_wb.atp_debug('parent_so_quantity := ' || p_comp_info_rec.parent_so_quantity);
9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);
9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);
9642: --bug 3059305
9643: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ship date this level := '

Line 9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);

9636: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_family_id := ' || p_family_id);
9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);
9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);
9642: --bug 3059305
9643: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ship date this level := '
9644: || p_comp_info_rec.ship_date_this_level);

Line 9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);

9637: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_atf_date := ' || p_atf_date);
9638: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'TOP_MODEL_LINE_ID :=' || p_comp_info_rec.TOP_MODEL_LINE_ID);
9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);
9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);
9642: --bug 3059305
9643: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ship date this level := '
9644: || p_comp_info_rec.ship_date_this_level);
9645:

Line 9643: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ship date this level := '

9639: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_MODEL_LINE_ID :=' || p_comp_info_rec.ATO_MODEL_LINE_ID);
9640: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ATO_PARENT_MODEL_LINE_ID := ' || p_comp_info_rec.ATO_PARENT_MODEL_LINE_ID);
9641: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'PARENT_LINE_ID := ' || p_comp_info_rec.PARENT_LINE_ID);
9642: --bug 3059305
9643: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'ship date this level := '
9644: || p_comp_info_rec.ship_date_this_level);
9645:
9646:
9647: END IF;

Line 9751: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'MSO LEAD TIME FACTOR = ' || l_mso_lead_time_factor);

9747: l_mso_lead_time_factor := MSC_ATP_PVT.G_MSO_LEAD_TIME_FACTOR;
9748: l_network_scheduling_method := MSC_ATP_PVT.G_ORG_INFO_REC.network_scheduling_method; --bug3601223
9749:
9750: IF PG_DEBUG in ('Y', 'C') THEN
9751: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'MSO LEAD TIME FACTOR = ' || l_mso_lead_time_factor);
9752: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after assign the value');
9753: --bug3601223
9754: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);
9755: END IF;

Line 9752: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after assign the value');

9748: l_network_scheduling_method := MSC_ATP_PVT.G_ORG_INFO_REC.network_scheduling_method; --bug3601223
9749:
9750: IF PG_DEBUG in ('Y', 'C') THEN
9751: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'MSO LEAD TIME FACTOR = ' || l_mso_lead_time_factor);
9752: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after assign the value');
9753: --bug3601223
9754: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);
9755: END IF;
9756:

Line 9754: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);

9750: IF PG_DEBUG in ('Y', 'C') THEN
9751: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'MSO LEAD TIME FACTOR = ' || l_mso_lead_time_factor);
9752: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after assign the value');
9753: --bug3601223
9754: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_network_scheduling_method = '|| l_network_scheduling_method);
9755: END IF;
9756:
9757: i := l_explode_comp.inventory_item_id.FIRST;
9758: l_bill_seq_id := p_bill_seq_id; --(3004862) circular BOM issue

Line 9788: msc_sch_wb.atp_debug('This is a model line');

9784:
9785: --s_cto_rearch
9786: IF p_comp_info_rec.bom_item_type = 1 and p_comp_info_rec.replenish_to_order_flag = 'Y' THEN
9787: IF PG_DEBUG in ('Y', 'C') THEN
9788: msc_sch_wb.atp_debug('This is a model line');
9789: END IF;
9790: l_model_atp_comp_flag := p_comp_info_rec.atp_comp_flag;
9791: l_model_flag := p_comp_info_rec.bom_item_type;
9792:

Line 9795: msc_sch_wb.atp_debug('Add this line to comp requirements table');

9791: l_model_flag := p_comp_info_rec.bom_item_type;
9792:
9793: IF p_comp_info_rec.atp_flag = 'Y' THEN
9794: IF PG_DEBUG in ('Y', 'C') THEN
9795: msc_sch_wb.atp_debug('Add this line to comp requirements table');
9796: END IF;
9797: --first extend the record
9798: MSC_ATP_REQ.Extend_Atp_Comp_Typ(l_comp_requirements);
9799:

Line 9842: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_explode_comp.component_identifier(' || i || ') : ' || l_explode_comp.component_identifier(i));

9838: END IF;
9839:
9840: -- l_inv_item_id := MSC_ATP_PVT.G_ITEM_INFO_REC.dest_inv_item_id; -- Not required after 3004862 fix
9841: IF PG_DEBUG in ('Y', 'C') THEN
9842: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_explode_comp.component_identifier(' || i || ') : ' || l_explode_comp.component_identifier(i));
9843: END IF;
9844:
9845: -- Bug 4143668, reset routing type ti ensure correct data in between various iterations
9846: l_routing_type := NULL;

Line 9887: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_routing_type := ' || l_routing_type);

9883: AND r.sr_instance_id = p_instance_id
9884: AND r.routing_sequence_id = l_routing_seq_id; --4570421 replaced p_routing_seq_id by l_routing_seq_id
9885:
9886: IF PG_DEBUG in ('Y', 'C') THEN
9887: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_routing_type := ' || l_routing_type);
9888: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'routing l_first_op_seq_num := ' || l_first_op_seq_num);
9889: END IF;
9890:
9891: -- Bug 4143668, check lowest op seq from routing operation as routing level data is only populated for network routings

Line 9888: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'routing l_first_op_seq_num := ' || l_first_op_seq_num);

9884: AND r.routing_sequence_id = l_routing_seq_id; --4570421 replaced p_routing_seq_id by l_routing_seq_id
9885:
9886: IF PG_DEBUG in ('Y', 'C') THEN
9887: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_routing_type := ' || l_routing_type);
9888: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'routing l_first_op_seq_num := ' || l_first_op_seq_num);
9889: END IF;
9890:
9891: -- Bug 4143668, check lowest op seq from routing operation as routing level data is only populated for network routings
9892: /* Not needed as of now as RCY is not populated for non-network routing.

Line 9902: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'operations l_first_op_seq_num := ' || l_first_op_seq_num);

9898: AND op.sr_instance_id = p_instance_id
9899: AND op.plan_id = p_plan_id;
9900:
9901: IF PG_DEBUG in ('Y', 'C') THEN
9902: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'operations l_first_op_seq_num := ' || l_first_op_seq_num);
9903: END IF;
9904: END IF; -- IF l_first_op_seq_num IS NULL THEN
9905: */
9906:

Line 9919: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_first_op_RCY := ' || l_first_op_RCY);

9915: AND op.operation_seq_num = l_first_op_seq_num
9916: and op.operation_sequence_id = l_op_seq_id; --4570421
9917:
9918: IF PG_DEBUG in ('Y', 'C') THEN
9919: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_first_op_RCY := ' || l_first_op_RCY);
9920: END IF;
9921: ELSE
9922: l_first_op_RCY := 1; -- Bug 4143668, l_first_op_RCY to 1 if Null
9923: END IF; -- IF l_first_op_seq_num IS NOT NULL THEN

Line 9928: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'exception in cfm: '|| sqlcode);

9924: EXCEPTION
9925: WHEN OTHERS THEN
9926: -- Bug 4143668, add debug message for exception
9927: IF PG_DEBUG in ('Y', 'C') THEN
9928: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'exception in cfm: '|| sqlcode);
9929: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'set l_routing_type and l_first_op_RCY');
9930: END IF;
9931: l_routing_type := NVL(l_routing_type, 2); -- Bug 4143668, use l_routing_type if already set, else 2
9932: l_first_op_RCY := 1; -- Bug 4143668, l_first_op_RCY to 1 for exception

Line 9929: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'set l_routing_type and l_first_op_RCY');

9925: WHEN OTHERS THEN
9926: -- Bug 4143668, add debug message for exception
9927: IF PG_DEBUG in ('Y', 'C') THEN
9928: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'exception in cfm: '|| sqlcode);
9929: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'set l_routing_type and l_first_op_RCY');
9930: END IF;
9931: l_routing_type := NVL(l_routing_type, 2); -- Bug 4143668, use l_routing_type if already set, else 2
9932: l_first_op_RCY := 1; -- Bug 4143668, l_first_op_RCY to 1 for exception
9933: END;

Line 9940: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_routing_type := ' || l_routing_type);

9936: l_first_op_RCY := 1; -- Bug 4143668, l_first_op_RCY to 1 if Null
9937: END IF;
9938:
9939: IF PG_DEBUG in ('Y', 'C') THEN
9940: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_routing_type := ' || l_routing_type);
9941: msc_sch_wb.atp_debug('l_model_flag := ' || l_model_flag);
9942: END IF;
9943: IF NVL(l_model_flag, 2) <> 1 THEN
9944: IF i <> 1 THEN

Line 9941: msc_sch_wb.atp_debug('l_model_flag := ' || l_model_flag);

9937: END IF;
9938:
9939: IF PG_DEBUG in ('Y', 'C') THEN
9940: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_routing_type := ' || l_routing_type);
9941: msc_sch_wb.atp_debug('l_model_flag := ' || l_model_flag);
9942: END IF;
9943: IF NVL(l_model_flag, 2) <> 1 THEN
9944: IF i <> 1 THEN
9945: -- (3004862) circular BOM issue: Call get process effectivity again

Line 9947: msc_sch_wb.atp_debug('Calling Process effectivity for Phantom:'|| l_explode_comp.component_identifier(i));

9943: IF NVL(l_model_flag, 2) <> 1 THEN
9944: IF i <> 1 THEN
9945: -- (3004862) circular BOM issue: Call get process effectivity again
9946: -- for the Phantom Component's Bill.
9947: msc_sch_wb.atp_debug('Calling Process effectivity for Phantom:'|| l_explode_comp.component_identifier(i));
9948: MSC_ATP_PROC.get_process_effectivity(
9949: p_plan_id,
9950: l_explode_comp.component_identifier(i),
9951: p_organization_id,

Line 9977: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');

9973: l_explode_comp.requested_date(i),
9974: l_explode_comp.comp_usage(i),
9975: l_explode_comp.wip_supply_type(i)); --4106269
9976: IF PG_DEBUG in ('Y', 'C') THEN
9977: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');
9978: END IF;
9979: ELSE
9980:
9981: OPEN drp_comp(l_bill_seq_id, -- (3004862) circular BOM issue: call with changed parameter

Line 9985: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening DRP cursor drp_comp');

9981: OPEN drp_comp(l_bill_seq_id, -- (3004862) circular BOM issue: call with changed parameter
9982: l_explode_comp.requested_date(i),
9983: l_explode_comp.comp_usage(i));
9984: IF PG_DEBUG in ('Y', 'C') THEN
9985: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening DRP cursor drp_comp');
9986: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
9987: END IF;
9988: END IF;
9989: -- End ATP4drp

Line 9986: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

9982: l_explode_comp.requested_date(i),
9983: l_explode_comp.comp_usage(i));
9984: IF PG_DEBUG in ('Y', 'C') THEN
9985: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening DRP cursor drp_comp');
9986: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
9987: END IF;
9988: END IF;
9989: -- End ATP4drp
9990:

Line 9992: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');

9988: END IF;
9989: -- End ATP4drp
9990:
9991: IF PG_DEBUG in ('Y', 'C') THEN
9992: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');
9993: msc_sch_wb.atp_debug('l_bill_seq_id '||l_bill_seq_id);
9994: msc_sch_wb.atp_debug('requested_date '||l_explode_comp.requested_date(i));
9995: msc_sch_wb.atp_debug('comp_usage '|| l_explode_comp.comp_usage(i));
9996: END IF;

Line 9993: msc_sch_wb.atp_debug('l_bill_seq_id '||l_bill_seq_id);

9989: -- End ATP4drp
9990:
9991: IF PG_DEBUG in ('Y', 'C') THEN
9992: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');
9993: msc_sch_wb.atp_debug('l_bill_seq_id '||l_bill_seq_id);
9994: msc_sch_wb.atp_debug('requested_date '||l_explode_comp.requested_date(i));
9995: msc_sch_wb.atp_debug('comp_usage '|| l_explode_comp.comp_usage(i));
9996: END IF;
9997: END IF;

Line 9994: msc_sch_wb.atp_debug('requested_date '||l_explode_comp.requested_date(i));

9990:
9991: IF PG_DEBUG in ('Y', 'C') THEN
9992: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');
9993: msc_sch_wb.atp_debug('l_bill_seq_id '||l_bill_seq_id);
9994: msc_sch_wb.atp_debug('requested_date '||l_explode_comp.requested_date(i));
9995: msc_sch_wb.atp_debug('comp_usage '|| l_explode_comp.comp_usage(i));
9996: END IF;
9997: END IF;
9998: ELSIF l_model_flag = 1 THEN

Line 9995: msc_sch_wb.atp_debug('comp_usage '|| l_explode_comp.comp_usage(i));

9991: IF PG_DEBUG in ('Y', 'C') THEN
9992: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after opening network routing cursor net_rout_com');
9993: msc_sch_wb.atp_debug('l_bill_seq_id '||l_bill_seq_id);
9994: msc_sch_wb.atp_debug('requested_date '||l_explode_comp.requested_date(i));
9995: msc_sch_wb.atp_debug('comp_usage '|| l_explode_comp.comp_usage(i));
9996: END IF;
9997: END IF;
9998: ELSIF l_model_flag = 1 THEN
9999: IF PG_DEBUG in ('Y', 'C') THEN

Line 10000: msc_sch_wb.atp_debug('Explode Model or its components Bom');

9996: END IF;
9997: END IF;
9998: ELSIF l_model_flag = 1 THEN
9999: IF PG_DEBUG in ('Y', 'C') THEN
10000: msc_sch_wb.atp_debug('Explode Model or its components Bom');
10001: msc_sch_wb.atp_debug('l_model_atp_comp_flag := ' || l_model_atp_comp_flag);
10002: END IF;
10003: IF l_model_atp_comp_flag in ('Y', 'C') THEN
10004: ---explode mandatory components if model or option class

Line 10001: msc_sch_wb.atp_debug('l_model_atp_comp_flag := ' || l_model_atp_comp_flag);

9997: END IF;
9998: ELSIF l_model_flag = 1 THEN
9999: IF PG_DEBUG in ('Y', 'C') THEN
10000: msc_sch_wb.atp_debug('Explode Model or its components Bom');
10001: msc_sch_wb.atp_debug('l_model_atp_comp_flag := ' || l_model_atp_comp_flag);
10002: END IF;
10003: IF l_model_atp_comp_flag in ('Y', 'C') THEN
10004: ---explode mandatory components if model or option class
10005: IF l_explode_comp.bom_item_type(i) in (1,2) or

Line 10009: msc_sch_wb.atp_debug('i = ' || i);

10005: IF l_explode_comp.bom_item_type(i) in (1,2) or
10006: (l_explode_comp.bom_item_type(i) = 4 and MSC_ATP_PVT.G_INV_CTP = 5) THEN
10007:
10008: IF PG_DEBUG in ('Y', 'C') THEN
10009: msc_sch_wb.atp_debug('i = ' || i);
10010: END IF;
10011: l_lead_time := CEIL((NVL(l_explode_comp.fixed_lt(i), 0) +
10012: NVL(l_explode_comp.variable_lt(i), 0)*l_explode_comp.comp_usage(i))
10013: * (1 + l_mso_lead_time_factor));

Line 10016: msc_sch_wb.atp_debug('l_lead_time = ' || l_lead_time);

10012: NVL(l_explode_comp.variable_lt(i), 0)*l_explode_comp.comp_usage(i))
10013: * (1 + l_mso_lead_time_factor));
10014:
10015: IF PG_DEBUG in ('Y', 'C') THEN
10016: msc_sch_wb.atp_debug('l_lead_time = ' || l_lead_time);
10017: END IF;
10018:
10019: IF nvl(l_lead_time, 0) > 0 AND p_search = 1 THEN
10020: l_request_date := MSC_CALENDAR.DATE_OFFSET

Line 10031: msc_sch_wb.atp_debug('l_request_date := ' || l_request_date);

10027: l_request_date := l_explode_comp.requested_date(i);
10028: END IF;
10029:
10030: IF PG_DEBUG in ('Y', 'C') THEN
10031: msc_sch_wb.atp_debug('l_request_date := ' || l_request_date);
10032: END IF;
10033:
10034: IF MSC_ATP_PVT.G_WS_CALL = 'N' THEN --Not a Web Serviec call
10035: MSC_ATP_CTO.Get_Mandatory_Components(p_plan_id,

Line 10045: msc_sch_wb.atp_debug('After Get mand comp, add it to list of components');

10041: l_explode_comp.dest_inventory_item_id(i),
10042: l_mand_comp_info_rec);
10043:
10044: IF PG_DEBUG in ('Y', 'C') THEN
10045: msc_sch_wb.atp_debug('After Get mand comp, add it to list of components');
10046: END IF;
10047: END IF;
10048:
10049: FOR l_cto_count in 1..l_mand_comp_info_rec.sr_inventory_item_id.count LOOP

Line 10124: msc_sch_wb.atp_debug('Get CTO Bom');

10120: END IF;
10121:
10122: --now call for CTO Bom
10123: IF PG_DEBUG in ('Y', 'C') THEN
10124: msc_sch_wb.atp_debug('Get CTO Bom');
10125: END IF;
10126:
10127: MSC_ATP_CTO.Get_CTO_BOM(MSC_ATP_PVT.G_SESSION_ID,
10128: l_cto_bom_rec,

Line 10144: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'i = '||i);

10140:
10141: END IF;
10142:
10143: IF PG_DEBUG in ('Y', 'C') THEN
10144: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'i = '||i);
10145: END IF;
10146:
10147:
10148: -- 3027711

Line 10161: msc_sch_wb.atp_debug('Before Fetch of net_rout_comp');

10157: -- ATP4drp fetch from DRP specific cursor for DRP plans.
10158: IF NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_type, 1) <> 5 THEN
10159: -- Non DRP Plan
10160: IF PG_DEBUG in ('Y', 'C') THEN
10161: msc_sch_wb.atp_debug('Before Fetch of net_rout_comp');
10162: END IF;
10163: FETCH net_rout_comp INTO
10164: l_comp_item_id,
10165: l_comp_component_identifier, -- (3004862) circular BOM issue

Line 10186: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetching cursor net_rout_comp');

10182: l_usage_qty; --4775920
10183:
10184: EXIT WHEN net_rout_comp%NOTFOUND;
10185: IF PG_DEBUG in ('Y', 'C') THEN
10186: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetching cursor net_rout_comp');
10187: END IF;
10188: ELSE -- DRP plan
10189: IF PG_DEBUG in ('Y', 'C') THEN
10190: msc_sch_wb.atp_debug('Before Fetch of drp_comp');

Line 10190: msc_sch_wb.atp_debug('Before Fetch of drp_comp');

10186: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetching cursor net_rout_comp');
10187: END IF;
10188: ELSE -- DRP plan
10189: IF PG_DEBUG in ('Y', 'C') THEN
10190: msc_sch_wb.atp_debug('Before Fetch of drp_comp');
10191: END IF;
10192: FETCH drp_comp INTO
10193: l_comp_item_id,
10194: l_comp_component_identifier, -- (3004862) circular BOM issue

Line 10215: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetching cursor drp_comp');

10211: l_usage_qty; --4775920
10212:
10213: EXIT WHEN drp_comp%NOTFOUND;
10214: IF PG_DEBUG in ('Y', 'C') THEN
10215: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetching cursor drp_comp');
10216: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10217: END IF;
10218: END IF;
10219: -- END ATP4drp

Line 10216: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

10212:
10213: EXIT WHEN drp_comp%NOTFOUND;
10214: IF PG_DEBUG in ('Y', 'C') THEN
10215: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetching cursor drp_comp');
10216: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10217: END IF;
10218: END IF;
10219: -- END ATP4drp
10220:

Line 10223: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetch');

10219: -- END ATP4drp
10220:
10221:
10222: IF PG_DEBUG in ('Y', 'C') THEN
10223: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetch');
10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);
10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);

Line 10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);

10220:
10221:
10222: IF PG_DEBUG in ('Y', 'C') THEN
10223: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetch');
10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);
10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);

Line 10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);

10221:
10222: IF PG_DEBUG in ('Y', 'C') THEN
10223: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetch');
10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);
10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);

Line 10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);

10222: IF PG_DEBUG in ('Y', 'C') THEN
10223: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetch');
10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);
10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);

Line 10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);

10223: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after fetch');
10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);
10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);

Line 10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);

10224: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_item_id = '||l_comp_item_id);
10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);

Line 10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);

10225: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_usage = '||l_comp_usage);
10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);

Line 10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);

10226: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_date = '||l_comp_date);
10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);

Line 10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);

10227: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_lead_time = '||l_comp_lead_time);
10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023

Line 10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);

10228: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_wip_supply_type = '||l_comp_wip_supply_type);
10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421

Line 10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);

10229: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_assembly_identifier = '||l_comp_assembly_identifier);
10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);

Line 10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);

10230: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_component_identifier = '||l_comp_component_identifier);
10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);

Line 10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023

10231: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_pre_pro_lead_time = '||l_comp_pre_pro_lead_time);
10232: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atf_date = '||l_atf_date);
10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);

Line 10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);

10233: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_ASSEMBLY_LINE_ID = '||MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);
10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);
10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);

Line 10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);

10234: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);
10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);
10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);
10242: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_usage_qty = '||l_usage_qty); --4775920

Line 10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);

10235: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_uom = '||l_comp_uom); --bug3110023
10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);
10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);
10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);
10242: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_usage_qty = '||l_usage_qty); --4775920
10243:

Line 10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);

10236: --4570421
10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);
10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);
10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);
10242: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_usage_qty = '||l_usage_qty); --4775920
10243:
10244:

Line 10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);

10237: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scaling_type = '||l_scaling_type);
10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);
10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);
10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);
10242: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_usage_qty = '||l_usage_qty); --4775920
10243:
10244:
10245:

Line 10242: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_usage_qty = '||l_usage_qty); --4775920

10238: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_multiple = '||l_scale_multiple);
10239: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_scale_rounding_variance = '||l_scale_rounding_variance);
10240: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_rounding_direction = '||l_rounding_direction);
10241: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_component_yield_factor = '||l_component_yield_factor);
10242: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_usage_qty = '||l_usage_qty); --4775920
10243:
10244:
10245:
10246: END IF;

Line 10267: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

10263: -- Turn Off Product Family ATP for components.
10264: l_atp_comp_rec.inventory_item_id := l_comp_item_id ;
10265: -- ATP4drp PF ATP not supported for DRP. Print out Debug Here.
10266: IF NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_type, 1) = 5 AND PG_DEBUG in ('Y', 'C') THEN
10267: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10268: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.inventory_item_id '
10269: || l_atp_comp_rec.inventory_item_id );
10270: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.request_item_id '
10271: || l_atp_comp_rec.request_item_id );

Line 10268: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.inventory_item_id '

10264: l_atp_comp_rec.inventory_item_id := l_comp_item_id ;
10265: -- ATP4drp PF ATP not supported for DRP. Print out Debug Here.
10266: IF NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_type, 1) = 5 AND PG_DEBUG in ('Y', 'C') THEN
10267: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10268: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.inventory_item_id '
10269: || l_atp_comp_rec.inventory_item_id );
10270: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.request_item_id '
10271: || l_atp_comp_rec.request_item_id );
10272: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

Line 10270: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.request_item_id '

10266: IF NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_type, 1) = 5 AND PG_DEBUG in ('Y', 'C') THEN
10267: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10268: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.inventory_item_id '
10269: || l_atp_comp_rec.inventory_item_id );
10270: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.request_item_id '
10271: || l_atp_comp_rec.request_item_id );
10272: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10273: END IF;
10274: ELSE -- Non DRP Plans

Line 10272: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

10268: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.inventory_item_id '
10269: || l_atp_comp_rec.inventory_item_id );
10270: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_comp_rec.request_item_id '
10271: || l_atp_comp_rec.request_item_id );
10272: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10273: END IF;
10274: ELSE -- Non DRP Plans
10275: l_atp_comp_rec.inventory_item_id := MSC_ATP_PF.Get_PF_Atp_Item_Id(
10276: p_instance_id,

Line 10329: msc_sch_wb.atp_debug('Model Entity ');

10325:
10326: END LOOP; -- end the loop of fetch
10327: ELSE
10328: IF PG_DEBUG in ('Y', 'C') THEN
10329: msc_sch_wb.atp_debug('Model Entity ');
10330: msc_sch_wb.atp_debug('l_model_atp_comp_flag := ' || l_model_atp_comp_flag);
10331: END IF;
10332:
10333: IF l_model_atp_comp_flag in ('Y', 'C') THEN

Line 10330: msc_sch_wb.atp_debug('l_model_atp_comp_flag := ' || l_model_atp_comp_flag);

10326: END LOOP; -- end the loop of fetch
10327: ELSE
10328: IF PG_DEBUG in ('Y', 'C') THEN
10329: msc_sch_wb.atp_debug('Model Entity ');
10330: msc_sch_wb.atp_debug('l_model_atp_comp_flag := ' || l_model_atp_comp_flag);
10331: END IF;
10332:
10333: IF l_model_atp_comp_flag in ('Y', 'C') THEN
10334: FOR l_cto_count in 1..l_cto_bom_rec.inventory_item_id.count LOOP

Line 10409: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor net_rout_comp');

10405: -- Bug 4042403, 4047183, 4070094 Close the cursor only if it has been opened.
10406: IF net_rout_comp%ISOPEN THEN
10407: CLOSE net_rout_comp;
10408: IF PG_DEBUG in ('Y', 'C') THEN
10409: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor net_rout_comp');
10410: END IF;
10411: END IF;
10412: -- End Bug 4042403, 4047183, 4070094
10413: ELSE -- DRP plan

Line 10418: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor drp_comp');

10414: -- Bug 4042403, 4047183, 4070094 Close the cursor only if it has been opened.
10415: IF drp_comp%ISOPEN THEN
10416: CLOSE drp_comp;
10417: IF PG_DEBUG in ('Y', 'C') THEN
10418: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor drp_comp');
10419: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10420: END IF;
10421: END IF;
10422: -- End Bug 4042403, 4047183, 4070094

Line 10419: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');

10415: IF drp_comp%ISOPEN THEN
10416: CLOSE drp_comp;
10417: IF PG_DEBUG in ('Y', 'C') THEN
10418: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor drp_comp');
10419: msc_sch_wb.atp_debug('----- ATP4drp Specific Debug Messages -----');
10420: END IF;
10421: END IF;
10422: -- End Bug 4042403, 4047183, 4070094
10423: END IF;

Line 10433: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor cto_comp');

10429: ELSIF l_cto_bom > 0 THEN
10430: CLOSE cto_comp;
10431:
10432: IF PG_DEBUG in ('Y', 'C') THEN
10433: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'after closing cursor cto_comp');
10434: END IF;
10435: END IF;
10436: e_cto_rearch */
10437: i := l_explode_comp.inventory_item_id.NEXT(i);

Line 10440: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'second time, i = '||i);

10436: e_cto_rearch */
10437: i := l_explode_comp.inventory_item_id.NEXT(i);
10438:
10439: IF PG_DEBUG in ('Y', 'C') THEN
10440: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'second time, i = '||i);
10441: END IF;
10442: END LOOP;
10443:
10444: -- 3027711 move initializing x_atp_date/x_avail_assembly_qty to beginning

Line 10447: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);

10443:
10444: -- 3027711 move initializing x_atp_date/x_avail_assembly_qty to beginning
10445:
10446: IF PG_DEBUG in ('Y', 'C') THEN
10447: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);
10448: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.inventory_item_id.count = '||
10449: l_comp_requirements.inventory_item_id.count);
10450: END IF;
10451: --msc_sch_wb.atp_debug('l_comp_requirements.pre_process_lead_time.count = '||

Line 10448: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.inventory_item_id.count = '||

10444: -- 3027711 move initializing x_atp_date/x_avail_assembly_qty to beginning
10445:
10446: IF PG_DEBUG in ('Y', 'C') THEN
10447: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);
10448: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.inventory_item_id.count = '||
10449: l_comp_requirements.inventory_item_id.count);
10450: END IF;
10451: --msc_sch_wb.atp_debug('l_comp_requirements.pre_process_lead_time.count = '||
10452: -- l_comp_requirements.pre_process_lead_time.count);

Line 10451: --msc_sch_wb.atp_debug('l_comp_requirements.pre_process_lead_time.count = '||

10447: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);
10448: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.inventory_item_id.count = '||
10449: l_comp_requirements.inventory_item_id.count);
10450: END IF;
10451: --msc_sch_wb.atp_debug('l_comp_requirements.pre_process_lead_time.count = '||
10452: -- l_comp_requirements.pre_process_lead_time.count);
10453:
10454: j := l_comp_requirements.inventory_item_id.first;
10455: -- if j is null, that means we don't have any comp requirements

Line 10472: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '|| p_search);

10468: --- is greater than sysdate or not
10469: --- if not then we can't meet the requirement
10470: --- We check only when we are in first time.
10471: IF PG_DEBUG in ('Y', 'C') THEN
10472: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '|| p_search);
10473: END IF;
10474:
10475: IF PG_DEBUG in ('Y', 'C') THEN
10476: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'j := '||j);

Line 10476: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'j := '||j);

10472: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = '|| p_search);
10473: END IF;
10474:
10475: IF PG_DEBUG in ('Y', 'C') THEN
10476: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'j := '||j);
10477: END IF;
10478:
10479: ---diag_atp: we look for complete quantity in case of diagnostic ATP
10480: IF PG_DEBUG in ('Y', 'C') THEN

Line 10481: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.comp_usage(j) := '||l_comp_requirements.comp_usage(j));

10477: END IF;
10478:
10479: ---diag_atp: we look for complete quantity in case of diagnostic ATP
10480: IF PG_DEBUG in ('Y', 'C') THEN
10481: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.comp_usage(j) := '||l_comp_requirements.comp_usage(j));
10482: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty := '||x_avail_assembly_qty);
10483: END IF;
10484: IF MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 1 THEN
10485: --- for diagnostic atp we always order the full quantity.

Line 10482: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty := '||x_avail_assembly_qty);

10478:
10479: ---diag_atp: we look for complete quantity in case of diagnostic ATP
10480: IF PG_DEBUG in ('Y', 'C') THEN
10481: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_comp_requirements.comp_usage(j) := '||l_comp_requirements.comp_usage(j));
10482: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty := '||x_avail_assembly_qty);
10483: END IF;
10484: IF MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 1 THEN
10485: --- for diagnostic atp we always order the full quantity.
10486: IF ( (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.DISCRETE_ORG AND nvl(l_comp_requirements.scaling_type(j),1) = 2) OR

Line 10508: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_requested_comp_qty := '||l_requested_comp_qty);

10504:
10505: END IF;
10506: --4570421 , print l_requested_comp_qty here !
10507: IF PG_DEBUG in ('Y', 'C') THEN
10508: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_requested_comp_qty := '||l_requested_comp_qty);
10509: END IF;
10510:
10511: -- now call atp check for this item:
10512: -- 1: populate the atp rec

Line 10528: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);

10524:
10525: MSC_ATP_PVT.G_ASSEMBLY_LINE_ID := NVL(l_comp_requirements.assembly_identifier(j), MSC_ATP_PVT.G_ASSEMBLY_LINE_ID);
10526: MSC_ATP_PVT.G_COMP_LINE_ID := NVL(l_comp_requirements.component_identifier(j), MSC_ATP_PVT.G_COMP_LINE_ID);
10527: IF PG_DEBUG in ('Y', 'C') THEN
10528: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'G_COMP_LINE_ID = '||MSC_ATP_PVT.G_COMP_LINE_ID);
10529: END IF;
10530:
10531: -- no need to do uom conversion
10532: l_atp_rec.instance_id := p_instance_id;

Line 10579: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Demand Class being passed is : '|| l_atp_rec.demand_class);

10575: -- Bug 2424357
10576: l_atp_rec.demand_class := NVL(MSC_ATP_PVT.G_ATP_DEMAND_CLASS, p_demand_class);
10577:
10578: IF PG_DEBUG in ('Y', 'C') THEN
10579: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Demand Class being passed is : '|| l_atp_rec.demand_class);
10580: END IF;
10581: -- end 2408902
10582:
10583: --s_cto_enhc

Line 10597: msc_sch_wb.atp_debug('Item not collected := ' || l_comp_requirements.inventory_item_id(j));

10593: --item doesn't exists in the given organization
10594: l_model_error_code := MSC_ATP_PVT.ATP_ITEM_NOT_COLLECTED;
10595:
10596: IF PG_DEBUG in ('Y', 'C') THEN
10597: msc_sch_wb.atp_debug('Item not collected := ' || l_comp_requirements.inventory_item_id(j));
10598: END IF;
10599:
10600: ELSIF l_model_flag = 1 and l_comp_requirements.atp_flag(j) = 'N'
10601: and l_comp_requirements.atp_components_flag(j) = 'N' THEN

Line 10627: msc_sch_wb.atp_debug('Match found := ' || l_atp_rec.inventory_item_id);

10623: l_atp_rec.demand_class);*/
10624: /* time_phased_atp changes begin
10625: Call new procedure Get_PF_Plan_Info*/
10626: IF PG_DEBUG in ('Y', 'C') THEN
10627: msc_sch_wb.atp_debug('Match found := ' || l_atp_rec.inventory_item_id);
10628: msc_sch_wb.atp_debug('Find plan for match');
10629: END IF;
10630: MSC_ATP_PF.Get_PF_Plan_Info(
10631: p_instance_id,

Line 10628: msc_sch_wb.atp_debug('Find plan for match');

10624: /* time_phased_atp changes begin
10625: Call new procedure Get_PF_Plan_Info*/
10626: IF PG_DEBUG in ('Y', 'C') THEN
10627: msc_sch_wb.atp_debug('Match found := ' || l_atp_rec.inventory_item_id);
10628: msc_sch_wb.atp_debug('Find plan for match');
10629: END IF;
10630: MSC_ATP_PF.Get_PF_Plan_Info(
10631: p_instance_id,
10632: l_atp_rec.request_item_id,

Line 10644: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error encountered in Get_PF_Plan_Info');

10640: );
10641:
10642: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
10643: IF PG_DEBUG in ('Y', 'C') THEN
10644: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error encountered in Get_PF_Plan_Info');
10645: END IF;
10646: END IF;
10647: /* time_phased_atp changes end*/
10648:

Line 10652: msc_sch_wb.atp_debug('Plan found for match := ' || MSC_ATP_PVT.G_PLAN_INFO_REC.plan_id );

10648:
10649: IF MSC_ATP_PVT.G_PLAN_INFO_REC.plan_id is not null and
10650: NVL(MSC_ATP_PVT.G_PLAN_INFO_REC.plan_id, -1) <> -1 then
10651: IF PG_DEBUG in ('Y', 'C') THEN
10652: msc_sch_wb.atp_debug('Plan found for match := ' || MSC_ATP_PVT.G_PLAN_INFO_REC.plan_id );
10653: END IF;
10654: ---plan found for match
10655: l_plan_found_for_match := 1;
10656: --l_atp_rec.request_item_id := l_comp_requirements.match_item_id(j);

Line 10663: msc_sch_wb.atp_debug('Plan not found for match := ' || MSC_ATP_PVT.G_PLAN_INFO_REC.plan_id );

10659: ELSE
10660: ---plan is not found for match. Do ATP on model level
10661: --l_atp_rec.inventory_item_id := l_comp_requirements.inventory_item_id(j);
10662: IF PG_DEBUG in ('Y', 'C') THEN
10663: msc_sch_wb.atp_debug('Plan not found for match := ' || MSC_ATP_PVT.G_PLAN_INFO_REC.plan_id );
10664: END IF;
10665: /* time_phased_atp
10666: Support PF ATP for components*/
10667: l_atp_rec.inventory_item_id := l_comp_requirements.inventory_item_id(j);

Line 10698: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error encountered in Get_PF_Plan_Info');

10694: );
10695:
10696: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
10697: IF PG_DEBUG in ('Y', 'C') THEN
10698: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error encountered in Get_PF_Plan_Info');
10699: END IF;
10700: END IF;
10701: /* time_phased_atp changes end*/
10702: END IF;

Line 10717: msc_sch_wb.atp_debug ('Plan ID in Get_Comp_Reqs : ' || l_plan_id);

10713: l_atp_rec.quantity_uom := l_comp_requirements.comp_uom(j); --bug3110023
10714:
10715: -- changes for bug 2392456 ends
10716:
10717: msc_sch_wb.atp_debug ('Plan ID in Get_Comp_Reqs : ' || l_plan_id);
10718: IF (l_plan_id is NULL) or (l_plan_id IN (-100, -200)) THEN
10719: --s_cto_rearch
10720: IF l_model_flag = 1 THEN
10721: l_model_error_code := MSC_ATP_PVT.PLAN_NOT_FOUND;

Line 10734: msc_sch_wb.atp_debug('Get_Comp_Req: ATP Downtime Detected');

10730: -- 24x7
10731: IF (l_plan_id = -300) then
10732: l_atp_rec.error_code := MSC_ATP_PVT.TRY_ATP_LATER;
10733: IF PG_DEBUG in ('Y', 'C') THEN
10734: msc_sch_wb.atp_debug('Get_Comp_Req: ATP Downtime Detected');
10735: msc_sch_wb.atp_debug('Get_Comp_Requirements: ATP Downtime');
10736: END IF;
10737: MSC_ATP_PVT.G_DOWNTIME_HIT := 'Y';
10738: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;

Line 10735: msc_sch_wb.atp_debug('Get_Comp_Requirements: ATP Downtime');

10731: IF (l_plan_id = -300) then
10732: l_atp_rec.error_code := MSC_ATP_PVT.TRY_ATP_LATER;
10733: IF PG_DEBUG in ('Y', 'C') THEN
10734: msc_sch_wb.atp_debug('Get_Comp_Req: ATP Downtime Detected');
10735: msc_sch_wb.atp_debug('Get_Comp_Requirements: ATP Downtime');
10736: END IF;
10737: MSC_ATP_PVT.G_DOWNTIME_HIT := 'Y';
10738: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;
10739: End IF;

Line 10803: msc_sch_wb.atp_debug('Model entity and error has occured');

10799: ---e_cto_rearch
10800: IF l_model_flag = 1 and l_model_error_code > 0 THEN
10801:
10802: IF PG_DEBUG in ('Y', 'C') THEN
10803: msc_sch_wb.atp_debug('Model entity and error has occured');
10804: msc_sch_wb.atp_debug('Error code := ' || l_model_error_code);
10805: END IF;
10806:
10807: /* bug 7508506

Line 10804: msc_sch_wb.atp_debug('Error code := ' || l_model_error_code);

10800: IF l_model_flag = 1 and l_model_error_code > 0 THEN
10801:
10802: IF PG_DEBUG in ('Y', 'C') THEN
10803: msc_sch_wb.atp_debug('Model entity and error has occured');
10804: msc_sch_wb.atp_debug('Error code := ' || l_model_error_code);
10805: END IF;
10806:
10807: /* bug 7508506
10808: * l_atp_rec.combined_requested_date_qty := 0;

Line 10879: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_rec.parent_item_id ' || l_atp_rec.parent_item_id );

10875: l_atp_rec.parent_item_id := p_inventory_item_id;
10876: END IF;
10877:
10878: IF PG_DEBUG in ('Y', 'C') THEN
10879: msc_sch_wb.atp_debug('Get_Comp_Requirements: l_atp_rec.parent_item_id ' || l_atp_rec.parent_item_id );
10880: END IF;
10881: -- End ATP4drp
10882:
10883: l_alloc_atp := MSC_ATP_PVT.G_ALLOCATED_ATP; --ALLOC ATP CHANGES, 12973673

Line 10909: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || ' Error in OSS');

10905:
10906: RAISE MSC_ATP_PVT.INVALID_OSS_SOURCE;
10907:
10908: IF PG_DEBUG in ('Y', 'C') THEN
10909: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || ' Error in OSS');
10910: END IF;
10911:
10912: -- Bug 1531429, in case return status is not success, raise an exception.
10913: -- krajan: 2400614

Line 10922: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Get_Comp_Req: Error in ATP_CHECK 0.1');

10918: -- krajan : 2752705 and dsting 2764213 : Other errors that need to go through to the
10919: -- top level model are also handled the same way as the mismatch case.
10920: ELSIF x_return_status = MSC_ATP_PVT.G_ATO_SRC_MISMATCH THEN
10921: IF PG_DEBUG in ('Y', 'C') THEN
10922: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Get_Comp_Req: Error in ATP_CHECK 0.1');
10923: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error in lower level component check');
10924: END IF;
10925: RAISE MSC_ATP_PVT.G_ATO_SOURCING_MISMATCH;
10926:

Line 10923: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error in lower level component check');

10919: -- top level model are also handled the same way as the mismatch case.
10920: ELSIF x_return_status = MSC_ATP_PVT.G_ATO_SRC_MISMATCH THEN
10921: IF PG_DEBUG in ('Y', 'C') THEN
10922: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Get_Comp_Req: Error in ATP_CHECK 0.1');
10923: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'Error in lower level component check');
10924: END IF;
10925: RAISE MSC_ATP_PVT.G_ATO_SOURCING_MISMATCH;
10926:
10927: --bug 3308206: IF ATP rule is not defined on the item then error out with message

Line 10931: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'No ATP rule on Component');

10927: --bug 3308206: IF ATP rule is not defined on the item then error out with message
10928: ELSIF MSC_ATP_PVT.G_INV_CTP = 5 and x_return_status <> FND_API.G_RET_STS_SUCCESS
10929: and l_atp_rec.error_code = MSC_ATP_PVT.ATP_BAD_RULE THEN
10930: IF PG_DEBUG in ('Y', 'C') THEN
10931: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'No ATP rule on Component');
10932: END IF;
10933: RAISE MSC_ATP_PVT.EXC_NO_ATP_RULE;
10934: END IF;
10935:

Line 10939: msc_sch_wb.atp_debug('Get_Comp_Req: Error in ATP_CHECK 0.2');

10935:
10936: -- dsting 2764213
10937: IF x_return_status = MSC_ATP_PVT.G_NO_PLAN_FOUND THEN
10938: IF PG_DEBUG in ('Y', 'C') THEN
10939: msc_sch_wb.atp_debug('Get_Comp_Req: Error in ATP_CHECK 0.2');
10940: msc_sch_wb.atp_debug('Get_Comp_Requirements: Error in lower level component check');
10941: END IF;
10942: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;
10943: END IF;

Line 10940: msc_sch_wb.atp_debug('Get_Comp_Requirements: Error in lower level component check');

10936: -- dsting 2764213
10937: IF x_return_status = MSC_ATP_PVT.G_NO_PLAN_FOUND THEN
10938: IF PG_DEBUG in ('Y', 'C') THEN
10939: msc_sch_wb.atp_debug('Get_Comp_Req: Error in ATP_CHECK 0.2');
10940: msc_sch_wb.atp_debug('Get_Comp_Requirements: Error in lower level component check');
10941: END IF;
10942: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;
10943: END IF;
10944:

Line 10948: msc_sch_wb.atp_debug('Get_Comp_Req: Error in ATP_CHECK 0.3');

10944:
10945: -- krajan 2752705
10946: IF x_return_status = MSC_ATP_PVT.G_ATO_UNCOLL_ITEM THEN
10947: IF PG_DEBUG in ('Y', 'C') THEN
10948: msc_sch_wb.atp_debug('Get_Comp_Req: Error in ATP_CHECK 0.3');
10949: msc_sch_wb.atp_debug('Get_Comp_Requirements: Error in lower level component check');
10950: END IF;
10951: RAISE MSC_ATP_PVT.G_EXC_UNCOLLECTED_ITEM;
10952: END IF;

Line 10949: msc_sch_wb.atp_debug('Get_Comp_Requirements: Error in lower level component check');

10945: -- krajan 2752705
10946: IF x_return_status = MSC_ATP_PVT.G_ATO_UNCOLL_ITEM THEN
10947: IF PG_DEBUG in ('Y', 'C') THEN
10948: msc_sch_wb.atp_debug('Get_Comp_Req: Error in ATP_CHECK 0.3');
10949: msc_sch_wb.atp_debug('Get_Comp_Requirements: Error in lower level component check');
10950: END IF;
10951: RAISE MSC_ATP_PVT.G_EXC_UNCOLLECTED_ITEM;
10952: END IF;
10953:

Line 10968: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atp_rec.combined_requested_date_qty := ' || l_atp_rec.combined_requested_date_qty);

10964:
10965:
10966: -- now adjust the x_avail_assembly_qty
10967: IF PG_DEBUG in ('Y', 'C') THEN
10968: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atp_rec.combined_requested_date_qty := ' || l_atp_rec.combined_requested_date_qty);
10969: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atp_rec.requested_date_quantity := ' ||l_atp_rec.requested_date_quantity);
10970: END IF;
10971:
10972: IF p_search = 1 THEN

Line 10969: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atp_rec.requested_date_quantity := ' ||l_atp_rec.requested_date_quantity);

10965:
10966: -- now adjust the x_avail_assembly_qty
10967: IF PG_DEBUG in ('Y', 'C') THEN
10968: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atp_rec.combined_requested_date_qty := ' || l_atp_rec.combined_requested_date_qty);
10969: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'l_atp_rec.requested_date_quantity := ' ||l_atp_rec.requested_date_quantity);
10970: END IF;
10971:
10972: IF p_search = 1 THEN
10973:

Line 10975: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = 1');

10971:
10972: IF p_search = 1 THEN
10973:
10974: IF PG_DEBUG in ('Y', 'C') THEN
10975: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = 1');
10976: END IF;
10977:
10978: -- cchen 1238941
10979: --4570421

Line 10989: msc_sch_wb.atp_debug('Fixed or Lot Based Case: Lot qty not available: avail_assembly_qty: ' || x_avail_assembly_qty);

10985: IF ( (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.DISCRETE_ORG AND nvl(l_comp_requirements.scaling_type(j),1) = 2) OR
10986: (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.OPM_ORG AND nvl(l_comp_requirements.scaling_type(j),1) IN (0,2))) THEN
10987: x_avail_assembly_qty := 0;
10988: IF PG_DEBUG in ('Y', 'C') THEN
10989: msc_sch_wb.atp_debug('Fixed or Lot Based Case: Lot qty not available: avail_assembly_qty: ' || x_avail_assembly_qty);
10990: END IF;
10991: IF MSC_ATP_PVT.G_DIAGNOSTIC_ATP = 2 THEN --5403495
10992: EXIT;
10993: END IF;

Line 10997: msc_sch_wb.atp_debug('Before inverse scaling : avail_assembly_qty: ' || x_avail_assembly_qty);

10993: END IF;
10994: --EXIT;
10995: ELSIF ( (MSC_ATP_PVT.G_ORG_INFO_REC.org_type = MSC_ATP_PVT.OPM_ORG) AND (nvl(l_comp_requirements.scaling_type(j),1) IN (4,5)) ) THEN
10996: IF PG_DEBUG in ('Y', 'C') THEN
10997: msc_sch_wb.atp_debug('Before inverse scaling : avail_assembly_qty: ' || x_avail_assembly_qty);
10998: END IF;
10999: x_avail_assembly_qty := LEAST(x_avail_assembly_qty,
11000: round(
11001: FLOOR( NVL(l_atp_rec.combined_requested_date_qty,

Line 11005: msc_sch_wb.atp_debug('Integer Scaling case : avail_assembly_qty: ' || x_avail_assembly_qty);

11001: FLOOR( NVL(l_atp_rec.combined_requested_date_qty,
11002: l_atp_rec.requested_date_quantity)/l_comp_requirements.scale_multiple(j))* l_comp_requirements.scale_multiple(j)
11003: /l_comp_requirements.comp_usage(j),6));
11004: IF PG_DEBUG in ('Y', 'C') THEN
11005: msc_sch_wb.atp_debug('Integer Scaling case : avail_assembly_qty: ' || x_avail_assembly_qty);
11006: END IF;
11007: ELSE
11008: x_avail_assembly_qty := LEAST(x_avail_assembly_qty,
11009: trunc(NVL(l_atp_rec.combined_requested_date_qty,

Line 11013: msc_sch_wb.atp_debug('Item or Proportional case : avail_assembly_qty: ' || x_avail_assembly_qty);

11009: trunc(NVL(l_atp_rec.combined_requested_date_qty,
11010: l_atp_rec.requested_date_quantity)/
11011: l_comp_requirements.comp_usage(j),6)); -- 5598066
11012: IF PG_DEBUG in ('Y', 'C') THEN
11013: msc_sch_wb.atp_debug('Item or Proportional case : avail_assembly_qty: ' || x_avail_assembly_qty);
11014: END IF;
11015: END IF;
11016: ELSE
11017: x_avail_assembly_qty := 0;

Line 11029: msc_sch_wb.atp_debug('avail_assembly_qty: ' || x_avail_assembly_qty);

11025: --x_avail_assembly_qty := 0;
11026:
11027: -- 2869830
11028: IF PG_DEBUG in ('Y', 'C') THEN
11029: msc_sch_wb.atp_debug('avail_assembly_qty: ' || x_avail_assembly_qty);
11030: END IF;
11031:
11032: IF l_rounding_flag = 1 THEN
11033: x_avail_assembly_qty := FLOOR(x_avail_assembly_qty);

Line 11034: msc_sch_wb.atp_debug('rounded avail qty: ' ||

11030: END IF;
11031:
11032: IF l_rounding_flag = 1 THEN
11033: x_avail_assembly_qty := FLOOR(x_avail_assembly_qty);
11034: msc_sch_wb.atp_debug('rounded avail qty: ' ||
11035: x_avail_assembly_qty);
11036: END IF;
11037: IF PG_DEBUG in ('Y', 'C') THEN
11038: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty' || x_avail_assembly_qty);

Line 11038: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty' || x_avail_assembly_qty);

11034: msc_sch_wb.atp_debug('rounded avail qty: ' ||
11035: x_avail_assembly_qty);
11036: END IF;
11037: IF PG_DEBUG in ('Y', 'C') THEN
11038: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty' || x_avail_assembly_qty);
11039: END IF;
11040: ELSE
11041: IF PG_DEBUG in ('Y', 'C') THEN
11042: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = 2');

Line 11042: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = 2');

11038: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_avail_assembly_qty' || x_avail_assembly_qty);
11039: END IF;
11040: ELSE
11041: IF PG_DEBUG in ('Y', 'C') THEN
11042: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'p_search = 2');
11043: END IF;
11044:
11045: IF l_atp_rec.ship_date IS NOT NULL THEN
11046: x_atp_date := GREATEST(MSC_CALENDAR.DATE_OFFSET

Line 11059: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);

11055: -- then date from last source will be used as the availability date.
11056: ---Therefore, no need to continue further
11057: IF x_atp_date >= p_comp_info_rec.ship_date_this_level THEN
11058: IF PG_DEBUG in ('Y', 'C') THEN
11059: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);
11060: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date > ship_date_this_level. Therefore exit');
11061: END IF;
11062: x_atp_date := null;
11063: EXIT;

Line 11060: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date > ship_date_this_level. Therefore exit');

11056: ---Therefore, no need to continue further
11057: IF x_atp_date >= p_comp_info_rec.ship_date_this_level THEN
11058: IF PG_DEBUG in ('Y', 'C') THEN
11059: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date := ' || x_atp_date);
11060: msc_sch_wb.atp_debug('Get_Comp_Requirements: ' || 'x_atp_date > ship_date_this_level. Therefore exit');
11061: END IF;
11062: x_atp_date := null;
11063: EXIT;
11064: END IF;

Line 11076: msc_sch_wb.atp_debug('***** End Get_Comp_Requirements *****');

11072:
11073: END LOOP;
11074:
11075: IF PG_DEBUG in ('Y', 'C') THEN
11076: msc_sch_wb.atp_debug('***** End Get_Comp_Requirements *****');
11077: END IF;
11078:
11079:
11080: Exception

Line 11085: msc_sch_wb.atp_debug('Get_Comp_Reqs: ' || 'Invalid OSS setup detected');

11081:
11082: WHEN MSC_ATP_PVT.INVALID_OSS_SOURCE THEN
11083:
11084: IF PG_DEBUG in ('Y', 'C') THEN
11085: msc_sch_wb.atp_debug('Get_Comp_Reqs: ' || 'Invalid OSS setup detected');
11086: END IF;
11087: x_avail_assembly_qty := 0;
11088: x_atp_date := null;
11089: x_return_status := MSC_ATP_PVT.CTO_OSS_Error;

Line 11094: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for G_ATO_SOURCE');

11090:
11091: -- 2400614 : krajan
11092: WHEN MSC_ATP_PVT.G_ATO_SOURCING_MISMATCH THEN
11093: IF PG_DEBUG in ('Y', 'C') THEN
11094: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for G_ATO_SOURCE');
11095: END IF;
11096: x_return_status := NVL(x_return_status, FND_API.G_RET_STS_ERROR);
11097: RAISE MSC_ATP_PVT.G_ATO_SOURCING_MISMATCH;
11098:

Line 11102: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for EXC_NO_PLAN_FOUND');

11098:
11099: -- dsting 2764213
11100: WHEN MSC_ATP_PVT.EXC_NO_PLAN_FOUND THEN
11101: IF PG_DEBUG in ('Y', 'C') THEN
11102: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for EXC_NO_PLAN_FOUND');
11103: END IF;
11104: x_return_status := NVL(x_return_status, FND_API.G_RET_STS_ERROR);
11105: RAISE MSC_ATP_PVT.EXC_NO_PLAN_FOUND;
11106:

Line 11110: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for G_EXC_UNCOLLECTED_ITEM');

11106:
11107: -- krajan 2752705
11108: WHEN MSC_ATP_PVT.G_EXC_UNCOLLECTED_ITEM THEN
11109: IF PG_DEBUG in ('Y', 'C') THEN
11110: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for G_EXC_UNCOLLECTED_ITEM');
11111: END IF;
11112: x_return_status := NVL(x_return_status, FND_API.G_RET_STS_ERROR);
11113: RAISE MSC_ATP_PVT.G_EXC_UNCOLLECTED_ITEM;
11114:

Line 11118: msc_sch_wb.atp_debug('Get_Comp_Reqs: IN Exception Block for EXC_NO_ATP_RULE');

11114:
11115: ---bug 3308206: Add exception so that it could be propogated to ATP_check
11116: WHEN MSC_ATP_PVT.EXC_NO_ATP_RULE THEN
11117: IF PG_DEBUG in ('Y', 'C') THEN
11118: msc_sch_wb.atp_debug('Get_Comp_Reqs: IN Exception Block for EXC_NO_ATP_RULE');
11119: END IF;
11120: RAISE MSC_ATP_PVT.EXC_NO_ATP_RULE;
11121:
11122: WHEN MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL THEN --bug3583705

Line 11124: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for NO_MATCHING_DATE_IN_CAL');

11120: RAISE MSC_ATP_PVT.EXC_NO_ATP_RULE;
11121:
11122: WHEN MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL THEN --bug3583705
11123: IF PG_DEBUG in ('Y', 'C') THEN
11124: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block for NO_MATCHING_DATE_IN_CAL');
11125: END IF;
11126: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
11127:
11128: WHEN OTHERS THEN

Line 11130: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block in others');

11126: RAISE MSC_ATP_PVT.NO_MATCHING_DATE_IN_CAL;
11127:
11128: WHEN OTHERS THEN
11129: IF PG_DEBUG in ('Y', 'C') THEN
11130: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block in others');
11131: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
11132: END IF;
11133: x_return_status := NVL(x_return_status, FND_API.G_RET_STS_ERROR);
11134: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 11131: msc_sch_wb.atp_debug ('error := ' || SQLERRM);

11127:
11128: WHEN OTHERS THEN
11129: IF PG_DEBUG in ('Y', 'C') THEN
11130: msc_sch_wb.atp_debug ('Get_Comp_Reqs: IN Exception Block in others');
11131: msc_sch_wb.atp_debug ('error := ' || SQLERRM);
11132: END IF;
11133: x_return_status := NVL(x_return_status, FND_API.G_RET_STS_ERROR);
11134: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
11135:

Line 11211: msc_sch_wb.atp_debug('***** Begin Get_Supplier_Atp_Info Procedure *****');

11207:
11208: BEGIN
11209:
11210: IF PG_DEBUG in ('Y', 'C') THEN
11211: msc_sch_wb.atp_debug('***** Begin Get_Supplier_Atp_Info Procedure *****');
11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');
11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));

Line 11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');

11208: BEGIN
11209:
11210: IF PG_DEBUG in ('Y', 'C') THEN
11211: msc_sch_wb.atp_debug('***** Begin Get_Supplier_Atp_Info Procedure *****');
11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');
11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));

Line 11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));

11209:
11210: IF PG_DEBUG in ('Y', 'C') THEN
11211: msc_sch_wb.atp_debug('***** Begin Get_Supplier_Atp_Info Procedure *****');
11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');
11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));

Line 11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));

11210: IF PG_DEBUG in ('Y', 'C') THEN
11211: msc_sch_wb.atp_debug('***** Begin Get_Supplier_Atp_Info Procedure *****');
11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');
11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));

Line 11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));

11211: msc_sch_wb.atp_debug('***** Begin Get_Supplier_Atp_Info Procedure *****');
11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');
11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));

Line 11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));

11212: msc_sch_wb.atp_debug('********** INPUT DATA:Get_Supplier_Atp_Info **********');
11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));

Line 11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));

11213: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inventory_item_id: '|| to_char(p_sup_atp_info_rec.inventory_item_id));
11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));

Line 11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));

11214: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'organization_id: '|| to_char(p_sup_atp_info_rec.organization_id));
11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));

Line 11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));

11215: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'requested_date: '|| to_char(p_sup_atp_info_rec.requested_date));
11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);

Line 11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));

11216: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'instance_id: '|| to_char(p_sup_atp_info_rec.instance_id));
11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);

Line 11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));

11217: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'plan_id: '|| to_char(p_sup_atp_info_rec.plan_id));
11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);
11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);

Line 11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));

11218: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'quantity_ordered: '|| to_char(p_sup_atp_info_rec.quantity_ordered));
11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);
11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);
11226: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'MSC_ATP_PVT.G_PTF_DATE := ' || MSC_ATP_PVT.G_PTF_DATE);

Line 11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);

11219: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'insert_flag: '|| to_char(p_sup_atp_info_rec.insert_flag));
11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);
11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);
11226: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'MSC_ATP_PVT.G_PTF_DATE := ' || MSC_ATP_PVT.G_PTF_DATE);
11227: END IF;

Line 11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);

11220: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_id: '|| to_char(p_sup_atp_info_rec.supplier_id));
11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);
11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);
11226: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'MSC_ATP_PVT.G_PTF_DATE := ' || MSC_ATP_PVT.G_PTF_DATE);
11227: END IF;
11228:

Line 11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);

11221: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'supplier_site_id: '|| to_char(p_sup_atp_info_rec.supplier_site_id));
11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);
11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);
11226: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'MSC_ATP_PVT.G_PTF_DATE := ' || MSC_ATP_PVT.G_PTF_DATE);
11227: END IF;
11228:
11229:

Line 11226: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'MSC_ATP_PVT.G_PTF_DATE := ' || MSC_ATP_PVT.G_PTF_DATE);

11222: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'sup_cap_cum_date: '|| to_char(p_sup_atp_info_rec.sup_cap_cum_date));
11223: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || ' bom_item_type : ' || p_sup_atp_info_rec.bom_item_type);
11224: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rep_ord_flag := ' || p_sup_atp_info_rec.rep_ord_flag);
11225: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'base item id := ' || p_sup_atp_info_rec.base_item_id);
11226: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'MSC_ATP_PVT.G_PTF_DATE := ' || MSC_ATP_PVT.G_PTF_DATE);
11227: END IF;
11228:
11229:
11230: -- initialize API return status to success

Line 11243: msc_sch_wb.atp_debug('G_PURCHASE_ORDER_PREFERENCE := ' || G_PURCHASE_ORDER_PREFERENCE);

11239: l_uom_code := MSC_ATP_PVT.G_ITEM_INFO_REC.uom_code;
11240: l_postprocessing_lead_time := MSC_ATP_PVT.G_ITEM_INFO_REC.pre_pro_lt;
11241:
11242: IF PG_DEBUG in ('Y', 'C') THEN
11243: msc_sch_wb.atp_debug('G_PURCHASE_ORDER_PREFERENCE := ' || G_PURCHASE_ORDER_PREFERENCE);
11244: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_uom_code and l_postprocessing_lead_time = '||
11245: l_uom_code ||' : '||l_postprocessing_lead_time);
11246: END IF;
11247:

Line 11244: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_uom_code and l_postprocessing_lead_time = '||

11240: l_postprocessing_lead_time := MSC_ATP_PVT.G_ITEM_INFO_REC.pre_pro_lt;
11241:
11242: IF PG_DEBUG in ('Y', 'C') THEN
11243: msc_sch_wb.atp_debug('G_PURCHASE_ORDER_PREFERENCE := ' || G_PURCHASE_ORDER_PREFERENCE);
11244: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_uom_code and l_postprocessing_lead_time = '||
11245: l_uom_code ||' : '||l_postprocessing_lead_time);
11246: END IF;
11247:
11248: --s_cto_rearch

Line 11251: msc_sch_wb.atp_debug('ATO item');

11247:
11248: --s_cto_rearch
11249: IF (p_sup_atp_info_rec.bom_item_type = 4 and p_sup_atp_info_rec.rep_ord_flag = 'Y') THEN
11250: IF PG_DEBUG in ('Y', 'C') THEN
11251: msc_sch_wb.atp_debug('ATO item');
11252: END IF;
11253: l_inv_item_id := p_sup_atp_info_rec.base_item_id;
11254: l_check_cap_model_flag := 1;
11255: ELSIF p_sup_atp_info_rec.bom_item_type = 1 THEN

Line 11257: msc_sch_wb.atp_debug('Model entity');

11253: l_inv_item_id := p_sup_atp_info_rec.base_item_id;
11254: l_check_cap_model_flag := 1;
11255: ELSIF p_sup_atp_info_rec.bom_item_type = 1 THEN
11256: IF PG_DEBUG in ('Y', 'C') THEN
11257: msc_sch_wb.atp_debug('Model entity');
11258: END IF;
11259: l_inv_item_id := p_sup_atp_info_rec.inventory_item_id;
11260: l_check_cap_model_flag := 1;
11261:

Line 11265: msc_sch_wb.atp_debug('Category entity: Aggregate Supply');

11261:
11262: --bug 8631827,7592457 - support aggregate capacity check for non-ATO cases also.
11263: ELSIF (p_sup_atp_info_rec.bom_item_type = 4 and p_sup_atp_info_rec.base_item_id is not null) THEN
11264: IF PG_DEBUG in ('Y', 'C') THEN
11265: msc_sch_wb.atp_debug('Category entity: Aggregate Supply');
11266: END IF;
11267: l_inv_item_id := p_sup_atp_info_rec.base_item_id;
11268: l_check_cap_model_flag := 1;
11269: ELSE

Line 11271: msc_sch_wb.atp_debug('Standard Item');

11267: l_inv_item_id := p_sup_atp_info_rec.base_item_id;
11268: l_check_cap_model_flag := 1;
11269: ELSE
11270: IF PG_DEBUG in ('Y', 'C') THEN
11271: msc_sch_wb.atp_debug('Standard Item');
11272: END IF;
11273: l_inv_item_id := p_sup_atp_info_rec.inventory_item_id;
11274: END IF;
11275: --e_cto_rearch

Line 11277: msc_sch_wb.atp_debug('l_inv_item_id := ' || l_inv_item_id);

11273: l_inv_item_id := p_sup_atp_info_rec.inventory_item_id;
11274: END IF;
11275: --e_cto_rearch
11276: IF PG_DEBUG in ('Y', 'C') THEN
11277: msc_sch_wb.atp_debug('l_inv_item_id := ' || l_inv_item_id);
11278: END IF;
11279:
11280:
11281: -- bug 1169467

Line 11321: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date = '||l_plan_start_date);

11317: only for unconstrained plans or if the plan option to enforce capacity was enforced. Now this is not required
11318: as capacity is always enforced. */
11319:
11320: IF PG_DEBUG in ('Y', 'C') THEN
11321: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date = '||l_plan_start_date);
11322: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_instance_id = '||l_instance_id);
11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);
11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||

Line 11322: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_instance_id = '||l_instance_id);

11318: as capacity is always enforced. */
11319:
11320: IF PG_DEBUG in ('Y', 'C') THEN
11321: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date = '||l_plan_start_date);
11322: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_instance_id = '||l_instance_id);
11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);
11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||
11326: l_default_atp_rule_id);

Line 11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);

11319:
11320: IF PG_DEBUG in ('Y', 'C') THEN
11321: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date = '||l_plan_start_date);
11322: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_instance_id = '||l_instance_id);
11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);
11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||
11326: l_default_atp_rule_id);
11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);

Line 11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);

11320: IF PG_DEBUG in ('Y', 'C') THEN
11321: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date = '||l_plan_start_date);
11322: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_instance_id = '||l_instance_id);
11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);
11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||
11326: l_default_atp_rule_id);
11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
11328: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_exception_set_id'||

Line 11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||

11321: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date = '||l_plan_start_date);
11322: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_instance_id = '||l_instance_id);
11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);
11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||
11326: l_default_atp_rule_id);
11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
11328: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_exception_set_id'||
11329: l_calendar_exception_set_id);

Line 11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);

11323: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_org_id = '||l_org_id);
11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||
11326: l_default_atp_rule_id);
11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
11328: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_exception_set_id'||
11329: l_calendar_exception_set_id);
11330: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_demand_class'||
11331: l_default_demand_class);

Line 11328: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_exception_set_id'||

11324: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_cutoff_date = '||l_cutoff_date);
11325: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_atp_rule_id='||
11326: l_default_atp_rule_id);
11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
11328: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_exception_set_id'||
11329: l_calendar_exception_set_id);
11330: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_demand_class'||
11331: l_default_demand_class);
11332: END IF;

Line 11330: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_demand_class'||

11326: l_default_atp_rule_id);
11327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_code='||l_calendar_code);
11328: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_calendar_exception_set_id'||
11329: l_calendar_exception_set_id);
11330: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_default_demand_class'||
11331: l_default_demand_class);
11332: END IF;
11333:
11334: /* Enforce Pur LT - capacity is always enforced.

Line 11354: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_last_cap_next_date='||

11350: END IF;
11351: /* Enforce Pur LT changes end */
11352:
11353: IF PG_DEBUG in ('Y', 'C') THEN
11354: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_last_cap_next_date='||
11355: l_last_cap_next_date);
11356: END IF;
11357:
11358: IF l_capacity_defined = 0 THEN

Line 11368: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date := ' || l_plan_start_date);

11364: l_atp_period_tab.EXTEND;
11365: l_atp_qty_tab.EXTEND;
11366: i:= l_atp_period_tab.COUNT;
11367: IF PG_DEBUG in ('Y', 'C') THEN
11368: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date := ' || l_plan_start_date);
11369: END IF;
11370:
11371: -- Ship_rec_cal.
11372: l_atp_period_tab(i) := l_last_cap_next_date;

Line 11470: msc_sch_wb.atp_debug('l_calendar_code := ' || l_calendar_code);

11466: AND tp.partner_type = 3
11467: AND tp.sr_tp_id = mp.organization_id;
11468: END IF;
11469:
11470: msc_sch_wb.atp_debug('l_calendar_code := ' || l_calendar_code);
11471: --=======================================================================================================
11472: -- ship_rec_cal changes begin
11473: --=======================================================================================================
11474: -- In all the SQLs that get supplier capacities following are the changes:

Line 11501: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_summary_flag := ' || l_summary_flag);

11497: FROM msc_plans plans
11498: WHERE plans.plan_id = p_sup_atp_info_rec.plan_id;
11499:
11500: IF PG_DEBUG in ('Y', 'C') THEN
11501: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_summary_flag := ' || l_summary_flag);
11502: END IF;
11503:
11504: IF l_summary_flag NOT IN (MSC_POST_PRO.G_SF_SUMMARY_NOT_RUN, MSC_POST_PRO.G_SF_PREALLOC_COMPLETED,
11505: MSC_POST_PRO.G_SF_FULL_SUMMARY_RUNNING) THEN

Line 11517: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Summary mode supplier info');

11513: END IF;
11514:
11515: IF l_summary_sql = 'Y' THEN
11516: IF PG_DEBUG in ('Y', 'C') THEN
11517: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Summary mode supplier info');
11518: END IF;
11519:
11520: IF l_check_cap_model_flag = 1 THEN
11521:

Line 11644: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');

11640: /* Cum drop issue changes begin*/
11641: MSC_AATP_PROC.Atp_Remove_Negatives(l_atp_qty_tab, l_return_status);
11642: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
11643: IF PG_DEBUG in ('Y', 'C') THEN
11644: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');
11645: END IF;
11646: RAISE FND_API.G_EXC_ERROR;
11647: END IF;
11648: /* Cum drop issue changes end*/

Line 11653: msc_sch_wb.atp_debug('Check Sources for model, details are off');

11649:
11650: ELSE -- IF l_summary_sql = 'Y' THEN
11651:
11652: IF l_check_cap_model_flag = 1 THEN
11653: msc_sch_wb.atp_debug('Check Sources for model, details are off');
11654:
11655: SELECT trunc(l_date), SUM(quantity) --4135752
11656: BULK COLLECT INTO
11657: l_atp_period_tab,

Line 11733: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');

11729: /* Cum drop issue changes begin*/
11730: MSC_AATP_PROC.Atp_Remove_Negatives(l_atp_qty_tab, l_return_status);
11731: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
11732: IF PG_DEBUG in ('Y', 'C') THEN
11733: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');
11734: END IF;
11735: RAISE FND_API.G_EXC_ERROR;
11736: END IF;
11737: /* Cum drop issue changes end*/

Line 11810: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');

11806: /* Cum drop issue changes begin*/
11807: MSC_AATP_PROC.Atp_Remove_Negatives(l_atp_qty_tab, l_return_status);
11808: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
11809: IF PG_DEBUG in ('Y', 'C') THEN
11810: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');
11811: END IF;
11812: RAISE FND_API.G_EXC_ERROR;
11813: END IF;
11814: /* Cum drop issue changes end*/

Line 11825: msc_sch_wb.atp_debug('Check Sources for model, details are on');

11821:
11822: MSC_ATP_DB_UTILS.Clear_SD_Details_temp();
11823:
11824: IF l_check_cap_model_flag = 1 THEN
11825: msc_sch_wb.atp_debug('Check Sources for model, details are on');
11826: INSERT INTO msc_atp_sd_details_temp (
11827: ATP_level,
11828: Order_line_id,
11829: Scenario_Id,

Line 12162: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'after inserting into msc_atp_sd_details_temp');

12158: END IF; -- IF l_check_cap_model_flag = 1 THEN
12159:
12160: -- for period ATP
12161: IF PG_DEBUG in ('Y', 'C') THEN
12162: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'after inserting into msc_atp_sd_details_temp');
12163: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rows processed: ' || SQL%ROWCOUNT);
12164: END IF;
12165:
12166: MSC_ATP_PROC.get_period_data_from_SD_temp(x_atp_period);

Line 12163: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rows processed: ' || SQL%ROWCOUNT);

12159:
12160: -- for period ATP
12161: IF PG_DEBUG in ('Y', 'C') THEN
12162: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'after inserting into msc_atp_sd_details_temp');
12163: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'rows processed: ' || SQL%ROWCOUNT);
12164: END IF;
12165:
12166: MSC_ATP_PROC.get_period_data_from_SD_temp(x_atp_period);
12167:

Line 12170: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'before atp_consume');

12166: MSC_ATP_PROC.get_period_data_from_SD_temp(x_atp_period);
12167:
12168: x_atp_period.Cumulative_Quantity := x_atp_period.Period_Quantity;
12169: IF PG_DEBUG in ('Y', 'C') THEN
12170: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'before atp_consume');
12171: END IF;
12172: -- do the accumulation
12173: -- 1487804
12174: -- atp_consume(x_atp_period.Cumulative_Quantity, m);

Line 12179: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'after atp_consume');

12175: MSC_ATP_PROC.atp_consume(x_atp_period.Cumulative_Quantity,
12176: x_atp_period.Cumulative_Quantity.COUNT);
12177:
12178: IF PG_DEBUG in ('Y', 'C') THEN
12179: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'after atp_consume');
12180: END IF;
12181:
12182: /* Cum drop issue changes begin*/
12183: MSC_AATP_PROC.Atp_Remove_Negatives(x_atp_period.Cumulative_Quantity, l_return_status);

Line 12186: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');

12182: /* Cum drop issue changes begin*/
12183: MSC_AATP_PROC.Atp_Remove_Negatives(x_atp_period.Cumulative_Quantity, l_return_status);
12184: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
12185: IF PG_DEBUG in ('Y', 'C') THEN
12186: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Error occured in procedure Atp_Remove_Negatives');
12187: END IF;
12188: RAISE FND_API.G_EXC_ERROR;
12189: END IF;
12190: /* Cum drop issue changes end*/

Line 12204: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date := ' || l_plan_start_date);

12200: l_atp_period_tab.EXTEND;
12201: l_atp_qty_tab.EXTEND;
12202: i:= l_atp_period_tab.COUNT;
12203: IF PG_DEBUG in ('Y', 'C') THEN
12204: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date := ' || l_plan_start_date);
12205: END IF;
12206:
12207: -- ship_rec_cal
12208: l_atp_period_tab(i) := l_last_cap_next_date;

Line 12212: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date1 := ' || l_plan_start_date);

12208: l_atp_period_tab(i) := l_last_cap_next_date;
12209: l_atp_qty_tab(i) := MSC_ATP_PVT.INFINITE_NUMBER;
12210:
12211: IF PG_DEBUG in ('Y', 'C') THEN
12212: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date1 := ' || l_plan_start_date);
12213: END IF;
12214:
12215: IF (NVL(p_sup_atp_info_rec.insert_flag, 0) <> 0) THEN
12216:

Line 12319: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_last_cap_date := ' || l_last_cap_date);

12315: Done with Enforce Pur LT changes
12316: --sup_cap chnages
12317: --first get the next working from the last day on which capacity is defined.
12318: IF PG_DEBUG in ('Y', 'C') THEN
12319: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_last_cap_date := ' || l_last_cap_date);
12320: END IF;
12321: l_last_cap_date := MSC_CALENDAR.DATE_OFFSET(p_sup_atp_info_rec.organization_id,
12322: p_sup_atp_info_rec.instance_id,
12323: 1,

Line 12327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_last_cap_date after offset := ' || l_last_cap_date);

12323: 1,
12324: l_last_cap_date,
12325: 1);
12326: IF PG_DEBUG in ('Y', 'C') THEN
12327: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_last_cap_date after offset := ' || l_last_cap_date);
12328: END IF;
12329: */
12330:
12331: -- add one more entry to indicate sysdate

Line 12340: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date := ' || l_plan_start_date);

12336: l_atp_period_tab.EXTEND;
12337: l_atp_qty_tab.EXTEND;
12338: i:= l_atp_period_tab.COUNT;
12339: IF PG_DEBUG in ('Y', 'C') THEN
12340: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_plan_start_date := ' || l_plan_start_date);
12341: END IF;
12342:
12343: -- ship_rec_cal
12344: l_atp_period_tab(i) := l_last_cap_next_date;

Line 12382: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'No rows in cursor!!!');

12378:
12379: IF i = 0 THEN
12380: -- need to add error message
12381: IF PG_DEBUG in ('Y', 'C') THEN
12382: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'No rows in cursor!!!');
12383: END IF;
12384: RAISE NO_DATA_FOUND;
12385: END IF;
12386:

Line 12389: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Date '||l_atp_period_tab(i)||' Qty '||

12385: END IF;
12386:
12387: FOR i in 1..l_atp_period_tab.COUNT LOOP
12388: IF PG_DEBUG in ('Y', 'C') THEN
12389: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'Date '||l_atp_period_tab(i)||' Qty '||
12390: l_atp_qty_tab(i));
12391: END IF;
12392: END LOOP;
12393:

Line 12413: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_qty_before_sysdate := ' || l_qty_before_sysdate);

12409: END IF;
12410: l_qty_before_sysdate := GREATEST(l_qty_before_sysdate, 0);
12411:
12412: IF PG_DEBUG in ('Y', 'C') THEN
12413: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_qty_before_sysdate := ' || l_qty_before_sysdate);
12414: END IF;
12415:
12416:
12417: -- we use this l_atp_requested_date to do the search

Line 12421: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_atp_requested_date := ' || l_atp_requested_date);

12417: -- we use this l_atp_requested_date to do the search
12418: l_atp_requested_date := GREATEST(l_requested_date, l_sysdate); -- Change for ship_rec_cal
12419:
12420: IF PG_DEBUG in ('Y', 'C') THEN
12421: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'l_atp_requested_date := ' || l_atp_requested_date);
12422: END IF;
12423:
12424: IF (l_atp_requested_date < l_atp_period_tab(1)) THEN
12425: -- let say the first period is on Day5 but your

Line 12475: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inside p_sup_atp_info_rec.requested_date_quantity 0 = '||

12471: -- l_requested_date < GREATEST(MSC_ATP_PVT.G_PTF_DATE,l_atp_requested_date)) THEN -- Bug 3782472 - Added PTF check
12472: p_sup_atp_info_rec.requested_date_quantity := 0;
12473:
12474: IF PG_DEBUG in ('Y', 'C') THEN
12475: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'inside p_sup_atp_info_rec.requested_date_quantity 0 = '||
12476: p_sup_atp_info_rec.requested_date_quantity);
12477: END IF;
12478: ELSE
12479: ---bug 2341075: availability should not include what is available before sysdate

Line 12485: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.requested_date_quantity: '|| to_char(p_sup_atp_info_rec.requested_date_quantity));

12481: END IF;
12482:
12483:
12484: IF PG_DEBUG in ('Y', 'C') THEN
12485: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.requested_date_quantity: '|| to_char(p_sup_atp_info_rec.requested_date_quantity));
12486: END IF;
12487: -- now find the atp_date_quantity and atp_date at this level
12488: ---bug 2341075: Cum Qty should not include cum qty before sysdate
12489: IF (l_atp_qty_tab(j) - l_qty_before_sysdate) >= p_sup_atp_info_rec.quantity_ordered

Line 12496: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.atp_date_this_level: '|| to_char(p_sup_atp_info_rec.atp_date_this_level));

12492: p_sup_atp_info_rec.atp_date_quantity_this_level := l_atp_qty_tab(j) - l_qty_before_sysdate;
12493: p_sup_atp_info_rec.atp_date_this_level := l_atp_requested_date;
12494:
12495: IF PG_DEBUG in ('Y', 'C') THEN
12496: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.atp_date_this_level: '|| to_char(p_sup_atp_info_rec.atp_date_this_level));
12497: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.atp_date_quantity_this_level: '|| to_char(p_sup_atp_info_rec.atp_date_quantity_this_level));
12498: END IF;
12499:
12500: ELSE

Line 12497: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.atp_date_quantity_this_level: '|| to_char(p_sup_atp_info_rec.atp_date_quantity_this_level));

12493: p_sup_atp_info_rec.atp_date_this_level := l_atp_requested_date;
12494:
12495: IF PG_DEBUG in ('Y', 'C') THEN
12496: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.atp_date_this_level: '|| to_char(p_sup_atp_info_rec.atp_date_this_level));
12497: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'p_sup_atp_info_rec.atp_date_quantity_this_level: '|| to_char(p_sup_atp_info_rec.atp_date_quantity_this_level));
12498: END IF;
12499:
12500: ELSE
12501: IF j = l_atp_period_tab.COUNT THEN

Line 12531: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'in supplier, count = '||x_atp_supply_demand.supplier_id.count);

12527: END LOOP; -- end j loop
12528: END IF;
12529:
12530: IF PG_DEBUG in ('Y', 'C') THEN
12531: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'in supplier, count = '||x_atp_supply_demand.supplier_id.count);
12532: msc_sch_wb.atp_debug('***** End Get_Supplier_Atp_Info Procedure *****');
12533: END IF;
12534:
12535: EXCEPTION

Line 12532: msc_sch_wb.atp_debug('***** End Get_Supplier_Atp_Info Procedure *****');

12528: END IF;
12529:
12530: IF PG_DEBUG in ('Y', 'C') THEN
12531: msc_sch_wb.atp_debug('Get_Supplier_Atp_Info: ' || 'in supplier, count = '||x_atp_supply_demand.supplier_id.count);
12532: msc_sch_wb.atp_debug('***** End Get_Supplier_Atp_Info Procedure *****');
12533: END IF;
12534:
12535: EXCEPTION
12536:

Line 12596: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'inside get_TRANSPORT_info ');

12592:
12593: BEGIN
12594:
12595: IF PG_DEBUG in ('Y', 'C') THEN
12596: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'inside get_TRANSPORT_info ');
12597: END IF;
12598:
12599: l_null_atp_period := x_atp_period;
12600: l_null_atp_supply_demand := x_atp_supply_demand;

Line 12603: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'p_insert_flag = '||p_insert_flag);

12599: l_null_atp_period := x_atp_period;
12600: l_null_atp_supply_demand := x_atp_supply_demand;
12601:
12602: IF PG_DEBUG in ('Y', 'C') THEN
12603: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'p_insert_flag = '||p_insert_flag);
12604: END IF;
12605:
12606: -- initialize API return status to success
12607: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 12632: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the unit weight is: '||to_char(l_unit_weight));

12628: AND inventory_item_id = p_inventory_item_id
12629: AND sr_instance_id = p_dest_org_instance_id;
12630:
12631: IF PG_DEBUG in ('Y', 'C') THEN
12632: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the unit weight is: '||to_char(l_unit_weight));
12633: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the unit volume is: '||to_char(l_unit_volume));
12634: END IF;
12635:
12636: SELECT l_date, SUM(weight), SUM(volume)

Line 12633: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the unit volume is: '||to_char(l_unit_volume));

12629: AND sr_instance_id = p_dest_org_instance_id;
12630:
12631: IF PG_DEBUG in ('Y', 'C') THEN
12632: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the unit weight is: '||to_char(l_unit_weight));
12633: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the unit volume is: '||to_char(l_unit_volume));
12634: END IF;
12635:
12636: SELECT l_date, SUM(weight), SUM(volume)
12637: BULK COLLECT INTO

Line 12688: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'No rows in cursor!!!');

12684:
12685: IF i = 0 THEN
12686: -- need to add error message
12687: IF PG_DEBUG in ('Y', 'C') THEN
12688: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'No rows in cursor!!!');
12689: END IF;
12690: RAISE NO_DATA_FOUND;
12691: END IF;
12692:

Line 12698: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'just before printing values');

12694: MSC_ATP_PROC.atp_consume(l_atp_qty_tab, i);
12695: MSC_ATP_PROC.atp_consume(l_atp_qty_tab2, i);
12696:
12697: IF PG_DEBUG in ('Y', 'C') THEN
12698: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'just before printing values');
12699: END IF;
12700:
12701: FOR k IN 1..i LOOP
12702: IF PG_DEBUG in ('Y', 'C') THEN

Line 12703: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date is: '||to_char(l_atp_period_tab(k)));

12699: END IF;
12700:
12701: FOR k IN 1..i LOOP
12702: IF PG_DEBUG in ('Y', 'C') THEN
12703: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date is: '||to_char(l_atp_period_tab(k)));
12704: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'weight is: '||to_char(l_atp_qty_tab(k)));
12705: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'volume is: '||to_char(l_atp_qty_tab2(k)));
12706: END IF;
12707:

Line 12704: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'weight is: '||to_char(l_atp_qty_tab(k)));

12700:
12701: FOR k IN 1..i LOOP
12702: IF PG_DEBUG in ('Y', 'C') THEN
12703: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date is: '||to_char(l_atp_period_tab(k)));
12704: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'weight is: '||to_char(l_atp_qty_tab(k)));
12705: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'volume is: '||to_char(l_atp_qty_tab2(k)));
12706: END IF;
12707:
12708: END LOOP;

Line 12705: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'volume is: '||to_char(l_atp_qty_tab2(k)));

12701: FOR k IN 1..i LOOP
12702: IF PG_DEBUG in ('Y', 'C') THEN
12703: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date is: '||to_char(l_atp_period_tab(k)));
12704: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'weight is: '||to_char(l_atp_qty_tab(k)));
12705: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'volume is: '||to_char(l_atp_qty_tab2(k)));
12706: END IF;
12707:
12708: END LOOP;
12709:

Line 12732: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the date is: '||to_char(l_atp_period_tab(j)));

12728: x_requested_date_quantity := l_item_volume_qty;
12729: END IF;
12730:
12731: IF PG_DEBUG in ('Y', 'C') THEN
12732: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the date is: '||to_char(l_atp_period_tab(j)));
12733: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the quantity is: '||to_char(x_requested_date_quantity));
12734: END IF;
12735:
12736: -- now find the atp_date_quantity and atp_date at this level

Line 12733: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the quantity is: '||to_char(x_requested_date_quantity));

12729: END IF;
12730:
12731: IF PG_DEBUG in ('Y', 'C') THEN
12732: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the date is: '||to_char(l_atp_period_tab(j)));
12733: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'the quantity is: '||to_char(x_requested_date_quantity));
12734: END IF;
12735:
12736: -- now find the atp_date_quantity and atp_date at this level
12737: IF x_requested_date_quantity >= p_quantity_ordered THEN

Line 12744: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity is enough.');

12740: l_atp_date_weight := l_atp_qty_tab(j);
12741: l_atp_date_volume := l_atp_qty_tab2(j);
12742:
12743: IF PG_DEBUG in ('Y', 'C') THEN
12744: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity is enough.');
12745: END IF;
12746:
12747: k := j;
12748: ELSE

Line 12751: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity is not enough.');

12747: k := j;
12748: ELSE
12749:
12750: IF PG_DEBUG in ('Y', 'C') THEN
12751: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity is not enough.');
12752: END IF;
12753:
12754: FOR k IN j+1..i LOOP
12755: -- Convert volume and weight capacity in units

Line 12767: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'Date is: '||to_char(l_atp_period_tab(k)));

12763: l_available_quantity := l_item_volume_qty;
12764: END IF;
12765:
12766: IF PG_DEBUG in ('Y', 'C') THEN
12767: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'Date is: '||to_char(l_atp_period_tab(k)));
12768: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'Quantity available is: '||to_char(l_available_quantity));
12769: END IF;
12770:
12771: IF (l_available_quantity >= p_quantity_ordered) THEN

Line 12768: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'Quantity available is: '||to_char(l_available_quantity));

12764: END IF;
12765:
12766: IF PG_DEBUG in ('Y', 'C') THEN
12767: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'Date is: '||to_char(l_atp_period_tab(k)));
12768: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'Quantity available is: '||to_char(l_available_quantity));
12769: END IF;
12770:
12771: IF (l_available_quantity >= p_quantity_ordered) THEN
12772: x_atp_date_quantity_this_level := l_available_quantity;

Line 12779: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'done');

12775: l_atp_date_weight := l_atp_qty_tab(k);
12776: l_atp_date_volume := l_atp_qty_tab2(k);
12777:
12778: IF PG_DEBUG in ('Y', 'C') THEN
12779: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'done');
12780: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity: '||to_char(x_atp_date_quantity_this_level));
12781: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date: '||to_char(x_atp_date_this_level));
12782: END IF;
12783: END IF;

Line 12780: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity: '||to_char(x_atp_date_quantity_this_level));

12776: l_atp_date_volume := l_atp_qty_tab2(k);
12777:
12778: IF PG_DEBUG in ('Y', 'C') THEN
12779: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'done');
12780: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity: '||to_char(x_atp_date_quantity_this_level));
12781: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date: '||to_char(x_atp_date_this_level));
12782: END IF;
12783: END IF;
12784: END LOOP;

Line 12781: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date: '||to_char(x_atp_date_this_level));

12777:
12778: IF PG_DEBUG in ('Y', 'C') THEN
12779: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'done');
12780: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'quantity: '||to_char(x_atp_date_quantity_this_level));
12781: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'date: '||to_char(x_atp_date_this_level));
12782: END IF;
12783: END IF;
12784: END LOOP;
12785: END IF;

Line 12936: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'in get_res_requirements we are here 2');

12932:
12933: END LOOP;
12934:
12935: IF PG_DEBUG in ('Y', 'C') THEN
12936: msc_sch_wb.atp_debug('Get_Transport_Cap_Atp_Info: ' || 'in get_res_requirements we are here 2');
12937: END IF;
12938:
12939: FOR i in 1..l_atp_supply_demand.Level.COUNT LOOP
12940: l_atp_supply_demand.Pegging_Id(i) := l_pegging_id;

Line 13560: msc_sch_wb.atp_debug('Add_To_Comp_List: Enter Into Add_To_Comp_List');

13556: j number;
13557: BEGIN
13558:
13559: IF PG_DEBUG in ('Y', 'C') THEN
13560: msc_sch_wb.atp_debug('Add_To_Comp_List: Enter Into Add_To_Comp_List');
13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );
13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );

Line 13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );

13557: BEGIN
13558:
13559: IF PG_DEBUG in ('Y', 'C') THEN
13560: msc_sch_wb.atp_debug('Add_To_Comp_List: Enter Into Add_To_Comp_List');
13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );
13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );

Line 13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );

13558:
13559: IF PG_DEBUG in ('Y', 'C') THEN
13560: msc_sch_wb.atp_debug('Add_To_Comp_List: Enter Into Add_To_Comp_List');
13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );
13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );

Line 13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );

13559: IF PG_DEBUG in ('Y', 'C') THEN
13560: msc_sch_wb.atp_debug('Add_To_Comp_List: Enter Into Add_To_Comp_List');
13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );
13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );

Line 13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );

13560: msc_sch_wb.atp_debug('Add_To_Comp_List: Enter Into Add_To_Comp_List');
13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );
13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );

Line 13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );

13561: msc_sch_wb.atp_debug('Add_To_Comp_List: inventory_item_id := ' || p_atp_comp_rec.inventory_item_id );
13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );

Line 13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );

13562: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_usage := ' || p_atp_comp_rec.comp_usage );
13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);

Line 13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );

13563: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_date := ' || p_atp_comp_rec.requested_date );
13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );

Line 13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );

13564: msc_sch_wb.atp_debug('Add_To_Comp_List: lead_time := ' || p_atp_comp_rec.lead_time );
13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );

Line 13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );

13565: msc_sch_wb.atp_debug('Add_To_Comp_List: wip_supply_type := ' || p_atp_comp_rec.wip_supply_type );
13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );

Line 13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);

13566: msc_sch_wb.atp_debug('Add_To_Comp_List: assembly_identifier := ' || p_atp_comp_rec.assembly_identifier );
13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );

Line 13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );

13567: msc_sch_wb.atp_debug('Add_To_Comp_List: component_identifier := ' || p_atp_comp_rec.component_identifier );
13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );

Line 13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );

13568: msc_sch_wb.atp_debug('Add_To_Comp_List: reverse_cumulative_yield := ' || p_atp_comp_rec.reverse_cumulative_yield );
13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );

Line 13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );

13569: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_id:= ' || p_atp_comp_rec.match_item_id );
13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );

Line 13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );

13570: msc_sch_wb.atp_debug('Add_To_Comp_List: match_item_family_id := ' || p_atp_comp_rec.match_item_family_id);
13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );

Line 13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );

13571: msc_sch_wb.atp_debug('Add_To_Comp_List: bom_item_type := ' || p_atp_comp_rec.bom_item_type );
13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );

Line 13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );

13572: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_line_id := ' || p_atp_comp_rec.parent_line_id );
13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );

Line 13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );

13573: msc_sch_wb.atp_debug('Add_To_Comp_List: top_model_line_id := ' || p_atp_comp_rec.top_model_line_id );
13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );

Line 13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );

13574: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_parent_model_line_id := ' || p_atp_comp_rec.ato_parent_model_line_id );
13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );

Line 13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );

13575: msc_sch_wb.atp_debug('Add_To_Comp_List: ato_model_line_id := ' || p_atp_comp_rec.ato_model_line_id );
13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);

Line 13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );

13576: msc_sch_wb.atp_debug('Add_To_Comp_List: MAND_COMP_FLAG := ' || p_atp_comp_rec.MAND_COMP_FLAG );
13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);

Line 13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );

13577: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_so_quantity := ' || p_atp_comp_rec.parent_so_quantity );
13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);

Line 13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );

13578: msc_sch_wb.atp_debug('Add_To_Comp_List: fixed_lt := ' || p_atp_comp_rec.fixed_lt );
13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);

Line 13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);

13579: msc_sch_wb.atp_debug('Add_To_Comp_List: variable_lt := ' || p_atp_comp_rec.variable_lt );
13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);
13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);

Line 13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);

13580: msc_sch_wb.atp_debug('Add_To_Comp_List: oss_error_code := ' || p_atp_comp_rec.oss_error_code );
13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);
13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);
13588: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_uom := ' || p_atp_comp_rec.comp_uom); --bug3110023

Line 13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);

13581: msc_sch_wb.atp_debug('Add_To_Comp_List: model_flag := ' || p_atp_comp_rec.model_flag );
13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);
13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);
13588: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_uom := ' || p_atp_comp_rec.comp_uom); --bug3110023
13589:

Line 13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);

13582: msc_sch_wb.atp_debug('Add_To_Comp_List: requested_quantity := ' || p_atp_comp_rec.requested_quantity );
13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);
13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);
13588: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_uom := ' || p_atp_comp_rec.comp_uom); --bug3110023
13589:
13590: END IF;

Line 13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);

13583: msc_sch_wb.atp_debug('Add_To_Comp_List: atp flag := ' || p_atp_comp_rec.atp_flag);
13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);
13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);
13588: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_uom := ' || p_atp_comp_rec.comp_uom); --bug3110023
13589:
13590: END IF;
13591:

Line 13588: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_uom := ' || p_atp_comp_rec.comp_uom); --bug3110023

13584: msc_sch_wb.atp_debug('Add_To_Comp_List: atp_comp_flag := '|| p_atp_comp_rec.atp_components_flag);
13585: msc_sch_wb.atp_debug('Add_To_Comp_List: atf_date := '|| p_atp_comp_rec.atf_date);
13586: msc_sch_wb.atp_debug('Add_To_Comp_List: dest_inventory_item_id := ' || p_atp_comp_rec.dest_inventory_item_id);
13587: msc_sch_wb.atp_debug('Add_To_Comp_List: parent_repl_ord_flag := ' || p_atp_comp_rec.parent_repl_ord_flag);
13588: msc_sch_wb.atp_debug('Add_To_Comp_List: comp_uom := ' || p_atp_comp_rec.comp_uom); --bug3110023
13589:
13590: END IF;
13591:
13592: IF ((p_atp_comp_rec.model_flag = 1 and p_atp_comp_rec.bom_item_type = 2) or

Line 13604: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'in side phantom, count = '||j);

13600: -- bug 1831563: removed the extend and assign to
13601: -- l_explode_comp.pre_process_lead_time since it is not needed.
13602:
13603: IF PG_DEBUG in ('Y', 'C') THEN
13604: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'in side phantom, count = '||j);
13605: msc_sch_wb.atp_debug('Add_To_Comp_List: Count in explode comp := ' || p_explode_comp_rec.inventory_item_id.count);
13606: END IF;
13607:
13608: MSC_ATP_REQ.Extend_ATP_Comp_TYP(p_explode_comp_rec);

Line 13605: msc_sch_wb.atp_debug('Add_To_Comp_List: Count in explode comp := ' || p_explode_comp_rec.inventory_item_id.count);

13601: -- l_explode_comp.pre_process_lead_time since it is not needed.
13602:
13603: IF PG_DEBUG in ('Y', 'C') THEN
13604: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'in side phantom, count = '||j);
13605: msc_sch_wb.atp_debug('Add_To_Comp_List: Count in explode comp := ' || p_explode_comp_rec.inventory_item_id.count);
13606: END IF;
13607:
13608: MSC_ATP_REQ.Extend_ATP_Comp_TYP(p_explode_comp_rec);
13609:

Line 13611: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'after extend');

13607:
13608: MSC_ATP_REQ.Extend_ATP_Comp_TYP(p_explode_comp_rec);
13609:
13610: IF PG_DEBUG in ('Y', 'C') THEN
13611: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'after extend');
13612: END IF;
13613:
13614: p_explode_comp_rec.inventory_item_id(j+1):= p_atp_comp_rec.inventory_item_id;
13615: /* time_phased_atp changes begin

Line 13650: msc_sch_wb.atp_debug('Add_To_Comp_List: explode lead_time := ' || p_explode_comp_rec.lead_time(j+1));

13646: p_explode_comp_rec.atp_components_flag(j +1 ) := p_atp_comp_rec.atp_components_flag;
13647: p_explode_comp_rec.dest_inventory_item_id(j +1) := p_atp_comp_rec.dest_inventory_item_id;
13648: p_explode_comp_rec.comp_uom(j +1) := p_atp_comp_rec.comp_uom; --bug3110023
13649: IF PG_DEBUG in ('Y', 'C') THEN
13650: msc_sch_wb.atp_debug('Add_To_Comp_List: explode lead_time := ' || p_explode_comp_rec.lead_time(j+1));
13651: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'after assign ');
13652: END IF;
13653: END IF;
13654:

Line 13651: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'after assign ');

13647: p_explode_comp_rec.dest_inventory_item_id(j +1) := p_atp_comp_rec.dest_inventory_item_id;
13648: p_explode_comp_rec.comp_uom(j +1) := p_atp_comp_rec.comp_uom; --bug3110023
13649: IF PG_DEBUG in ('Y', 'C') THEN
13650: msc_sch_wb.atp_debug('Add_To_Comp_List: explode lead_time := ' || p_explode_comp_rec.lead_time(j+1));
13651: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'after assign ');
13652: END IF;
13653: END IF;
13654:
13655: IF p_atp_comp_rec.wip_supply_type <> 6 or

Line 13663: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'not phantom, j='||j);

13659:
13660: j := p_component_rec.inventory_item_id.COUNT;
13661:
13662: IF PG_DEBUG in ('Y', 'C') THEN
13663: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'not phantom, j='||j);
13664: END IF;
13665:
13666: MSC_ATP_REQ.Extend_ATP_Comp_TYP(p_component_rec);
13667:

Line 13685: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.comp_usage ' || p_atp_comp_rec.comp_usage);

13681: ELSE
13682: p_component_rec.comp_usage(j+1) := p_atp_comp_rec.comp_usage;
13683: END IF;
13684: IF PG_DEBUG in ('Y', 'C') THEN
13685: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.comp_usage ' || p_atp_comp_rec.comp_usage);
13686: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.requested_quantity ' || p_atp_comp_rec.requested_quantity);
13687: msc_sch_wb.atp_debug('Add_To_Comp_List: p_component_rec.comp_usage(j+1) ' || p_component_rec.comp_usage(j+1));
13688: END IF;
13689:

Line 13686: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.requested_quantity ' || p_atp_comp_rec.requested_quantity);

13682: p_component_rec.comp_usage(j+1) := p_atp_comp_rec.comp_usage;
13683: END IF;
13684: IF PG_DEBUG in ('Y', 'C') THEN
13685: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.comp_usage ' || p_atp_comp_rec.comp_usage);
13686: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.requested_quantity ' || p_atp_comp_rec.requested_quantity);
13687: msc_sch_wb.atp_debug('Add_To_Comp_List: p_component_rec.comp_usage(j+1) ' || p_component_rec.comp_usage(j+1));
13688: END IF;
13689:
13690: --4570421

Line 13687: msc_sch_wb.atp_debug('Add_To_Comp_List: p_component_rec.comp_usage(j+1) ' || p_component_rec.comp_usage(j+1));

13683: END IF;
13684: IF PG_DEBUG in ('Y', 'C') THEN
13685: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.comp_usage ' || p_atp_comp_rec.comp_usage);
13686: msc_sch_wb.atp_debug('Add_To_Comp_List: p_atp_comp_rec.requested_quantity ' || p_atp_comp_rec.requested_quantity);
13687: msc_sch_wb.atp_debug('Add_To_Comp_List: p_component_rec.comp_usage(j+1) ' || p_component_rec.comp_usage(j+1));
13688: END IF;
13689:
13690: --4570421
13691: p_component_rec.scaling_type(j+1) := p_atp_comp_rec.scaling_type;

Line 13727: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'in side not phantom');

13723: p_component_rec.comp_uom(j + 1) := p_atp_comp_rec.comp_uom; --bug3110023
13724:
13725:
13726: IF PG_DEBUG in ('Y', 'C') THEN
13727: msc_sch_wb.atp_debug('Add_To_Comp_List: ' || 'in side not phantom');
13728: END IF;
13729: END IF;
13730:
13731: END Add_To_Comp_List;