DBA Data[Home] [Help]

APPS.GMF_LOT_COSTING_PUB dependencies on FND_FILE

Line 1427: fnd_file.put_line

1423: procedure_name := 'Merge Costs';
1424:
1425: IF l_debug_level >= l_debug_level_medium
1426: THEN
1427: fnd_file.put_line
1428: (fnd_file.log,'Entered Procedure: '||procedure_name);
1429: END IF;
1430:
1431: IF l_debug_level >= l_debug_level_high

Line 1428: (fnd_file.log,'Entered Procedure: '||procedure_name);

1424:
1425: IF l_debug_level >= l_debug_level_medium
1426: THEN
1427: fnd_file.put_line
1428: (fnd_file.log,'Entered Procedure: '||procedure_name);
1429: END IF;
1430:
1431: IF l_debug_level >= l_debug_level_high
1432: THEN

Line 1433: fnd_file.put_line(fnd_file.log,'Cost_qty = '||cost_qty||', new_qty = '||new_qty);

1429: END IF;
1430:
1431: IF l_debug_level >= l_debug_level_high
1432: THEN
1433: fnd_file.put_line(fnd_file.log,'Cost_qty = '||cost_qty||', new_qty = '||new_qty);
1434:
1435: fnd_file.put_line(fnd_file.log,'Before merge new_cost_tab is:');
1436:
1437: FOR k IN 1 .. new_cost_tab.COUNT

Line 1435: fnd_file.put_line(fnd_file.log,'Before merge new_cost_tab is:');

1431: IF l_debug_level >= l_debug_level_high
1432: THEN
1433: fnd_file.put_line(fnd_file.log,'Cost_qty = '||cost_qty||', new_qty = '||new_qty);
1434:
1435: fnd_file.put_line(fnd_file.log,'Before merge new_cost_tab is:');
1436:
1437: FOR k IN 1 .. new_cost_tab.COUNT
1438: LOOP
1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

Line 1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

1435: fnd_file.put_line(fnd_file.log,'Before merge new_cost_tab is:');
1436:
1437: FOR k IN 1 .. new_cost_tab.COUNT
1438: LOOP
1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1440: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1441: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1442: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1443: fnd_file.put_line(fnd_file.log,'====================================');

Line 1440: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

1436:
1437: FOR k IN 1 .. new_cost_tab.COUNT
1438: LOOP
1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1440: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1441: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1442: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1443: fnd_file.put_line(fnd_file.log,'====================================');
1444: END LOOP;

Line 1441: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);

1437: FOR k IN 1 .. new_cost_tab.COUNT
1438: LOOP
1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1440: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1441: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1442: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1443: fnd_file.put_line(fnd_file.log,'====================================');
1444: END LOOP;
1445:

Line 1442: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

1438: LOOP
1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1440: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1441: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1442: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1443: fnd_file.put_line(fnd_file.log,'====================================');
1444: END LOOP;
1445:
1446: IF costs_table.EXISTS(1)

Line 1443: fnd_file.put_line(fnd_file.log,'====================================');

1439: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1440: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1441: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1442: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1443: fnd_file.put_line(fnd_file.log,'====================================');
1444: END LOOP;
1445:
1446: IF costs_table.EXISTS(1)
1447: THEN

Line 1448: fnd_file.put_line(fnd_file.log,'Before merge costs_tab is:');

1444: END LOOP;
1445:
1446: IF costs_table.EXISTS(1)
1447: THEN
1448: fnd_file.put_line(fnd_file.log,'Before merge costs_tab is:');
1449: FOR k IN 1 .. costs_table.COUNT
1450: LOOP
1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

Line 1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);

1447: THEN
1448: fnd_file.put_line(fnd_file.log,'Before merge costs_tab is:');
1449: FOR k IN 1 .. costs_table.COUNT
1450: LOOP
1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1453: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1455: fnd_file.put_line(fnd_file.log,'====================================');

Line 1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

1448: fnd_file.put_line(fnd_file.log,'Before merge costs_tab is:');
1449: FOR k IN 1 .. costs_table.COUNT
1450: LOOP
1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1453: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1455: fnd_file.put_line(fnd_file.log,'====================================');
1456: END LOOP;

Line 1453: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);

1449: FOR k IN 1 .. costs_table.COUNT
1450: LOOP
1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1453: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1455: fnd_file.put_line(fnd_file.log,'====================================');
1456: END LOOP;
1457: ELSE

Line 1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);

1450: LOOP
1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1453: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1455: fnd_file.put_line(fnd_file.log,'====================================');
1456: END LOOP;
1457: ELSE
1458: fnd_file.put_line(fnd_file.log,'No costs to merge');

Line 1455: fnd_file.put_line(fnd_file.log,'====================================');

1451: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1452: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1453: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1455: fnd_file.put_line(fnd_file.log,'====================================');
1456: END LOOP;
1457: ELSE
1458: fnd_file.put_line(fnd_file.log,'No costs to merge');
1459: END IF;

Line 1458: fnd_file.put_line(fnd_file.log,'No costs to merge');

1454: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1455: fnd_file.put_line(fnd_file.log,'====================================');
1456: END LOOP;
1457: ELSE
1458: fnd_file.put_line(fnd_file.log,'No costs to merge');
1459: END IF;
1460: END IF;
1461:
1462: IF costs_table.EXISTS(1)

Line 1474: fnd_file.put_line(fnd_file.log,'Divisor is '||divisor||'cost qty = '||cost_qty||' new qty= '||new_qty);

1470: THEN
1471: divisor := 1;
1472: END IF;
1473:
1474: fnd_file.put_line(fnd_file.log,'Divisor is '||divisor||'cost qty = '||cost_qty||' new qty= '||new_qty);
1475:
1476: FOR k in 1 .. costs_table.COUNT
1477: LOOP
1478: costs_table(k).component_cost := costs_table(k).component_cost * cost_qty / divisor;

Line 1488: fnd_file.put_line(fnd_file.log,'Cost_qty = '||cost_qty||', new_qty = '||new_qty);

1484: END LOOP;
1485:
1486: IF l_debug_level >= l_debug_level_high
1487: THEN
1488: fnd_file.put_line(fnd_file.log,'Cost_qty = '||cost_qty||', new_qty = '||new_qty);
1489:
1490: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
1491:
1492: FOR k IN 1 .. new_cost_tab.COUNT

Line 1490: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');

1486: IF l_debug_level >= l_debug_level_high
1487: THEN
1488: fnd_file.put_line(fnd_file.log,'Cost_qty = '||cost_qty||', new_qty = '||new_qty);
1489:
1490: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
1491:
1492: FOR k IN 1 .. new_cost_tab.COUNT
1493: LOOP
1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

Line 1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

1490: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
1491:
1492: FOR k IN 1 .. new_cost_tab.COUNT
1493: LOOP
1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1495: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1496: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1498: fnd_file.put_line(fnd_file.log,'====================================');

Line 1495: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

1491:
1492: FOR k IN 1 .. new_cost_tab.COUNT
1493: LOOP
1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1495: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1496: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1498: fnd_file.put_line(fnd_file.log,'====================================');
1499: END LOOP;

Line 1496: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);

1492: FOR k IN 1 .. new_cost_tab.COUNT
1493: LOOP
1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1495: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1496: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1498: fnd_file.put_line(fnd_file.log,'====================================');
1499: END LOOP;
1500:

Line 1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

1493: LOOP
1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1495: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1496: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1498: fnd_file.put_line(fnd_file.log,'====================================');
1499: END LOOP;
1500:
1501: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');

Line 1498: fnd_file.put_line(fnd_file.log,'====================================');

1494: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1495: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1496: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1498: fnd_file.put_line(fnd_file.log,'====================================');
1499: END LOOP;
1500:
1501: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
1502: FOR k IN 1 .. costs_table.COUNT

Line 1501: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');

1497: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1498: fnd_file.put_line(fnd_file.log,'====================================');
1499: END LOOP;
1500:
1501: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
1502: FOR k IN 1 .. costs_table.COUNT
1503: LOOP
1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

Line 1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);

1500:
1501: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
1502: FOR k IN 1 .. costs_table.COUNT
1503: LOOP
1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1506: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1507: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1508: fnd_file.put_line(fnd_file.log,'====================================');

Line 1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

1501: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
1502: FOR k IN 1 .. costs_table.COUNT
1503: LOOP
1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1506: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1507: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1508: fnd_file.put_line(fnd_file.log,'====================================');
1509: END LOOP;

Line 1506: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);

1502: FOR k IN 1 .. costs_table.COUNT
1503: LOOP
1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1506: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1507: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1508: fnd_file.put_line(fnd_file.log,'====================================');
1509: END LOOP;
1510: END IF;

Line 1507: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);

1503: LOOP
1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1506: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1507: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1508: fnd_file.put_line(fnd_file.log,'====================================');
1509: END LOOP;
1510: END IF;
1511: END IF;

Line 1508: fnd_file.put_line(fnd_file.log,'====================================');

1504: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
1505: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
1506: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
1507: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
1508: fnd_file.put_line(fnd_file.log,'====================================');
1509: END LOOP;
1510: END IF;
1511: END IF;
1512:

Line 1553: fnd_file.put_line(fnd_file.log,'After merge new_cost_tab is:');

1549: END LOOP;
1550:
1551: IF l_debug_level >= l_debug_level_high
1552: THEN
1553: fnd_file.put_line(fnd_file.log,'After merge new_cost_tab is:');
1554: FOR k IN 1 .. new_cost_tab.COUNT
1555: LOOP
1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

Line 1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

1552: THEN
1553: fnd_file.put_line(fnd_file.log,'After merge new_cost_tab is:');
1554: FOR k IN 1 .. new_cost_tab.COUNT
1555: LOOP
1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1560: fnd_file.put_line(fnd_file.log,'====================================');

Line 1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

1553: fnd_file.put_line(fnd_file.log,'After merge new_cost_tab is:');
1554: FOR k IN 1 .. new_cost_tab.COUNT
1555: LOOP
1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1560: fnd_file.put_line(fnd_file.log,'====================================');
1561: END LOOP;

Line 1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);

1554: FOR k IN 1 .. new_cost_tab.COUNT
1555: LOOP
1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1560: fnd_file.put_line(fnd_file.log,'====================================');
1561: END LOOP;
1562: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||new_cost.unit_cost);

Line 1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

1555: LOOP
1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1560: fnd_file.put_line(fnd_file.log,'====================================');
1561: END LOOP;
1562: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||new_cost.unit_cost);
1563: END IF;

Line 1560: fnd_file.put_line(fnd_file.log,'====================================');

1556: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
1557: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1560: fnd_file.put_line(fnd_file.log,'====================================');
1561: END LOOP;
1562: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||new_cost.unit_cost);
1563: END IF;
1564:

Line 1562: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||new_cost.unit_cost);

1558: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
1559: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
1560: fnd_file.put_line(fnd_file.log,'====================================');
1561: END LOOP;
1562: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||new_cost.unit_cost);
1563: END IF;
1564:
1565:
1566: IF l_debug_level >= l_debug_level_medium

Line 1568: fnd_file.put_line

1564:
1565:
1566: IF l_debug_level >= l_debug_level_medium
1567: THEN
1568: fnd_file.put_line
1569: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1570: END IF;
1571: END;
1572:

Line 1569: (fnd_file.log,'Leaving Procedure: '||procedure_name);

1565:
1566: IF l_debug_level >= l_debug_level_medium
1567: THEN
1568: fnd_file.put_line
1569: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1570: END IF;
1571: END;
1572:
1573:

Line 1597: fnd_file.put_line

1593: procedure_name := 'Process Burdens';
1594:
1595: IF l_debug_level >= l_debug_level_medium
1596: THEN
1597: fnd_file.put_line
1598: (fnd_file.log,'Entered Procedure: '||procedure_name);
1599: END IF;
1600:
1601: l_return_status := 'S';

Line 1598: (fnd_file.log,'Entered Procedure: '||procedure_name);

1594:
1595: IF l_debug_level >= l_debug_level_medium
1596: THEN
1597: fnd_file.put_line
1598: (fnd_file.log,'Entered Procedure: '||procedure_name);
1599: END IF;
1600:
1601: l_return_status := 'S';
1602: l_burdens_total := 0;

Line 1623: fnd_file.put_line(fnd_file.log,

1619: IF l_burdens_tab.EXISTS(1)
1620: THEN
1621: IF l_debug_level >= l_debug_level_high
1622: THEN
1623: fnd_file.put_line(fnd_file.log,
1624: 'Burdens found for item: ' || transaction_row.inventory_item_id ||
1625: ' orgn: ' || l_org_tab(transaction_row.orgn_id) || ' cost type: ' || l_cost_method_code ||
1626: ' lot: ' || transaction_row.lot_number ||
1627: ' trans_date: ' || to_char(transaction_row.trans_date));

Line 1629: fnd_file.put_line

1625: ' orgn: ' || l_org_tab(transaction_row.orgn_id) || ' cost type: ' || l_cost_method_code ||
1626: ' lot: ' || transaction_row.lot_number ||
1627: ' trans_date: ' || to_char(transaction_row.trans_date));
1628:
1629: fnd_file.put_line
1630: ( fnd_file.log
1631: , 'Burdens Table is:');
1632: FOR i IN 1.. l_burdens_tab.COUNT
1633: LOOP

Line 1630: ( fnd_file.log

1626: ' lot: ' || transaction_row.lot_number ||
1627: ' trans_date: ' || to_char(transaction_row.trans_date));
1628:
1629: fnd_file.put_line
1630: ( fnd_file.log
1631: , 'Burdens Table is:');
1632: FOR i IN 1.. l_burdens_tab.COUNT
1633: LOOP
1634: fnd_file.put_line( fnd_file.log, 'Resources['||i||']:'||l_burdens_tab(i).resources);

Line 1634: fnd_file.put_line( fnd_file.log, 'Resources['||i||']:'||l_burdens_tab(i).resources);

1630: ( fnd_file.log
1631: , 'Burdens Table is:');
1632: FOR i IN 1.. l_burdens_tab.COUNT
1633: LOOP
1634: fnd_file.put_line( fnd_file.log, 'Resources['||i||']:'||l_burdens_tab(i).resources);
1635: fnd_file.put_line( fnd_file.log, 'CCC ID ['||i||']:'||l_burdens_tab(i).cost_cmpntcls_id);
1636: fnd_file.put_line( fnd_file.log, 'C/A Code ['||i||']:'||l_burdens_tab(i).cost_analysis_code);
1637: fnd_file.put_line( fnd_file.log, 'B/Factor ['||i||']:'||l_burdens_tab(i).burden_factor);
1638: END LOOP;

Line 1635: fnd_file.put_line( fnd_file.log, 'CCC ID ['||i||']:'||l_burdens_tab(i).cost_cmpntcls_id);

1631: , 'Burdens Table is:');
1632: FOR i IN 1.. l_burdens_tab.COUNT
1633: LOOP
1634: fnd_file.put_line( fnd_file.log, 'Resources['||i||']:'||l_burdens_tab(i).resources);
1635: fnd_file.put_line( fnd_file.log, 'CCC ID ['||i||']:'||l_burdens_tab(i).cost_cmpntcls_id);
1636: fnd_file.put_line( fnd_file.log, 'C/A Code ['||i||']:'||l_burdens_tab(i).cost_analysis_code);
1637: fnd_file.put_line( fnd_file.log, 'B/Factor ['||i||']:'||l_burdens_tab(i).burden_factor);
1638: END LOOP;
1639: END IF;

Line 1636: fnd_file.put_line( fnd_file.log, 'C/A Code ['||i||']:'||l_burdens_tab(i).cost_analysis_code);

1632: FOR i IN 1.. l_burdens_tab.COUNT
1633: LOOP
1634: fnd_file.put_line( fnd_file.log, 'Resources['||i||']:'||l_burdens_tab(i).resources);
1635: fnd_file.put_line( fnd_file.log, 'CCC ID ['||i||']:'||l_burdens_tab(i).cost_cmpntcls_id);
1636: fnd_file.put_line( fnd_file.log, 'C/A Code ['||i||']:'||l_burdens_tab(i).cost_analysis_code);
1637: fnd_file.put_line( fnd_file.log, 'B/Factor ['||i||']:'||l_burdens_tab(i).burden_factor);
1638: END LOOP;
1639: END IF;
1640:

Line 1637: fnd_file.put_line( fnd_file.log, 'B/Factor ['||i||']:'||l_burdens_tab(i).burden_factor);

1633: LOOP
1634: fnd_file.put_line( fnd_file.log, 'Resources['||i||']:'||l_burdens_tab(i).resources);
1635: fnd_file.put_line( fnd_file.log, 'CCC ID ['||i||']:'||l_burdens_tab(i).cost_cmpntcls_id);
1636: fnd_file.put_line( fnd_file.log, 'C/A Code ['||i||']:'||l_burdens_tab(i).cost_analysis_code);
1637: fnd_file.put_line( fnd_file.log, 'B/Factor ['||i||']:'||l_burdens_tab(i).burden_factor);
1638: END LOOP;
1639: END IF;
1640:
1641: -- Retrieve the cost for each resource. If we can't find a cost for this cost method

Line 1653: fnd_file.put_line

1649: -- was calendar_code and cost_mthd_code
1650:
1651: IF l_debug_level >= l_debug_level_high
1652: THEN
1653: fnd_file.put_line
1654: ( fnd_file.log
1655: , 'Searching for resource cost using LE: ' || l_le_id ||
1656: ' mthd: ' || l_default_cost_type_id ||
1657: ' rsrc: ' || l_burdens_tab(i).resources ||

Line 1654: ( fnd_file.log

1650:
1651: IF l_debug_level >= l_debug_level_high
1652: THEN
1653: fnd_file.put_line
1654: ( fnd_file.log
1655: , 'Searching for resource cost using LE: ' || l_le_id ||
1656: ' mthd: ' || l_default_cost_type_id ||
1657: ' rsrc: ' || l_burdens_tab(i).resources ||
1658: ' orgn: ' || l_org_tab(transaction_row.orgn_id) ||

Line 1685: fnd_file.put_line

1681: THEN
1682:
1683: IF l_debug_level >= l_debug_level_high
1684: THEN
1685: fnd_file.put_line
1686: (fnd_file.log, 'Found cost: '|| l_burden_cost);
1687: END IF;
1688:
1689: l_burdens_tab(i).burden_cost := l_burdens_tab(i).burden_factor * l_burden_cost;

Line 1686: (fnd_file.log, 'Found cost: '|| l_burden_cost);

1682:
1683: IF l_debug_level >= l_debug_level_high
1684: THEN
1685: fnd_file.put_line
1686: (fnd_file.log, 'Found cost: '|| l_burden_cost);
1687: END IF;
1688:
1689: l_burdens_tab(i).burden_cost := l_burdens_tab(i).burden_factor * l_burden_cost;
1690:

Line 1693: fnd_file.put_line

1689: l_burdens_tab(i).burden_cost := l_burdens_tab(i).burden_factor * l_burden_cost;
1690:
1691: ELSE
1692:
1693: fnd_file.put_line
1694: ( fnd_file.log
1695: , 'ERROR: Unable to locate a burden cost. Resource: '
1696: || l_burdens_tab(i).resources
1697: || ', analysis code: '

Line 1694: ( fnd_file.log

1690:
1691: ELSE
1692:
1693: fnd_file.put_line
1694: ( fnd_file.log
1695: , 'ERROR: Unable to locate a burden cost. Resource: '
1696: || l_burdens_tab(i).resources
1697: || ', analysis code: '
1698: || l_burdens_tab(i).cost_analysis_code

Line 1722: fnd_file.put_line(fnd_file.log,'At end of process_burdens, the burden costs are:');

1718: END IF;
1719:
1720: IF l_debug_level >= l_debug_level_high
1721: THEN
1722: fnd_file.put_line(fnd_file.log,'At end of process_burdens, the burden costs are:');
1723: FOR i IN 1 .. l_burden_costs_tab.COUNT
1724: LOOP
1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);
1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);

Line 1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);

1721: THEN
1722: fnd_file.put_line(fnd_file.log,'At end of process_burdens, the burden costs are:');
1723: FOR i IN 1 .. l_burden_costs_tab.COUNT
1724: LOOP
1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);
1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);
1727: fnd_file.put_line(fnd_file.log,'Level ['||i||']: '||l_burden_costs_tab(i).cost_level);
1728: fnd_file.put_line(fnd_file.log,'C/Cost['||i||']: '||l_burden_costs_tab(i).component_cost);
1729: fnd_file.put_line(fnd_file.log,'====================================');

Line 1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);

1722: fnd_file.put_line(fnd_file.log,'At end of process_burdens, the burden costs are:');
1723: FOR i IN 1 .. l_burden_costs_tab.COUNT
1724: LOOP
1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);
1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);
1727: fnd_file.put_line(fnd_file.log,'Level ['||i||']: '||l_burden_costs_tab(i).cost_level);
1728: fnd_file.put_line(fnd_file.log,'C/Cost['||i||']: '||l_burden_costs_tab(i).component_cost);
1729: fnd_file.put_line(fnd_file.log,'====================================');
1730: END LOOP;

Line 1727: fnd_file.put_line(fnd_file.log,'Level ['||i||']: '||l_burden_costs_tab(i).cost_level);

1723: FOR i IN 1 .. l_burden_costs_tab.COUNT
1724: LOOP
1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);
1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);
1727: fnd_file.put_line(fnd_file.log,'Level ['||i||']: '||l_burden_costs_tab(i).cost_level);
1728: fnd_file.put_line(fnd_file.log,'C/Cost['||i||']: '||l_burden_costs_tab(i).component_cost);
1729: fnd_file.put_line(fnd_file.log,'====================================');
1730: END LOOP;
1731: END IF;

Line 1728: fnd_file.put_line(fnd_file.log,'C/Cost['||i||']: '||l_burden_costs_tab(i).component_cost);

1724: LOOP
1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);
1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);
1727: fnd_file.put_line(fnd_file.log,'Level ['||i||']: '||l_burden_costs_tab(i).cost_level);
1728: fnd_file.put_line(fnd_file.log,'C/Cost['||i||']: '||l_burden_costs_tab(i).component_cost);
1729: fnd_file.put_line(fnd_file.log,'====================================');
1730: END LOOP;
1731: END IF;
1732:

Line 1729: fnd_file.put_line(fnd_file.log,'====================================');

1725: fnd_file.put_line(fnd_file.log,'CCC/ID['||i||']: '||l_burden_costs_tab(i).cost_cmpntcls_id);
1726: fnd_file.put_line(fnd_file.log,'A/Code['||i||']: '||l_burden_costs_tab(i).cost_analysis_code);
1727: fnd_file.put_line(fnd_file.log,'Level ['||i||']: '||l_burden_costs_tab(i).cost_level);
1728: fnd_file.put_line(fnd_file.log,'C/Cost['||i||']: '||l_burden_costs_tab(i).component_cost);
1729: fnd_file.put_line(fnd_file.log,'====================================');
1730: END LOOP;
1731: END IF;
1732:
1733:

Line 1737: fnd_file.put_line

1733:
1734:
1735: IF l_debug_level >= l_debug_level_medium
1736: THEN
1737: fnd_file.put_line
1738: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1739: END IF;
1740:
1741: EXCEPTION

Line 1738: (fnd_file.log,'Leaving Procedure: '||procedure_name);

1734:
1735: IF l_debug_level >= l_debug_level_medium
1736: THEN
1737: fnd_file.put_line
1738: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1739: END IF;
1740:
1741: EXCEPTION
1742: WHEN OTHERS

Line 1745: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);

1741: EXCEPTION
1742: WHEN OTHERS
1743: THEN
1744:
1745: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);
1746: l_return_status := 'E';
1747:
1748: END process_burdens;
1749:

Line 1780: fnd_file.put_line

1776: BEGIN
1777: procedure_name := 'Create Cost Header';
1778: IF l_debug_level >= l_debug_level_medium
1779: THEN
1780: fnd_file.put_line
1781: (fnd_file.log,'Entered Procedure: '||procedure_name);
1782: END IF;
1783:
1784: IF l_debug_level >= l_debug_level_medium

Line 1781: (fnd_file.log,'Entered Procedure: '||procedure_name);

1777: procedure_name := 'Create Cost Header';
1778: IF l_debug_level >= l_debug_level_medium
1779: THEN
1780: fnd_file.put_line
1781: (fnd_file.log,'Entered Procedure: '||procedure_name);
1782: END IF;
1783:
1784: IF l_debug_level >= l_debug_level_medium
1785: THEN

Line 1786: fnd_file.put_line(fnd_file.log, 'p_unit_cost = '||p_unit_cost);

1782: END IF;
1783:
1784: IF l_debug_level >= l_debug_level_medium
1785: THEN
1786: fnd_file.put_line(fnd_file.log, 'p_unit_cost = '||p_unit_cost);
1787: END IF;
1788:
1789: IF p_unit_cost IS NULL
1790: THEN

Line 1791: fnd_file.put_line

1787: END IF;
1788:
1789: IF p_unit_cost IS NULL
1790: THEN
1791: fnd_file.put_line
1792: (fnd_file.log,'ERROR: Could not create cost header for Lot Number '||to_char(transaction_row.lot_number)||' as no cost was available');
1793: fnd_file.put_line
1794: (fnd_file.log,' Transaction type/ID was '||transaction_row.transaction_source_type_id||'/'||to_char(transaction_row.transaction_id));
1795: x_return_status := 'E';

Line 1792: (fnd_file.log,'ERROR: Could not create cost header for Lot Number '||to_char(transaction_row.lot_number)||' as no cost was available');

1788:
1789: IF p_unit_cost IS NULL
1790: THEN
1791: fnd_file.put_line
1792: (fnd_file.log,'ERROR: Could not create cost header for Lot Number '||to_char(transaction_row.lot_number)||' as no cost was available');
1793: fnd_file.put_line
1794: (fnd_file.log,' Transaction type/ID was '||transaction_row.transaction_source_type_id||'/'||to_char(transaction_row.transaction_id));
1795: x_return_status := 'E';
1796: RETURN;

Line 1793: fnd_file.put_line

1789: IF p_unit_cost IS NULL
1790: THEN
1791: fnd_file.put_line
1792: (fnd_file.log,'ERROR: Could not create cost header for Lot Number '||to_char(transaction_row.lot_number)||' as no cost was available');
1793: fnd_file.put_line
1794: (fnd_file.log,' Transaction type/ID was '||transaction_row.transaction_source_type_id||'/'||to_char(transaction_row.transaction_id));
1795: x_return_status := 'E';
1796: RETURN;
1797: END IF;

Line 1794: (fnd_file.log,' Transaction type/ID was '||transaction_row.transaction_source_type_id||'/'||to_char(transaction_row.transaction_id));

1790: THEN
1791: fnd_file.put_line
1792: (fnd_file.log,'ERROR: Could not create cost header for Lot Number '||to_char(transaction_row.lot_number)||' as no cost was available');
1793: fnd_file.put_line
1794: (fnd_file.log,' Transaction type/ID was '||transaction_row.transaction_source_type_id||'/'||to_char(transaction_row.transaction_id));
1795: x_return_status := 'E';
1796: RETURN;
1797: END IF;
1798:

Line 1801: fnd_file.put_line(fnd_file.log,'Inside INSERT HEADER');

1797: END IF;
1798:
1799: IF l_debug_level >= l_debug_level_medium
1800: THEN
1801: fnd_file.put_line(fnd_file.log,'Inside INSERT HEADER');
1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);
1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);

Line 1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);

1798:
1799: IF l_debug_level >= l_debug_level_medium
1800: THEN
1801: fnd_file.put_line(fnd_file.log,'Inside INSERT HEADER');
1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);
1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);

Line 1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);

1799: IF l_debug_level >= l_debug_level_medium
1800: THEN
1801: fnd_file.put_line(fnd_file.log,'Inside INSERT HEADER');
1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);
1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);

Line 1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);

1800: THEN
1801: fnd_file.put_line(fnd_file.log,'Inside INSERT HEADER');
1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);
1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);

Line 1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);

1801: fnd_file.put_line(fnd_file.log,'Inside INSERT HEADER');
1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);
1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);
1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);

Line 1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);

1802: fnd_file.put_line(fnd_file.log,'Item ID = '||p_item_id);
1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);
1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);
1810: fnd_file.put_line(fnd_file.log,'Doc ID = '||p_doc_id);

Line 1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);

1803: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_number);
1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);
1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);
1810: fnd_file.put_line(fnd_file.log,'Doc ID = '||p_doc_id);
1811: END IF;

Line 1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);

1804: fnd_file.put_line(fnd_file.log,'Unit Cost = '||p_unit_cost);
1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);
1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);
1810: fnd_file.put_line(fnd_file.log,'Doc ID = '||p_doc_id);
1811: END IF;
1812:

Line 1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);

1805: fnd_file.put_line(fnd_file.log,'Cost Date = '||p_cost_date);
1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);
1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);
1810: fnd_file.put_line(fnd_file.log,'Doc ID = '||p_doc_id);
1811: END IF;
1812:
1813: INSERT INTO gmf_lot_costs

Line 1810: fnd_file.put_line(fnd_file.log,'Doc ID = '||p_doc_id);

1806: fnd_file.put_line(fnd_file.log,'Whse Code = '||p_orgn_id);
1807: fnd_file.put_line(fnd_file.log,'Cost Method = '||p_cost_type_id);
1808: fnd_file.put_line(fnd_file.log,'Onhand Qty = '||p_onhand_qty);
1809: fnd_file.put_line(fnd_file.log,'Doc Type = '||p_trx_src_type_id||','||p_txn_act_id);
1810: fnd_file.put_line(fnd_file.log,'Doc ID = '||p_doc_id);
1811: END IF;
1812:
1813: INSERT INTO gmf_lot_costs
1814: ( header_id

Line 1867: fnd_file.put_line

1863: x_return_status := 'S';
1864:
1865: IF l_debug_level >= l_debug_level_medium
1866: THEN
1867: fnd_file.put_line
1868: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1869: END IF;
1870:
1871:

Line 1868: (fnd_file.log,'Leaving Procedure: '||procedure_name);

1864:
1865: IF l_debug_level >= l_debug_level_medium
1866: THEN
1867: fnd_file.put_line
1868: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1869: END IF;
1870:
1871:
1872: EXCEPTION

Line 1876: fnd_file.put_line

1872: EXCEPTION
1873:
1874: WHEN OTHERS
1875: THEN
1876: fnd_file.put_line
1877: (fnd_file.log,'ERROR: Unable to create cost header');
1878: fnd_file.put_line
1879: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1880:

Line 1877: (fnd_file.log,'ERROR: Unable to create cost header');

1873:
1874: WHEN OTHERS
1875: THEN
1876: fnd_file.put_line
1877: (fnd_file.log,'ERROR: Unable to create cost header');
1878: fnd_file.put_line
1879: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1880:
1881: x_return_status := 'E';

Line 1878: fnd_file.put_line

1874: WHEN OTHERS
1875: THEN
1876: fnd_file.put_line
1877: (fnd_file.log,'ERROR: Unable to create cost header');
1878: fnd_file.put_line
1879: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1880:
1881: x_return_status := 'E';
1882:

Line 1879: (fnd_file.log,SQLERRM || ' in ' || procedure_name);

1875: THEN
1876: fnd_file.put_line
1877: (fnd_file.log,'ERROR: Unable to create cost header');
1878: fnd_file.put_line
1879: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1880:
1881: x_return_status := 'E';
1882:
1883: END create_cost_header;

Line 1910: fnd_file.put_line

1906: BEGIN
1907: procedure_name := 'Create Cost Detail';
1908: IF l_debug_level >= l_debug_level_medium
1909: THEN
1910: fnd_file.put_line
1911: (fnd_file.log,'Entered Procedure: '||procedure_name);
1912: END IF;
1913: IF l_debug_level >= l_debug_level_medium
1914: THEN

Line 1911: (fnd_file.log,'Entered Procedure: '||procedure_name);

1907: procedure_name := 'Create Cost Detail';
1908: IF l_debug_level >= l_debug_level_medium
1909: THEN
1910: fnd_file.put_line
1911: (fnd_file.log,'Entered Procedure: '||procedure_name);
1912: END IF;
1913: IF l_debug_level >= l_debug_level_medium
1914: THEN
1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');

Line 1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');

1911: (fnd_file.log,'Entered Procedure: '||procedure_name);
1912: END IF;
1913: IF l_debug_level >= l_debug_level_medium
1914: THEN
1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');
1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);
1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);

Line 1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);

1912: END IF;
1913: IF l_debug_level >= l_debug_level_medium
1914: THEN
1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');
1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);
1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);
1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);

Line 1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);

1913: IF l_debug_level >= l_debug_level_medium
1914: THEN
1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');
1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);
1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);
1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);
1921: fnd_file.put_line(fnd_file.log,'Cost = '||p_component_cost);

Line 1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);

1914: THEN
1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');
1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);
1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);
1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);
1921: fnd_file.put_line(fnd_file.log,'Cost = '||p_component_cost);
1922: END IF;

Line 1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);

1915: fnd_file.put_line(fnd_file.log,'Inside INSERT DETAIL');
1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);
1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);
1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);
1921: fnd_file.put_line(fnd_file.log,'Cost = '||p_component_cost);
1922: END IF;
1923:

Line 1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);

1916: fnd_file.put_line(fnd_file.log,'Header ID = '||p_header_id);
1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);
1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);
1921: fnd_file.put_line(fnd_file.log,'Cost = '||p_component_cost);
1922: END IF;
1923:
1924:

Line 1921: fnd_file.put_line(fnd_file.log,'Cost = '||p_component_cost);

1917: fnd_file.put_line(fnd_file.log,'Component Class ID = '||p_component_class_id);
1918: fnd_file.put_line(fnd_file.log,'Analysis Code = '||p_cost_analysis_code);
1919: fnd_file.put_line(fnd_file.log,'Cost Level = '||p_cost_level);
1920: fnd_file.put_line(fnd_file.log,'Burden Ind = '||p_burden_ind);
1921: fnd_file.put_line(fnd_file.log,'Cost = '||p_component_cost);
1922: END IF;
1923:
1924:
1925: INSERT INTO gmf_lot_cost_details

Line 1966: fnd_file.put_line

1962: );
1963: x_return_status := 'S';
1964: IF l_debug_level >= l_debug_level_medium
1965: THEN
1966: fnd_file.put_line
1967: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1968: END IF;
1969:
1970: EXCEPTION

Line 1967: (fnd_file.log,'Leaving Procedure: '||procedure_name);

1963: x_return_status := 'S';
1964: IF l_debug_level >= l_debug_level_medium
1965: THEN
1966: fnd_file.put_line
1967: (fnd_file.log,'Leaving Procedure: '||procedure_name);
1968: END IF;
1969:
1970: EXCEPTION
1971:

Line 1974: fnd_file.put_line

1970: EXCEPTION
1971:
1972: WHEN OTHERS
1973: THEN
1974: fnd_file.put_line
1975: (fnd_file.log,'ERROR: Unable to create cost detail');
1976: fnd_file.put_line
1977: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1978:

Line 1975: (fnd_file.log,'ERROR: Unable to create cost detail');

1971:
1972: WHEN OTHERS
1973: THEN
1974: fnd_file.put_line
1975: (fnd_file.log,'ERROR: Unable to create cost detail');
1976: fnd_file.put_line
1977: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1978:
1979: x_return_status := 'E';

Line 1976: fnd_file.put_line

1972: WHEN OTHERS
1973: THEN
1974: fnd_file.put_line
1975: (fnd_file.log,'ERROR: Unable to create cost detail');
1976: fnd_file.put_line
1977: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1978:
1979: x_return_status := 'E';
1980:

Line 1977: (fnd_file.log,SQLERRM || ' in ' || procedure_name);

1973: THEN
1974: fnd_file.put_line
1975: (fnd_file.log,'ERROR: Unable to create cost detail');
1976: fnd_file.put_line
1977: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
1978:
1979: x_return_status := 'E';
1980:
1981: END create_cost_detail;

Line 2001: fnd_file.put_line

1997:
1998: procedure_name := 'Clone Costs';
1999: IF l_debug_level >= l_debug_level_medium
2000: THEN
2001: fnd_file.put_line
2002: (fnd_file.log,'Entered Procedure: '||procedure_name);
2003: END IF;
2004:
2005: create_cost_header

Line 2002: (fnd_file.log,'Entered Procedure: '||procedure_name);

1998: procedure_name := 'Clone Costs';
1999: IF l_debug_level >= l_debug_level_medium
2000: THEN
2001: fnd_file.put_line
2002: (fnd_file.log,'Entered Procedure: '||procedure_name);
2003: END IF;
2004:
2005: create_cost_header
2006: ( old_cost.inventory_item_id /*bug 5309434*/

Line 2041: fnd_file.put_line

2037: END LOOP;
2038: END IF;
2039: IF l_debug_level >= l_debug_level_medium
2040: THEN
2041: fnd_file.put_line
2042: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2043: END IF;
2044:
2045: EXCEPTION

Line 2042: (fnd_file.log,'Leaving Procedure: '||procedure_name);

2038: END IF;
2039: IF l_debug_level >= l_debug_level_medium
2040: THEN
2041: fnd_file.put_line
2042: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2043: END IF;
2044:
2045: EXCEPTION
2046:

Line 2049: fnd_file.put_line

2045: EXCEPTION
2046:
2047: WHEN OTHERS
2048: THEN
2049: fnd_file.put_line
2050: ( fnd_file.log
2051: , 'ERROR: Could not clone costs '||SQLERRM
2052: );
2053:

Line 2050: ( fnd_file.log

2046:
2047: WHEN OTHERS
2048: THEN
2049: fnd_file.put_line
2050: ( fnd_file.log
2051: , 'ERROR: Could not clone costs '||SQLERRM
2052: );
2053:
2054: l_return_status := 'U';

Line 2086: fnd_file.put_line

2082: BEGIN
2083: procedure_name := 'Create Material Transaction';
2084: IF l_debug_level >= l_debug_level_medium
2085: THEN
2086: fnd_file.put_line
2087: (fnd_file.log,'Entered Procedure: '||procedure_name);
2088: END IF;
2089:
2090: IF l_debug_level >= l_debug_level_medium

Line 2087: (fnd_file.log,'Entered Procedure: '||procedure_name);

2083: procedure_name := 'Create Material Transaction';
2084: IF l_debug_level >= l_debug_level_medium
2085: THEN
2086: fnd_file.put_line
2087: (fnd_file.log,'Entered Procedure: '||procedure_name);
2088: END IF;
2089:
2090: IF l_debug_level >= l_debug_level_medium
2091: THEN

Line 2092: fnd_file.put_line(fnd_file.log,'Creating material transaction with these values:');

2088: END IF;
2089:
2090: IF l_debug_level >= l_debug_level_medium
2091: THEN
2092: fnd_file.put_line(fnd_file.log,'Creating material transaction with these values:');
2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);
2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);

Line 2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);

2089:
2090: IF l_debug_level >= l_debug_level_medium
2091: THEN
2092: fnd_file.put_line(fnd_file.log,'Creating material transaction with these values:');
2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);
2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);

Line 2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);

2090: IF l_debug_level >= l_debug_level_medium
2091: THEN
2092: fnd_file.put_line(fnd_file.log,'Creating material transaction with these values:');
2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);
2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);

Line 2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);

2091: THEN
2092: fnd_file.put_line(fnd_file.log,'Creating material transaction with these values:');
2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);
2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);

Line 2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);

2092: fnd_file.put_line(fnd_file.log,'Creating material transaction with these values:');
2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);
2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);

Line 2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);

2093: fnd_file.put_line(fnd_file.log,'Header ID :'||p_header_id);
2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);

Line 2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);

2094: fnd_file.put_line(fnd_file.log,'Cost Method :'||p_cost_type_id);
2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);

Line 2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);

2095: fnd_file.put_line(fnd_file.log,'Date :'||p_trans_date);
2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);

Line 2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);

2096: fnd_file.put_line(fnd_file.log,'Trans Qty :'||p_trans_qty);
2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);
2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);

Line 2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);

2097: fnd_file.put_line(fnd_file.log,'UoM :'||p_trans_um);
2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);
2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);
2105: fnd_file.put_line(fnd_file.log,'Lot Number :'||p_lot_number);

Line 2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);

2098: fnd_file.put_line(fnd_file.log,'Total Cost :'||p_total_cost);
2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);
2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);
2105: fnd_file.put_line(fnd_file.log,'Lot Number :'||p_lot_number);
2106: END IF;

Line 2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);

2099: fnd_file.put_line(fnd_file.log,'Trans ID :'||p_trans_id);
2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);
2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);
2105: fnd_file.put_line(fnd_file.log,'Lot Number :'||p_lot_number);
2106: END IF;
2107:

Line 2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);

2100: fnd_file.put_line(fnd_file.log,'Unit Cost :'||p_unit_cost);
2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);
2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);
2105: fnd_file.put_line(fnd_file.log,'Lot Number :'||p_lot_number);
2106: END IF;
2107:
2108: INSERT INTO gmf_material_lot_cost_txns

Line 2105: fnd_file.put_line(fnd_file.log,'Lot Number :'||p_lot_number);

2101: fnd_file.put_line(fnd_file.log,'Onhand Qty :'||p_onhand_qty);
2102: fnd_file.put_line(fnd_file.log,'Old Unit Cost :'||p_old_unit_cost);
2103: fnd_file.put_line(fnd_file.log,'Old Onhand Qty :'||p_old_onhand_qty);
2104: fnd_file.put_line(fnd_file.log,'New Cost Ind :'||p_new_cost_ind);
2105: fnd_file.put_line(fnd_file.log,'Lot Number :'||p_lot_number);
2106: END IF;
2107:
2108: INSERT INTO gmf_material_lot_cost_txns
2109: ( cost_trans_id

Line 2161: fnd_file.put_line

2157: );
2158: x_return_status := 'S';
2159: IF l_debug_level >= l_debug_level_medium
2160: THEN
2161: fnd_file.put_line
2162: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2163: END IF;
2164:
2165:

Line 2162: (fnd_file.log,'Leaving Procedure: '||procedure_name);

2158: x_return_status := 'S';
2159: IF l_debug_level >= l_debug_level_medium
2160: THEN
2161: fnd_file.put_line
2162: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2163: END IF;
2164:
2165:
2166: EXCEPTION

Line 2170: fnd_file.put_line

2166: EXCEPTION
2167:
2168: WHEN OTHERS
2169: THEN
2170: fnd_file.put_line
2171: (fnd_file.log,'ERROR: Unable to create material cost transaction');
2172: fnd_file.put_line
2173: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
2174:

Line 2171: (fnd_file.log,'ERROR: Unable to create material cost transaction');

2167:
2168: WHEN OTHERS
2169: THEN
2170: fnd_file.put_line
2171: (fnd_file.log,'ERROR: Unable to create material cost transaction');
2172: fnd_file.put_line
2173: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
2174:
2175: x_return_status := 'E';

Line 2172: fnd_file.put_line

2168: WHEN OTHERS
2169: THEN
2170: fnd_file.put_line
2171: (fnd_file.log,'ERROR: Unable to create material cost transaction');
2172: fnd_file.put_line
2173: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
2174:
2175: x_return_status := 'E';
2176:

Line 2173: (fnd_file.log,SQLERRM || ' in ' || procedure_name);

2169: THEN
2170: fnd_file.put_line
2171: (fnd_file.log,'ERROR: Unable to create material cost transaction');
2172: fnd_file.put_line
2173: (fnd_file.log,SQLERRM || ' in ' || procedure_name);
2174:
2175: x_return_status := 'E';
2176:
2177: END create_material_transaction;

Line 2244: fnd_file.put_line

2240:
2241: procedure_name := 'Process Special Charges';
2242: IF l_debug_level >= l_debug_level_medium
2243: THEN
2244: fnd_file.put_line
2245: (fnd_file.log,'Entered Procedure: '||procedure_name);
2246: END IF;
2247:
2248: l_acquisitions_total := 0;

Line 2245: (fnd_file.log,'Entered Procedure: '||procedure_name);

2241: procedure_name := 'Process Special Charges';
2242: IF l_debug_level >= l_debug_level_medium
2243: THEN
2244: fnd_file.put_line
2245: (fnd_file.log,'Entered Procedure: '||procedure_name);
2246: END IF;
2247:
2248: l_acquisitions_total := 0;
2249:

Line 2278: fnd_file.put_line

2274: l_acq_tab(i).component_cost := l_acquisition_cost;
2275:
2276: IF (l_acquisition_cost < 0)
2277: THEN
2278: fnd_file.put_line
2279: (fnd_file.log,'ERROR: Unable to convert from '
2280: ||transaction_row.trans_um
2281: ||' to '||l_from_uom||' for transaction ID '
2282: ||transaction_row.transaction_id

Line 2279: (fnd_file.log,'ERROR: Unable to convert from '

2275:
2276: IF (l_acquisition_cost < 0)
2277: THEN
2278: fnd_file.put_line
2279: (fnd_file.log,'ERROR: Unable to convert from '
2280: ||transaction_row.trans_um
2281: ||' to '||l_from_uom||' for transaction ID '
2282: ||transaction_row.transaction_id
2283: );

Line 2301: fnd_file.put_line (fnd_file.log,'

2297: IF ( l_base_ccy_code <> receipt_ccy) THEN /* Check if the receipt currency is the same as the base currency */
2298:
2299: IF l_debug_level >= l_debug_level_medium
2300: THEN
2301: fnd_file.put_line (fnd_file.log,'
2302: In Acquisition Costs() : Converting component_cost : '||
2303: NVL(l_acq_tab(i).component_cost,0)||' Receipt Currency : '||receipt_ccy||
2304: ' to Base Currency : '||l_base_ccy_code||'. New component_cost : '||
2305: NVL(l_acq_tab(i).component_cost,0) * l_exchange_rate||'. Exchange Rate is : '||l_exchange_rate);

Line 2335: fnd_file.put_line(fnd_file.log,'At end of get_special_charges, the costs are:');

2331: END IF;
2332:
2333: IF l_debug_level >= l_debug_level_medium
2334: THEN
2335: fnd_file.put_line(fnd_file.log,'At end of get_special_charges, the costs are:');
2336: FOR i IN 1 .. l_acqui_cost_tab.COUNT
2337: LOOP
2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);
2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);

Line 2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);

2334: THEN
2335: fnd_file.put_line(fnd_file.log,'At end of get_special_charges, the costs are:');
2336: FOR i IN 1 .. l_acqui_cost_tab.COUNT
2337: LOOP
2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);
2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);
2340: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||l_acqui_cost_tab(i).cost_level);
2341: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||l_acqui_cost_tab(i).component_cost);
2342: fnd_file.put_line(fnd_file.log,'====================================');

Line 2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);

2335: fnd_file.put_line(fnd_file.log,'At end of get_special_charges, the costs are:');
2336: FOR i IN 1 .. l_acqui_cost_tab.COUNT
2337: LOOP
2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);
2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);
2340: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||l_acqui_cost_tab(i).cost_level);
2341: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||l_acqui_cost_tab(i).component_cost);
2342: fnd_file.put_line(fnd_file.log,'====================================');
2343:

Line 2340: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||l_acqui_cost_tab(i).cost_level);

2336: FOR i IN 1 .. l_acqui_cost_tab.COUNT
2337: LOOP
2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);
2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);
2340: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||l_acqui_cost_tab(i).cost_level);
2341: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||l_acqui_cost_tab(i).component_cost);
2342: fnd_file.put_line(fnd_file.log,'====================================');
2343:
2344: END LOOP;

Line 2341: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||l_acqui_cost_tab(i).component_cost);

2337: LOOP
2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);
2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);
2340: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||l_acqui_cost_tab(i).cost_level);
2341: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||l_acqui_cost_tab(i).component_cost);
2342: fnd_file.put_line(fnd_file.log,'====================================');
2343:
2344: END LOOP;
2345: END IF;

Line 2342: fnd_file.put_line(fnd_file.log,'====================================');

2338: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||l_acqui_cost_tab(i).cost_cmpntcls_id);
2339: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||l_acqui_cost_tab(i).cost_analysis_code);
2340: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||l_acqui_cost_tab(i).cost_level);
2341: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||l_acqui_cost_tab(i).component_cost);
2342: fnd_file.put_line(fnd_file.log,'====================================');
2343:
2344: END LOOP;
2345: END IF;
2346:

Line 2349: fnd_file.put_line

2345: END IF;
2346:
2347: IF l_debug_level >= l_debug_level_medium
2348: THEN
2349: fnd_file.put_line
2350: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2351: END IF;
2352: EXCEPTION
2353: WHEN OTHERS THEN

Line 2350: (fnd_file.log,'Leaving Procedure: '||procedure_name);

2346:
2347: IF l_debug_level >= l_debug_level_medium
2348: THEN
2349: fnd_file.put_line
2350: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2351: END IF;
2352: EXCEPTION
2353: WHEN OTHERS THEN
2354: fnd_file.put_line(fnd_file.log,procedure_name||':'||SQLERRM);

Line 2354: fnd_file.put_line(fnd_file.log,procedure_name||':'||SQLERRM);

2350: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2351: END IF;
2352: EXCEPTION
2353: WHEN OTHERS THEN
2354: fnd_file.put_line(fnd_file.log,procedure_name||':'||SQLERRM);
2355: END get_special_charges;
2356:
2357: --*************************************************************************************
2358: --* Procedure Name : PROCESS_ADJUSTMENT

Line 2381: fnd_file.put_line

2377:
2378: procedure_name := 'Process Adjustment';
2379: IF l_debug_level >= l_debug_level_medium
2380: THEN
2381: fnd_file.put_line
2382: (fnd_file.log,'Entered Procedure: '||procedure_name);
2383: END IF;
2384:
2385: -- This procedure is used if the lot being adjusted has a lot cost. Lots being created

Line 2382: (fnd_file.log,'Entered Procedure: '||procedure_name);

2378: procedure_name := 'Process Adjustment';
2379: IF l_debug_level >= l_debug_level_medium
2380: THEN
2381: fnd_file.put_line
2382: (fnd_file.log,'Entered Procedure: '||procedure_name);
2383: END IF;
2384:
2385: -- This procedure is used if the lot being adjusted has a lot cost. Lots being created
2386: -- via ADJx transactions are handled by the process_creation procedure (above).

Line 2393: fnd_file.put_line

2389: -- not the costs themselves.
2390:
2391: IF l_debug_level >= l_debug_level_medium
2392: THEN
2393: fnd_file.put_line
2394: (fnd_file.log,'Updating lot cost header with trans_qty of '||transaction_row.trans_qty);
2395: END IF;
2396:
2397: -- If the existing cost is marked as 'Final' and we are running in test mode we need

Line 2394: (fnd_file.log,'Updating lot cost header with trans_qty of '||transaction_row.trans_qty);

2390:
2391: IF l_debug_level >= l_debug_level_medium
2392: THEN
2393: fnd_file.put_line
2394: (fnd_file.log,'Updating lot cost header with trans_qty of '||transaction_row.trans_qty);
2395: END IF;
2396:
2397: -- If the existing cost is marked as 'Final' and we are running in test mode we need
2398: -- to clone the header and its details to prevent multiple decrements from the same transaction.

Line 2417: fnd_file.put_line

2413: IF SQL%ROWCOUNT = 1
2414: THEN
2415: IF l_debug_level >= l_debug_level_medium
2416: THEN
2417: fnd_file.put_line
2418: (fnd_file.log,'Creating new cost transaction');
2419: END IF;
2420:
2421: l_header_id := old_cost.header_id;

Line 2418: (fnd_file.log,'Creating new cost transaction');

2414: THEN
2415: IF l_debug_level >= l_debug_level_medium
2416: THEN
2417: fnd_file.put_line
2418: (fnd_file.log,'Creating new cost transaction');
2419: END IF;
2420:
2421: l_header_id := old_cost.header_id;
2422:

Line 2450: fnd_file.put_line

2446: RETURN;
2447: END IF;
2448: IF l_debug_level >= l_debug_level_medium
2449: THEN
2450: fnd_file.put_line
2451: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2452: END IF;
2453:
2454: EXCEPTION

Line 2451: (fnd_file.log,'Leaving Procedure: '||procedure_name);

2447: END IF;
2448: IF l_debug_level >= l_debug_level_medium
2449: THEN
2450: fnd_file.put_line
2451: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2452: END IF;
2453:
2454: EXCEPTION
2455: WHEN OTHERS

Line 2456: THEN fnd_file.put_line

2452: END IF;
2453:
2454: EXCEPTION
2455: WHEN OTHERS
2456: THEN fnd_file.put_line
2457: (fnd_file.log,'Failed in procedure process_adjustment with error');
2458: fnd_file.put_line
2459: (fnd_file.log,SQLERRM);
2460: l_return_status := 'U';

Line 2457: (fnd_file.log,'Failed in procedure process_adjustment with error');

2453:
2454: EXCEPTION
2455: WHEN OTHERS
2456: THEN fnd_file.put_line
2457: (fnd_file.log,'Failed in procedure process_adjustment with error');
2458: fnd_file.put_line
2459: (fnd_file.log,SQLERRM);
2460: l_return_status := 'U';
2461:

Line 2458: fnd_file.put_line

2454: EXCEPTION
2455: WHEN OTHERS
2456: THEN fnd_file.put_line
2457: (fnd_file.log,'Failed in procedure process_adjustment with error');
2458: fnd_file.put_line
2459: (fnd_file.log,SQLERRM);
2460: l_return_status := 'U';
2461:
2462: END process_adjustment;

Line 2459: (fnd_file.log,SQLERRM);

2455: WHEN OTHERS
2456: THEN fnd_file.put_line
2457: (fnd_file.log,'Failed in procedure process_adjustment with error');
2458: fnd_file.put_line
2459: (fnd_file.log,SQLERRM);
2460: l_return_status := 'U';
2461:
2462: END process_adjustment;
2463:

Line 2568: fnd_file.put_line

2564:
2565: procedure_name := 'Process Reversals';
2566: IF l_debug_level >= l_debug_level_medium
2567: THEN
2568: fnd_file.put_line
2569: (fnd_file.log,'Entered Procedure: '||procedure_name);
2570: END IF;
2571:
2572: --

Line 2569: (fnd_file.log,'Entered Procedure: '||procedure_name);

2565: procedure_name := 'Process Reversals';
2566: IF l_debug_level >= l_debug_level_medium
2567: THEN
2568: fnd_file.put_line
2569: (fnd_file.log,'Entered Procedure: '||procedure_name);
2570: END IF;
2571:
2572: --
2573: -- Running this loop only twice to see two previous cost rows.

Line 2598: fnd_file.put_line

2594: -- Other types of txns after original yield. So, process this reversal
2595: -- as regular adjustment. This will result in incorrect avg costs. known issue
2596: IF l_debug_level >= l_debug_level_medium
2597: THEN
2598: fnd_file.put_line
2599: (fnd_file.log,'Reversals: Processing reversal as regular adjustment');
2600: END IF;
2601:
2602: process_adjustment;

Line 2599: (fnd_file.log,'Reversals: Processing reversal as regular adjustment');

2595: -- as regular adjustment. This will result in incorrect avg costs. known issue
2596: IF l_debug_level >= l_debug_level_medium
2597: THEN
2598: fnd_file.put_line
2599: (fnd_file.log,'Reversals: Processing reversal as regular adjustment');
2600: END IF;
2601:
2602: process_adjustment;
2603: RETURN;

Line 2615: fnd_file.put_line

2611: -- if prev costs exists, then we'll use those costs and qty, but will
2612: -- get set in the else block below in the 2nd iteration.
2613: IF l_debug_level >= l_debug_level_low
2614: THEN
2615: fnd_file.put_line
2616: (fnd_file.log, 'Reversals: This txn is (pure) reversal of previous txn');
2617: END IF;
2618:
2619: l_prev_header_id := i.prev_header_id;

Line 2616: (fnd_file.log, 'Reversals: This txn is (pure) reversal of previous txn');

2612: -- get set in the else block below in the 2nd iteration.
2613: IF l_debug_level >= l_debug_level_low
2614: THEN
2615: fnd_file.put_line
2616: (fnd_file.log, 'Reversals: This txn is (pure) reversal of previous txn');
2617: END IF;
2618:
2619: l_prev_header_id := i.prev_header_id;
2620: l_cost_header_id := i.prev_header_id; /* will be used to insert in material txns table */

Line 2637: fnd_file.put_line

2633: -- Will come here if there any old costs before original yield.
2634: --
2635: IF l_debug_level >= l_debug_level_low
2636: THEN
2637: fnd_file.put_line
2638: (fnd_file.log,'Reversals: costs exists prior to original yield');
2639: END IF;
2640: l_prev_header_id := i.prev_header_id;
2641: l_prev_prev_header_id := i.prev_header_id;

Line 2638: (fnd_file.log,'Reversals: costs exists prior to original yield');

2634: --
2635: IF l_debug_level >= l_debug_level_low
2636: THEN
2637: fnd_file.put_line
2638: (fnd_file.log,'Reversals: costs exists prior to original yield');
2639: END IF;
2640: l_prev_header_id := i.prev_header_id;
2641: l_prev_prev_header_id := i.prev_header_id;
2642: l_prev_unit_cost := i.prev_unit_cost;

Line 2660: fnd_file.put_line

2656:
2657:
2658: IF l_debug_level >= l_debug_level_low
2659: THEN
2660: fnd_file.put_line
2661: (fnd_file.log,'Reversals: setting unit cost to ' || l_prev_unit_cost ||
2662: ' and qty to ' || (old_cost.onhand_qty + transaction_row.trans_qty));
2663: END IF;
2664:

Line 2661: (fnd_file.log,'Reversals: setting unit cost to ' || l_prev_unit_cost ||

2657:
2658: IF l_debug_level >= l_debug_level_low
2659: THEN
2660: fnd_file.put_line
2661: (fnd_file.log,'Reversals: setting unit cost to ' || l_prev_unit_cost ||
2662: ' and qty to ' || (old_cost.onhand_qty + transaction_row.trans_qty));
2663: END IF;
2664:
2665: IF l_prev_cost_cnt = 0

Line 2667: fnd_file.put_line

2663: END IF;
2664:
2665: IF l_prev_cost_cnt = 0
2666: THEN
2667: fnd_file.put_line
2668: (fnd_file.log,'ERROR: Failed to retrieve previous costs in Process Reversals');
2669: RETURN;
2670: END IF;
2671:

Line 2668: (fnd_file.log,'ERROR: Failed to retrieve previous costs in Process Reversals');

2664:
2665: IF l_prev_cost_cnt = 0
2666: THEN
2667: fnd_file.put_line
2668: (fnd_file.log,'ERROR: Failed to retrieve previous costs in Process Reversals');
2669: RETURN;
2670: END IF;
2671:
2672: create_cost_header

Line 2695: fnd_file.put_line

2691: THEN
2692:
2693: IF l_debug_level >= l_debug_level_low
2694: THEN
2695: fnd_file.put_line
2696: (fnd_file.log,'Reversals: Creating new cost detail row');
2697: END IF;
2698:
2699: FOR j in get_cost_details_cur(l_prev_header_id)

Line 2696: (fnd_file.log,'Reversals: Creating new cost detail row');

2692:
2693: IF l_debug_level >= l_debug_level_low
2694: THEN
2695: fnd_file.put_line
2696: (fnd_file.log,'Reversals: Creating new cost detail row');
2697: END IF;
2698:
2699: FOR j in get_cost_details_cur(l_prev_header_id)
2700: LOOP

Line 2728: fnd_file.put_line

2724: THEN
2725:
2726: IF l_debug_level >= l_debug_level_medium
2727: THEN
2728: fnd_file.put_line
2729: (fnd_file.log,'Reversals: Creating new material cost transaction. the l_prev_prev_header_id is '||l_prev_prev_header_id||' and l_cost_header_id '||l_cost_header_id);
2730: END IF;
2731:
2732:

Line 2729: (fnd_file.log,'Reversals: Creating new material cost transaction. the l_prev_prev_header_id is '||l_prev_prev_header_id||' and l_cost_header_id '||l_cost_header_id);

2725:
2726: IF l_debug_level >= l_debug_level_medium
2727: THEN
2728: fnd_file.put_line
2729: (fnd_file.log,'Reversals: Creating new material cost transaction. the l_prev_prev_header_id is '||l_prev_prev_header_id||' and l_cost_header_id '||l_cost_header_id);
2730: END IF;
2731:
2732:
2733:

Line 2770: THEN fnd_file.put_line

2766: END IF;
2767:
2768: EXCEPTION
2769: WHEN OTHERS
2770: THEN fnd_file.put_line
2771: (fnd_file.log,'Failed in procedure process_reversals with error');
2772: fnd_file.put_line
2773: (fnd_file.log,SQLERRM);
2774: l_return_status := 'U';

Line 2771: (fnd_file.log,'Failed in procedure process_reversals with error');

2767:
2768: EXCEPTION
2769: WHEN OTHERS
2770: THEN fnd_file.put_line
2771: (fnd_file.log,'Failed in procedure process_reversals with error');
2772: fnd_file.put_line
2773: (fnd_file.log,SQLERRM);
2774: l_return_status := 'U';
2775: END process_reversals;

Line 2772: fnd_file.put_line

2768: EXCEPTION
2769: WHEN OTHERS
2770: THEN fnd_file.put_line
2771: (fnd_file.log,'Failed in procedure process_reversals with error');
2772: fnd_file.put_line
2773: (fnd_file.log,SQLERRM);
2774: l_return_status := 'U';
2775: END process_reversals;
2776:

Line 2773: (fnd_file.log,SQLERRM);

2769: WHEN OTHERS
2770: THEN fnd_file.put_line
2771: (fnd_file.log,'Failed in procedure process_reversals with error');
2772: fnd_file.put_line
2773: (fnd_file.log,SQLERRM);
2774: l_return_status := 'U';
2775: END process_reversals;
2776:
2777:

Line 2827: fnd_file.put_line

2823: BEGIN
2824: procedure_name := 'Process Reversals2';
2825: IF l_debug_level >= l_debug_level_medium
2826: THEN
2827: fnd_file.put_line
2828: (fnd_file.log,'Entered Procedure: '||procedure_name);
2829: END IF;
2830:
2831: OPEN get_orig_trx(transaction_row.reverse_id);

Line 2828: (fnd_file.log,'Entered Procedure: '||procedure_name);

2824: procedure_name := 'Process Reversals2';
2825: IF l_debug_level >= l_debug_level_medium
2826: THEN
2827: fnd_file.put_line
2828: (fnd_file.log,'Entered Procedure: '||procedure_name);
2829: END IF;
2830:
2831: OPEN get_orig_trx(transaction_row.reverse_id);
2832: FETCH get_orig_trx INTO l_orig_trx_header_id, l_orig_trx_new_cost_ind;

Line 2836: fnd_file.put_line(fnd_file.log,'Reversals2: Error in locating the original trx '||transaction_row.reverse_id||' of transaction'||transaction_row.transaction_id);

2832: FETCH get_orig_trx INTO l_orig_trx_header_id, l_orig_trx_new_cost_ind;
2833:
2834: IF(get_orig_trx%NOTFOUND) THEN
2835: CLOSE get_orig_trx;
2836: fnd_file.put_line(fnd_file.log,'Reversals2: Error in locating the original trx '||transaction_row.reverse_id||' of transaction'||transaction_row.transaction_id);
2837: l_return_status := 'E';
2838: RETURN;
2839: END IF;
2840: CLOSE get_orig_trx;

Line 2848: fnd_file.put_line(fnd_file.log,'Reversals2: Error in locating the cost detail for orig_trx '||transaction_row.reverse_id);

2844: FETCH lot_cost_detail_cursor BULK COLLECT INTO orig_trx_cost_tab;
2845:
2846: IF(orig_trx_cost_tab.COUNT = 0) THEN
2847: CLOSE lot_cost_detail_cursor;
2848: fnd_file.put_line(fnd_file.log,'Reversals2: Error in locating the cost detail for orig_trx '||transaction_row.reverse_id);
2849: l_return_status := 'E';
2850: RETURN;
2851: END IF;
2852: CLOSE lot_cost_detail_cursor;

Line 2873: fnd_file.put_line(fnd_file.log,'Reversals2: Error in updating gmf_lot_costs for transaction_id: '||to_char(transaction_row.transaction_id));

2869:
2870: IF(SQL%ROWCOUNT = 1) THEN
2871: l_return_status := 'S';
2872: ELSE
2873: fnd_file.put_line(fnd_file.log,'Reversals2: Error in updating gmf_lot_costs for transaction_id: '||to_char(transaction_row.transaction_id));
2874: l_return_status := 'E';
2875: RETURN;
2876: END IF;
2877:

Line 2903: fnd_file.put_line(fnd_file.log,'Reversals2: Creating new cost detail row');

2899: IF l_return_status = 'S'
2900: THEN
2901: IF l_debug_level >= l_debug_level_medium
2902: THEN
2903: fnd_file.put_line(fnd_file.log,'Reversals2: Creating new cost detail row');
2904: END IF;
2905:
2906: FOR i in 1..new_cost_tab.COUNT
2907: LOOP

Line 2934: fnd_file.put_line

2930: END LOOP;
2931:
2932: IF l_debug_level >= l_debug_level_medium
2933: THEN
2934: fnd_file.put_line
2935: (fnd_file.log,'Reversals2: Creating new material cost transaction. The orig_header_id is '||l_orig_trx_header_id||' and l_header_id '||l_header_id);
2936: END IF;
2937:
2938: create_material_transaction

Line 2935: (fnd_file.log,'Reversals2: Creating new material cost transaction. The orig_header_id is '||l_orig_trx_header_id||' and l_header_id '||l_header_id);

2931:
2932: IF l_debug_level >= l_debug_level_medium
2933: THEN
2934: fnd_file.put_line
2935: (fnd_file.log,'Reversals2: Creating new material cost transaction. The orig_header_id is '||l_orig_trx_header_id||' and l_header_id '||l_header_id);
2936: END IF;
2937:
2938: create_material_transaction
2939: ( l_orig_trx_header_id

Line 2958: fnd_file.put_line(fnd_file.log,'Reversals2: Error in creating material_transaction for '||to_char(transaction_row.transaction_id));

2954:
2955:
2956: IF l_return_status <> 'S'
2957: THEN
2958: fnd_file.put_line(fnd_file.log,'Reversals2: Error in creating material_transaction for '||to_char(transaction_row.transaction_id));
2959: RETURN;
2960: END IF;
2961:
2962: ELSE

Line 2963: fnd_file.put_line(fnd_file.log,'Reversals2: Error in creating Cost Header/Detail for transaction '||to_char(transaction_row.transaction_id));

2959: RETURN;
2960: END IF;
2961:
2962: ELSE
2963: fnd_file.put_line(fnd_file.log,'Reversals2: Error in creating Cost Header/Detail for transaction '||to_char(transaction_row.transaction_id));
2964: RETURN;
2965: END IF;
2966: IF l_debug_level >= l_debug_level_medium
2967: THEN

Line 2968: fnd_file.put_line

2964: RETURN;
2965: END IF;
2966: IF l_debug_level >= l_debug_level_medium
2967: THEN
2968: fnd_file.put_line
2969: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2970: END IF;
2971:
2972: EXCEPTION

Line 2969: (fnd_file.log,'Leaving Procedure: '||procedure_name);

2965: END IF;
2966: IF l_debug_level >= l_debug_level_medium
2967: THEN
2968: fnd_file.put_line
2969: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2970: END IF;
2971:
2972: EXCEPTION
2973: WHEN OTHERS THEN fnd_file.put_line

Line 2973: WHEN OTHERS THEN fnd_file.put_line

2969: (fnd_file.log,'Leaving Procedure: '||procedure_name);
2970: END IF;
2971:
2972: EXCEPTION
2973: WHEN OTHERS THEN fnd_file.put_line
2974: (fnd_file.log,'Failed in procedure process_reversals2 with error');
2975: fnd_file.put_line(fnd_file.log,SQLERRM);
2976: l_return_status := 'U';
2977: END PROCESS_REVERSALS2;

Line 2974: (fnd_file.log,'Failed in procedure process_reversals2 with error');

2970: END IF;
2971:
2972: EXCEPTION
2973: WHEN OTHERS THEN fnd_file.put_line
2974: (fnd_file.log,'Failed in procedure process_reversals2 with error');
2975: fnd_file.put_line(fnd_file.log,SQLERRM);
2976: l_return_status := 'U';
2977: END PROCESS_REVERSALS2;
2978:

Line 2975: fnd_file.put_line(fnd_file.log,SQLERRM);

2971:
2972: EXCEPTION
2973: WHEN OTHERS THEN fnd_file.put_line
2974: (fnd_file.log,'Failed in procedure process_reversals2 with error');
2975: fnd_file.put_line(fnd_file.log,SQLERRM);
2976: l_return_status := 'U';
2977: END PROCESS_REVERSALS2;
2978:
2979:

Line 3038: fnd_file.put_line

3034: BEGIN
3035: procedure_name := 'Process Movement';
3036: IF l_debug_level >= l_debug_level_medium
3037: THEN
3038: fnd_file.put_line
3039: (fnd_file.log,'Entered Procedure: '||procedure_name);
3040: END IF;
3041: -- This procedure is only called when the source and target organizations differ.
3042:

Line 3039: (fnd_file.log,'Entered Procedure: '||procedure_name);

3035: procedure_name := 'Process Movement';
3036: IF l_debug_level >= l_debug_level_medium
3037: THEN
3038: fnd_file.put_line
3039: (fnd_file.log,'Entered Procedure: '||procedure_name);
3040: END IF;
3041: -- This procedure is only called when the source and target organizations differ.
3042:
3043: -- If this is a debit on the source organization (line type = -1) this is equivalent to an adjustment

Line 3064: fnd_file.put_line(fnd_file.log,'At start of Process Movement, new_cost_tab is:');

3060: -- This section also caters for line type 0 (used in PORC transactions for internal orders)
3061:
3062: IF l_debug_level >= l_debug_level_medium
3063: THEN
3064: fnd_file.put_line(fnd_file.log,'At start of Process Movement, new_cost_tab is:');
3065: IF new_cost_tab.EXISTS(1)
3066: THEN
3067: FOR k IN 1 .. new_cost_tab.COUNT
3068: LOOP

Line 3069: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

3065: IF new_cost_tab.EXISTS(1)
3066: THEN
3067: FOR k IN 1 .. new_cost_tab.COUNT
3068: LOOP
3069: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3070: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3071: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3073: fnd_file.put_line(fnd_file.log,'====================================');

Line 3070: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

3066: THEN
3067: FOR k IN 1 .. new_cost_tab.COUNT
3068: LOOP
3069: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3070: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3071: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3073: fnd_file.put_line(fnd_file.log,'====================================');
3074: END LOOP;

Line 3071: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);

3067: FOR k IN 1 .. new_cost_tab.COUNT
3068: LOOP
3069: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3070: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3071: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3073: fnd_file.put_line(fnd_file.log,'====================================');
3074: END LOOP;
3075: ELSE

Line 3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

3068: LOOP
3069: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3070: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3071: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3073: fnd_file.put_line(fnd_file.log,'====================================');
3074: END LOOP;
3075: ELSE
3076: fnd_file.put_line(fnd_file.log,'EMPTY');

Line 3073: fnd_file.put_line(fnd_file.log,'====================================');

3069: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3070: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3071: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3073: fnd_file.put_line(fnd_file.log,'====================================');
3074: END LOOP;
3075: ELSE
3076: fnd_file.put_line(fnd_file.log,'EMPTY');
3077: END IF;

Line 3076: fnd_file.put_line(fnd_file.log,'EMPTY');

3072: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3073: fnd_file.put_line(fnd_file.log,'====================================');
3074: END LOOP;
3075: ELSE
3076: fnd_file.put_line(fnd_file.log,'EMPTY');
3077: END IF;
3078: END IF;
3079: -- As there is a chance that the two organizations could be in separate companies we need to do something
3080: -- to ensure we can locate a cost for the sending transaction. If the two companies involved are the same

Line 3122: fnd_file.put_line

3118: );
3119: IF retval <> 0
3120: THEN
3121: l_return_status := 'E';
3122: fnd_file.put_line
3123: (fnd_file.log,'ERROR: Failed to retrieve single cost component in source organization '||l_org_tab(p_source_orgn));
3124: RETURN;
3125: ELSE
3126: -- Procedure doesn't return burden ind so coerce it to zero.

Line 3123: (fnd_file.log,'ERROR: Failed to retrieve single cost component in source organization '||l_org_tab(p_source_orgn));

3119: IF retval <> 0
3120: THEN
3121: l_return_status := 'E';
3122: fnd_file.put_line
3123: (fnd_file.log,'ERROR: Failed to retrieve single cost component in source organization '||l_org_tab(p_source_orgn));
3124: RETURN;
3125: ELSE
3126: -- Procedure doesn't return burden ind so coerce it to zero.
3127: new_cost_tab(i) := SYSTEM.gmf_cost_type ( l_ccc_id, l_a_code, 0, l_unit_cost, 0);

Line 3139: fnd_file.put_line

3135: OPEN component_class_cursor( p_target_le,transaction_row.inventory_item_id,p_target_orgn,p_trans_date);
3136: FETCH component_class_cursor INTO l_ccc_id,l_a_code,dummy;
3137: IF (component_class_cursor%NOTFOUND) THEN
3138: l_return_status := 'E';
3139: fnd_file.put_line
3140: (fnd_file.log,'ERROR: Failed to retrieve cost multiple components in source organization '||l_org_tab(p_source_orgn));
3141: CLOSE component_class_cursor;
3142: RETURN;
3143: END IF;

Line 3140: (fnd_file.log,'ERROR: Failed to retrieve cost multiple components in source organization '||l_org_tab(p_source_orgn));

3136: FETCH component_class_cursor INTO l_ccc_id,l_a_code,dummy;
3137: IF (component_class_cursor%NOTFOUND) THEN
3138: l_return_status := 'E';
3139: fnd_file.put_line
3140: (fnd_file.log,'ERROR: Failed to retrieve cost multiple components in source organization '||l_org_tab(p_source_orgn));
3141: CLOSE component_class_cursor;
3142: RETURN;
3143: END IF;
3144: END IF;

Line 3153: fnd_file.put_line

3149: CLOSE lot_cost_cursor;
3150:
3151: IF new_cost.header_id IS NULL
3152: THEN
3153: fnd_file.put_line
3154: ( fnd_file.log,'ERROR: Unable to locate cost header for organization: '||l_org_tab(p_source_orgn)
3155: || ', item ID: '||transaction_row.inventory_item_id
3156: ||', lot Number: '||transaction_row.lot_number
3157: );

Line 3154: ( fnd_file.log,'ERROR: Unable to locate cost header for organization: '||l_org_tab(p_source_orgn)

3150:
3151: IF new_cost.header_id IS NULL
3152: THEN
3153: fnd_file.put_line
3154: ( fnd_file.log,'ERROR: Unable to locate cost header for organization: '||l_org_tab(p_source_orgn)
3155: || ', item ID: '||transaction_row.inventory_item_id
3156: ||', lot Number: '||transaction_row.lot_number
3157: );
3158: l_return_status := 'E';

Line 3169: fnd_file.put_line(fnd_file.log,'After reading costs from source organization, new_cost_tab is:');

3165: END IF;
3166:
3167: IF l_debug_level >= l_debug_level_medium
3168: THEN
3169: fnd_file.put_line(fnd_file.log,'After reading costs from source organization, new_cost_tab is:');
3170: FOR k IN 1 .. new_cost_tab.COUNT
3171: LOOP
3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

Line 3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

3168: THEN
3169: fnd_file.put_line(fnd_file.log,'After reading costs from source organization, new_cost_tab is:');
3170: FOR k IN 1 .. new_cost_tab.COUNT
3171: LOOP
3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3174: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3175: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3176: fnd_file.put_line(fnd_file.log,'====================================');

Line 3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

3169: fnd_file.put_line(fnd_file.log,'After reading costs from source organization, new_cost_tab is:');
3170: FOR k IN 1 .. new_cost_tab.COUNT
3171: LOOP
3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3174: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3175: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3176: fnd_file.put_line(fnd_file.log,'====================================');
3177: END LOOP;

Line 3174: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);

3170: FOR k IN 1 .. new_cost_tab.COUNT
3171: LOOP
3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3174: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3175: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3176: fnd_file.put_line(fnd_file.log,'====================================');
3177: END LOOP;
3178: END IF;

Line 3175: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

3171: LOOP
3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3174: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3175: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3176: fnd_file.put_line(fnd_file.log,'====================================');
3177: END LOOP;
3178: END IF;
3179:

Line 3176: fnd_file.put_line(fnd_file.log,'====================================');

3172: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
3173: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
3174: fnd_file.put_line(fnd_file.log,'Level ['||k||']: '||new_cost_tab(k).cost_level);
3175: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
3176: fnd_file.put_line(fnd_file.log,'====================================');
3177: END LOOP;
3178: END IF;
3179:
3180:

Line 3183: fnd_file.put_line

3179:
3180:
3181: IF NOT new_cost_tab.EXISTS(1)
3182: THEN
3183: fnd_file.put_line
3184: ( fnd_file.log,'ERROR: Unable to locate source cost details for organization: '||l_org_tab(p_source_orgn)
3185: ||', inventory item ID: '||transaction_row.inventory_item_id
3186: ||', lot number: '||transaction_row.lot_number /* INVCONV sschinch */
3187: );

Line 3184: ( fnd_file.log,'ERROR: Unable to locate source cost details for organization: '||l_org_tab(p_source_orgn)

3180:
3181: IF NOT new_cost_tab.EXISTS(1)
3182: THEN
3183: fnd_file.put_line
3184: ( fnd_file.log,'ERROR: Unable to locate source cost details for organization: '||l_org_tab(p_source_orgn)
3185: ||', inventory item ID: '||transaction_row.inventory_item_id
3186: ||', lot number: '||transaction_row.lot_number /* INVCONV sschinch */
3187: );
3188: l_return_status := 'E';

Line 3195: fnd_file.put_line( fnd_file.log,'ERROR: Unable to locate source primary quantity and primary uom for the transfer transaction id: '||

3191:
3192: OPEN get_src_qty_uom;
3193: FETCH get_src_qty_uom INTO l_src_qty, l_src_uom;
3194: IF get_src_qty_uom%NOTFOUND THEN
3195: fnd_file.put_line( fnd_file.log,'ERROR: Unable to locate source primary quantity and primary uom for the transfer transaction id: '||
3196: transaction_row.transfer_transaction_id);
3197: l_return_status := 'E';
3198: CLOSE get_src_qty_uom;
3199: RETURN;

Line 3204: fnd_file.put_line( fnd_file.log,'Source primary uom: '||l_src_uom||' and Receiving primary uom: '||transaction_row.trans_um||

3200: END IF;
3201: CLOSE get_src_qty_uom;
3202:
3203: IF l_src_uom <> transaction_row.trans_um THEN
3204: fnd_file.put_line( fnd_file.log,'Source primary uom: '||l_src_uom||' and Receiving primary uom: '||transaction_row.trans_um||
3205: ' are different');
3206: IF transaction_row.trans_qty <> 0 THEN
3207: l_cost_ratio := (l_src_qty * -1)/transaction_row.trans_qty;
3208: fnd_file.put_line(fnd_file.log,'Source primary qty: '||l_src_qty||', Receiving primary qty: '||transaction_row.trans_qty||

Line 3208: fnd_file.put_line(fnd_file.log,'Source primary qty: '||l_src_qty||', Receiving primary qty: '||transaction_row.trans_qty||

3204: fnd_file.put_line( fnd_file.log,'Source primary uom: '||l_src_uom||' and Receiving primary uom: '||transaction_row.trans_um||
3205: ' are different');
3206: IF transaction_row.trans_qty <> 0 THEN
3207: l_cost_ratio := (l_src_qty * -1)/transaction_row.trans_qty;
3208: fnd_file.put_line(fnd_file.log,'Source primary qty: '||l_src_qty||', Receiving primary qty: '||transaction_row.trans_qty||
3209: ', cost ratio: '||l_cost_ratio);
3210: ELSE
3211: l_cost_ratio := 0;
3212: fnd_file.put_line(fnd_file.log,'Transaction qty is zero, so making cost ratio as zero');

Line 3212: fnd_file.put_line(fnd_file.log,'Transaction qty is zero, so making cost ratio as zero');

3208: fnd_file.put_line(fnd_file.log,'Source primary qty: '||l_src_qty||', Receiving primary qty: '||transaction_row.trans_qty||
3209: ', cost ratio: '||l_cost_ratio);
3210: ELSE
3211: l_cost_ratio := 0;
3212: fnd_file.put_line(fnd_file.log,'Transaction qty is zero, so making cost ratio as zero');
3213: END IF;
3214:
3215: FOR i IN 1 .. new_cost_tab.COUNT
3216: LOOP

Line 3221: fnd_file.put_line( fnd_file.log,'Source primary uom: '||l_src_uom||' and Receiving primary uom: '||transaction_row.trans_um||

3217: new_cost_tab(i).component_cost := new_cost_tab(i).component_cost * l_cost_ratio;
3218: END LOOP;
3219:
3220: ELSE
3221: fnd_file.put_line( fnd_file.log,'Source primary uom: '||l_src_uom||' and Receiving primary uom: '||transaction_row.trans_um||
3222: ' are same');
3223: l_cost_ratio := 1;
3224: END IF;
3225:

Line 3264: fnd_file.put_line

3260:
3261:
3262: IF l_error_status <> 0
3263: THEN
3264: fnd_file.put_line
3265: ( fnd_file.log
3266: , 'ERROR: Unable to find exchange rate from '||l_from_ccy_code
3267: ||' to '||l_to_ccy_code
3268: ||' on '||transaction_row.trans_date

Line 3265: ( fnd_file.log

3261:
3262: IF l_error_status <> 0
3263: THEN
3264: fnd_file.put_line
3265: ( fnd_file.log
3266: , 'ERROR: Unable to find exchange rate from '||l_from_ccy_code
3267: ||' to '||l_to_ccy_code
3268: ||' on '||transaction_row.trans_date
3269: );

Line 3285: fnd_file.put_line

3281: IF l_burdens_total <> 0
3282: THEN
3283: IF l_debug_level >= l_debug_level_medium
3284: THEN
3285: fnd_file.put_line
3286: (fnd_file.log,'Combining burden costs');
3287: END IF;
3288:
3289: merge_costs( l_burden_costs_tab

Line 3286: (fnd_file.log,'Combining burden costs');

3282: THEN
3283: IF l_debug_level >= l_debug_level_medium
3284: THEN
3285: fnd_file.put_line
3286: (fnd_file.log,'Combining burden costs');
3287: END IF;
3288:
3289: merge_costs( l_burden_costs_tab
3290: , 1

Line 3306: fnd_file.put_line

3302: prd_cost_tab := new_cost_tab;
3303:
3304: IF l_debug_level >= l_debug_level_medium
3305: THEN
3306: fnd_file.put_line
3307: (fnd_file.log,'Aggregating old costs with new costs');
3308: END IF;
3309:
3310: merge_costs( old_cost_tab

Line 3307: (fnd_file.log,'Aggregating old costs with new costs');

3303:
3304: IF l_debug_level >= l_debug_level_medium
3305: THEN
3306: fnd_file.put_line
3307: (fnd_file.log,'Aggregating old costs with new costs');
3308: END IF;
3309:
3310: merge_costs( old_cost_tab
3311: , old_cost.onhand_qty

Line 3336: fnd_file.put_line

3332: IF l_return_status = 'S'
3333: THEN
3334: IF l_debug_level >= l_debug_level_medium
3335: THEN
3336: fnd_file.put_line
3337: (fnd_file.log,'Creating new cost detail rows');
3338: END IF;
3339:
3340: -- Bug 3388974

Line 3337: (fnd_file.log,'Creating new cost detail rows');

3333: THEN
3334: IF l_debug_level >= l_debug_level_medium
3335: THEN
3336: fnd_file.put_line
3337: (fnd_file.log,'Creating new cost detail rows');
3338: END IF;
3339:
3340: -- Bug 3388974
3341: new_cost.header_id := l_header_id;

Line 3365: fnd_file.put_line

3361: END LOOP;
3362:
3363: IF l_debug_level >= l_debug_level_medium
3364: THEN
3365: fnd_file.put_line
3366: (fnd_file.log,'Creating new material cost transaction');
3367: END IF;
3368:
3369:

Line 3366: (fnd_file.log,'Creating new material cost transaction');

3362:
3363: IF l_debug_level >= l_debug_level_medium
3364: THEN
3365: fnd_file.put_line
3366: (fnd_file.log,'Creating new material cost transaction');
3367: END IF;
3368:
3369:
3370: IF NOT old_cost_tab.EXISTS(1)

Line 3374: fnd_file.put_line (fnd_file.log,'AAAAA');

3370: IF NOT old_cost_tab.EXISTS(1)
3371: THEN
3372: IF l_debug_level >= l_debug_level_high
3373: THEN
3374: fnd_file.put_line (fnd_file.log,'AAAAA');
3375: END IF;
3376:
3377: create_material_transaction
3378: ( new_cost.header_id

Line 3397: fnd_file.put_line (fnd_file.log,'BBBBB');

3393:
3394: ELSE
3395: IF l_debug_level >= l_debug_level_high
3396: THEN
3397: fnd_file.put_line (fnd_file.log,'BBBBB');
3398: END IF;
3399: create_material_transaction
3400: ( new_cost.header_id
3401: , l_cost_type_id

Line 3443: fnd_file.put_line

3439: END IF; /* get cost */
3440: END IF; /* Line type */
3441: IF l_debug_level >= l_debug_level_medium
3442: THEN
3443: fnd_file.put_line
3444: (fnd_file.log,'Leaving Procedure: '||procedure_name);
3445: END IF;
3446: EXCEPTION
3447: WHEN OTHERS THEN

Line 3444: (fnd_file.log,'Leaving Procedure: '||procedure_name);

3440: END IF; /* Line type */
3441: IF l_debug_level >= l_debug_level_medium
3442: THEN
3443: fnd_file.put_line
3444: (fnd_file.log,'Leaving Procedure: '||procedure_name);
3445: END IF;
3446: EXCEPTION
3447: WHEN OTHERS THEN
3448: fnd_file.put_line

Line 3448: fnd_file.put_line

3444: (fnd_file.log,'Leaving Procedure: '||procedure_name);
3445: END IF;
3446: EXCEPTION
3447: WHEN OTHERS THEN
3448: fnd_file.put_line
3449: (fnd_file.log,'Failed in procedure Process Movement with error');
3450: fnd_file.put_line
3451: (fnd_file.log,SQLERRM);
3452: l_return_status := 'U';

Line 3449: (fnd_file.log,'Failed in procedure Process Movement with error');

3445: END IF;
3446: EXCEPTION
3447: WHEN OTHERS THEN
3448: fnd_file.put_line
3449: (fnd_file.log,'Failed in procedure Process Movement with error');
3450: fnd_file.put_line
3451: (fnd_file.log,SQLERRM);
3452: l_return_status := 'U';
3453:

Line 3450: fnd_file.put_line

3446: EXCEPTION
3447: WHEN OTHERS THEN
3448: fnd_file.put_line
3449: (fnd_file.log,'Failed in procedure Process Movement with error');
3450: fnd_file.put_line
3451: (fnd_file.log,SQLERRM);
3452: l_return_status := 'U';
3453:
3454: END process_movement;

Line 3451: (fnd_file.log,SQLERRM);

3447: WHEN OTHERS THEN
3448: fnd_file.put_line
3449: (fnd_file.log,'Failed in procedure Process Movement with error');
3450: fnd_file.put_line
3451: (fnd_file.log,SQLERRM);
3452: l_return_status := 'U';
3453:
3454: END process_movement;
3455:

Line 3486: fnd_file.put_line

3482: BEGIN
3483: procedure_name := 'Process Receipt';
3484: IF l_debug_level >= l_debug_level_medium
3485: THEN
3486: fnd_file.put_line
3487: (fnd_file.log,'Entered Procedure: '||procedure_name);
3488: END IF;
3489:
3490: IF l_debug_level >= l_debug_level_medium

Line 3487: (fnd_file.log,'Entered Procedure: '||procedure_name);

3483: procedure_name := 'Process Receipt';
3484: IF l_debug_level >= l_debug_level_medium
3485: THEN
3486: fnd_file.put_line
3487: (fnd_file.log,'Entered Procedure: '||procedure_name);
3488: END IF;
3489:
3490: IF l_debug_level >= l_debug_level_medium
3491: THEN

Line 3492: fnd_file.put_line

3488: END IF;
3489:
3490: IF l_debug_level >= l_debug_level_medium
3491: THEN
3492: fnd_file.put_line
3493: (fnd_file.log,'PO Receipt found: transaction ID = '||to_char(transaction_row.transaction_id));
3494: END IF;
3495:
3496: -- The pointers in the inventory transaction link to the receipt as follows:

Line 3493: (fnd_file.log,'PO Receipt found: transaction ID = '||to_char(transaction_row.transaction_id));

3489:
3490: IF l_debug_level >= l_debug_level_medium
3491: THEN
3492: fnd_file.put_line
3493: (fnd_file.log,'PO Receipt found: transaction ID = '||to_char(transaction_row.transaction_id));
3494: END IF;
3495:
3496: -- The pointers in the inventory transaction link to the receipt as follows:
3497: -- DOC_ID is the SHIPMENT_HEADER_ID in rcv_shipment_headers

Line 3518: fnd_file.put_line

3514:
3515:
3516: IF l_debug_level >= l_debug_level_medium
3517: THEN
3518: fnd_file.put_line
3519: (fnd_file.log,' Retrieving receipt details');
3520: END IF;
3521:
3522: -- Now using source_doc_unit_of_measure instead of unit_of_measure

Line 3519: (fnd_file.log,' Retrieving receipt details');

3515:
3516: IF l_debug_level >= l_debug_level_medium
3517: THEN
3518: fnd_file.put_line
3519: (fnd_file.log,' Retrieving receipt details');
3520: END IF;
3521:
3522: -- Now using source_doc_unit_of_measure instead of unit_of_measure
3523:

Line 3558: fnd_file.put_line (fnd_file.log,' Converting Receipt_unit_cost : '||receipt_unit_cost||' Receipt Currency : '||receipt_ccy||

3554:
3555: IF ( l_base_ccy_code <> receipt_ccy) THEN /* Check if the receipt currency is the same as the base currency */
3556: IF l_debug_level >= l_debug_level_medium
3557: THEN
3558: fnd_file.put_line (fnd_file.log,' Converting Receipt_unit_cost : '||receipt_unit_cost||' Receipt Currency : '||receipt_ccy||
3559: ' to Base Currency : '||l_base_ccy_code||'. New_receipt_unit_cost : '||receipt_unit_cost * l_exchange_rate||'. Exchange Rate is : '||l_exchange_rate);
3560: END IF;
3561:
3562: receipt_unit_cost := receipt_unit_cost * l_exchange_rate;

Line 3574: fnd_file.put_line

3570: IF document_code = 'RMA'
3571: THEN
3572: IF l_debug_level >= l_debug_level_medium
3573: THEN
3574: fnd_file.put_line
3575: (fnd_file.log,' Processing PORC txn as an RMA');
3576: END IF;
3577: process_adjustment;
3578: RETURN;

Line 3575: (fnd_file.log,' Processing PORC txn as an RMA');

3571: THEN
3572: IF l_debug_level >= l_debug_level_medium
3573: THEN
3574: fnd_file.put_line
3575: (fnd_file.log,' Processing PORC txn as an RMA');
3576: END IF;
3577: process_adjustment;
3578: RETURN;
3579: END IF;

Line 3668: fnd_file.put_line

3664: -- If we reach here the PORC transaction is for a true PO Receipt
3665:
3666: IF receipt_unit_cost IS NULL
3667: THEN
3668: fnd_file.put_line
3669: (fnd_file.log,'ERROR: Could not retrieve PO unit price for transaction ID '||to_char(transaction_row.transaction_id));
3670: l_return_status := 'E';
3671: RETURN;
3672: END IF;

Line 3669: (fnd_file.log,'ERROR: Could not retrieve PO unit price for transaction ID '||to_char(transaction_row.transaction_id));

3665:
3666: IF receipt_unit_cost IS NULL
3667: THEN
3668: fnd_file.put_line
3669: (fnd_file.log,'ERROR: Could not retrieve PO unit price for transaction ID '||to_char(transaction_row.transaction_id));
3670: l_return_status := 'E';
3671: RETURN;
3672: END IF;
3673:

Line 3676: fnd_file.put_line

3672: END IF;
3673:
3674: IF l_debug_level >= l_debug_level_medium
3675: THEN
3676: fnd_file.put_line
3677: (fnd_file.log,'Received '||transaction_row.trans_qty ||' '||transaction_row.trans_um
3678: ||' at a unit price of '||l_base_ccy_code||' '||to_char(receipt_unit_cost)); /* Bug 4038722 - Changed the receipt_ccy to l_base_ccy_code. */
3679: END IF;
3680:

Line 3677: (fnd_file.log,'Received '||transaction_row.trans_qty ||' '||transaction_row.trans_um

3673:
3674: IF l_debug_level >= l_debug_level_medium
3675: THEN
3676: fnd_file.put_line
3677: (fnd_file.log,'Received '||transaction_row.trans_qty ||' '||transaction_row.trans_um
3678: ||' at a unit price of '||l_base_ccy_code||' '||to_char(receipt_unit_cost)); /* Bug 4038722 - Changed the receipt_ccy to l_base_ccy_code. */
3679: END IF;
3680:
3681: IF transaction_row.trans_um <> receipt_uom

Line 3698: fnd_file.put_line

3694: ,TO_NAME => NULL
3695: );
3696: IF lot_unit_cost < 0
3697: THEN
3698: fnd_file.put_line
3699: (fnd_file.log,'ERROR: Could not convert PO receipt uom for transaction ID '||to_char(transaction_row.transaction_id));
3700: l_return_status := 'E';
3701: RETURN;
3702: END IF;

Line 3699: (fnd_file.log,'ERROR: Could not convert PO receipt uom for transaction ID '||to_char(transaction_row.transaction_id));

3695: );
3696: IF lot_unit_cost < 0
3697: THEN
3698: fnd_file.put_line
3699: (fnd_file.log,'ERROR: Could not convert PO receipt uom for transaction ID '||to_char(transaction_row.transaction_id));
3700: l_return_status := 'E';
3701: RETURN;
3702: END IF;
3703:

Line 3710: fnd_file.put_line(fnd_file.log,'Retrieving burdens for receipt');

3706: END IF;
3707:
3708: IF l_debug_level >= l_debug_level_medium
3709: THEN
3710: fnd_file.put_line(fnd_file.log,'Retrieving burdens for receipt');
3711: END IF;
3712:
3713: process_burdens;
3714:

Line 3722: fnd_file.put_line(fnd_file.log,'Retrieving Freight and special charges for receipt');

3718: END IF;
3719:
3720: IF l_debug_level >= l_debug_level_medium
3721: THEN
3722: fnd_file.put_line(fnd_file.log,'Retrieving Freight and special charges for receipt');
3723: END IF;
3724:
3725: get_special_charges;
3726:

Line 3734: fnd_file.put_line

3730: END IF;
3731:
3732: IF l_debug_level >= l_debug_level_medium
3733: THEN
3734: fnd_file.put_line
3735: (fnd_file.log,'Retrieving component class and analysis code for cost details');
3736: END IF;
3737:
3738: OPEN component_class_cursor

Line 3735: (fnd_file.log,'Retrieving component class and analysis code for cost details');

3731:
3732: IF l_debug_level >= l_debug_level_medium
3733: THEN
3734: fnd_file.put_line
3735: (fnd_file.log,'Retrieving component class and analysis code for cost details');
3736: END IF;
3737:
3738: OPEN component_class_cursor
3739: (l_le_id, transaction_row.inventory_item_id, transaction_row.orgn_id,transaction_row.trans_date);

Line 3745: fnd_file.put_line

3741: CLOSE component_class_cursor;
3742:
3743: IF l_debug_level >= l_debug_level_medium
3744: THEN
3745: fnd_file.put_line
3746: (fnd_file.log,'Setting up lot cost of PO receipt');
3747: END IF;
3748:
3749: IF l_debug_level >= l_debug_level_medium

Line 3746: (fnd_file.log,'Setting up lot cost of PO receipt');

3742:
3743: IF l_debug_level >= l_debug_level_medium
3744: THEN
3745: fnd_file.put_line
3746: (fnd_file.log,'Setting up lot cost of PO receipt');
3747: END IF;
3748:
3749: IF l_debug_level >= l_debug_level_medium
3750: THEN

Line 3751: fnd_file.put_line

3747: END IF;
3748:
3749: IF l_debug_level >= l_debug_level_medium
3750: THEN
3751: fnd_file.put_line
3752: (fnd_file.log,'Lot cost of PO Receipt is: ' || to_char(lot_unit_cost));
3753: END IF;
3754:
3755:

Line 3752: (fnd_file.log,'Lot cost of PO Receipt is: ' || to_char(lot_unit_cost));

3748:
3749: IF l_debug_level >= l_debug_level_medium
3750: THEN
3751: fnd_file.put_line
3752: (fnd_file.log,'Lot cost of PO Receipt is: ' || to_char(lot_unit_cost));
3753: END IF;
3754:
3755:
3756: IF l_debug_level >= l_debug_level_medium

Line 3758: fnd_file.put_line

3754:
3755:
3756: IF l_debug_level >= l_debug_level_medium
3757: THEN
3758: fnd_file.put_line
3759: (fnd_file.log,'Initialising new_cost_tab(1)' || to_char(lot_unit_cost));
3760: END IF;
3761:
3762: new_cost_tab(1) := SYSTEM.gmf_cost_type

Line 3759: (fnd_file.log,'Initialising new_cost_tab(1)' || to_char(lot_unit_cost));

3755:
3756: IF l_debug_level >= l_debug_level_medium
3757: THEN
3758: fnd_file.put_line
3759: (fnd_file.log,'Initialising new_cost_tab(1)' || to_char(lot_unit_cost));
3760: END IF;
3761:
3762: new_cost_tab(1) := SYSTEM.gmf_cost_type
3763: ( component_class_id

Line 3781: fnd_file.put_line

3777: THEN
3778:
3779: IF l_debug_level >= l_debug_level_medium
3780: THEN
3781: fnd_file.put_line
3782: (fnd_file.log,'Merging burden costs');
3783: END IF;
3784:
3785: merge_costs( l_burden_costs_tab

Line 3782: (fnd_file.log,'Merging burden costs');

3778:
3779: IF l_debug_level >= l_debug_level_medium
3780: THEN
3781: fnd_file.put_line
3782: (fnd_file.log,'Merging burden costs');
3783: END IF;
3784:
3785: merge_costs( l_burden_costs_tab
3786: , 0

Line 3798: fnd_file.put_line

3794: THEN
3795:
3796: IF l_debug_level >= l_debug_level_medium
3797: THEN
3798: fnd_file.put_line
3799: (fnd_file.log,'Merging acquisition costs');
3800: END IF;
3801:
3802: merge_costs( l_acqui_cost_tab

Line 3799: (fnd_file.log,'Merging acquisition costs');

3795:
3796: IF l_debug_level >= l_debug_level_medium
3797: THEN
3798: fnd_file.put_line
3799: (fnd_file.log,'Merging acquisition costs');
3800: END IF;
3801:
3802: merge_costs( l_acqui_cost_tab
3803: , 0

Line 3816: fnd_file.put_line

3812: l_onhand_qty := transaction_row.trans_qty;
3813:
3814: IF l_debug_level >= l_debug_level_medium
3815: THEN
3816: fnd_file.put_line
3817: (fnd_file.log,'Finished setting up costs for PO Receipt. Lot unit cost is:'||to_char(lot_unit_cost));
3818: END IF;
3819: ELSE
3820: IF l_debug_level >= l_debug_level_medium

Line 3817: (fnd_file.log,'Finished setting up costs for PO Receipt. Lot unit cost is:'||to_char(lot_unit_cost));

3813:
3814: IF l_debug_level >= l_debug_level_medium
3815: THEN
3816: fnd_file.put_line
3817: (fnd_file.log,'Finished setting up costs for PO Receipt. Lot unit cost is:'||to_char(lot_unit_cost));
3818: END IF;
3819: ELSE
3820: IF l_debug_level >= l_debug_level_medium
3821: THEN

Line 3822: fnd_file.put_line

3818: END IF;
3819: ELSE
3820: IF l_debug_level >= l_debug_level_medium
3821: THEN
3822: fnd_file.put_line
3823: (fnd_file.log,'Merging old costs with new cost');
3824: END IF;
3825:
3826: IF l_burdens_total <> 0

Line 3823: (fnd_file.log,'Merging old costs with new cost');

3819: ELSE
3820: IF l_debug_level >= l_debug_level_medium
3821: THEN
3822: fnd_file.put_line
3823: (fnd_file.log,'Merging old costs with new cost');
3824: END IF;
3825:
3826: IF l_burdens_total <> 0
3827: THEN

Line 3830: fnd_file.put_line

3826: IF l_burdens_total <> 0
3827: THEN
3828: IF l_debug_level >= l_debug_level_medium
3829: THEN
3830: fnd_file.put_line
3831: (fnd_file.log,'Merging burden costs');
3832: END IF;
3833:
3834: merge_costs( l_burden_costs_tab

Line 3831: (fnd_file.log,'Merging burden costs');

3827: THEN
3828: IF l_debug_level >= l_debug_level_medium
3829: THEN
3830: fnd_file.put_line
3831: (fnd_file.log,'Merging burden costs');
3832: END IF;
3833:
3834: merge_costs( l_burden_costs_tab
3835: , transaction_row.trans_qty

Line 3847: fnd_file.put_line (fnd_file.log,'Merging Special Charges');

3843: THEN
3844:
3845: IF l_debug_level >= l_debug_level_medium
3846: THEN
3847: fnd_file.put_line (fnd_file.log,'Merging Special Charges');
3848: END IF;
3849:
3850: merge_costs( l_acqui_cost_tab
3851: , transaction_row.trans_qty

Line 3870: fnd_file.put_line(fnd_file.log,'Lot_unit_cost = '||lot_unit_cost);

3866: );
3867:
3868: IF l_debug_level >= l_debug_level_medium
3869: THEN
3870: fnd_file.put_line(fnd_file.log,'Lot_unit_cost = '||lot_unit_cost);
3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);
3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);
3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);
3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);

Line 3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);

3867:
3868: IF l_debug_level >= l_debug_level_medium
3869: THEN
3870: fnd_file.put_line(fnd_file.log,'Lot_unit_cost = '||lot_unit_cost);
3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);
3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);
3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);
3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);
3875: fnd_file.put_line(fnd_file.log,'trans_qty = '||transaction_row.trans_qty);

Line 3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);

3868: IF l_debug_level >= l_debug_level_medium
3869: THEN
3870: fnd_file.put_line(fnd_file.log,'Lot_unit_cost = '||lot_unit_cost);
3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);
3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);
3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);
3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);
3875: fnd_file.put_line(fnd_file.log,'trans_qty = '||transaction_row.trans_qty);
3876: END IF;

Line 3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);

3869: THEN
3870: fnd_file.put_line(fnd_file.log,'Lot_unit_cost = '||lot_unit_cost);
3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);
3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);
3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);
3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);
3875: fnd_file.put_line(fnd_file.log,'trans_qty = '||transaction_row.trans_qty);
3876: END IF;
3877:

Line 3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);

3870: fnd_file.put_line(fnd_file.log,'Lot_unit_cost = '||lot_unit_cost);
3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);
3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);
3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);
3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);
3875: fnd_file.put_line(fnd_file.log,'trans_qty = '||transaction_row.trans_qty);
3876: END IF;
3877:
3878: lot_unit_cost := new_cost.unit_cost;

Line 3875: fnd_file.put_line(fnd_file.log,'trans_qty = '||transaction_row.trans_qty);

3871: fnd_file.put_line(fnd_file.log,'l_burdens_total = '||l_burdens_total);
3872: fnd_file.put_line(fnd_file.log,'l_acquisitions_total = '||l_acquisitions_total);
3873: fnd_file.put_line(fnd_file.log,'old_onhand = '||old_cost.onhand_qty);
3874: fnd_file.put_line(fnd_file.log,'old_unit_cost = '||old_cost.unit_cost);
3875: fnd_file.put_line(fnd_file.log,'trans_qty = '||transaction_row.trans_qty);
3876: END IF;
3877:
3878: lot_unit_cost := new_cost.unit_cost;
3879:

Line 3882: fnd_file.put_line

3878: lot_unit_cost := new_cost.unit_cost;
3879:
3880: IF l_debug_level >= l_debug_level_medium
3881: THEN
3882: fnd_file.put_line
3883: (fnd_file.log,'Finished setting up revised costs for PO Receipt. Lot unit cost is:'||to_char(lot_unit_cost));
3884: END IF;
3885:
3886: l_onhand_qty := transaction_row.trans_qty + old_cost.onhand_qty;

Line 3883: (fnd_file.log,'Finished setting up revised costs for PO Receipt. Lot unit cost is:'||to_char(lot_unit_cost));

3879:
3880: IF l_debug_level >= l_debug_level_medium
3881: THEN
3882: fnd_file.put_line
3883: (fnd_file.log,'Finished setting up revised costs for PO Receipt. Lot unit cost is:'||to_char(lot_unit_cost));
3884: END IF;
3885:
3886: l_onhand_qty := transaction_row.trans_qty + old_cost.onhand_qty;
3887:

Line 3892: fnd_file.put_line

3888: END IF;
3889:
3890: IF l_debug_level >= l_debug_level_low
3891: THEN
3892: fnd_file.put_line
3893: (fnd_file.log,'Creating cost header row');
3894: END IF;
3895:
3896: create_cost_header

Line 3893: (fnd_file.log,'Creating cost header row');

3889:
3890: IF l_debug_level >= l_debug_level_low
3891: THEN
3892: fnd_file.put_line
3893: (fnd_file.log,'Creating cost header row');
3894: END IF;
3895:
3896: create_cost_header
3897: ( transaction_row.inventory_item_id

Line 3917: fnd_file.put_line

3913: IF l_return_status = 'S'
3914: THEN
3915: IF l_debug_level >= l_debug_level_medium
3916: THEN
3917: fnd_file.put_line
3918: (fnd_file.log,'Creating cost detail rows');
3919: END IF;
3920:
3921: FOR i in 1 .. new_cost_tab.COUNT

Line 3918: (fnd_file.log,'Creating cost detail rows');

3914: THEN
3915: IF l_debug_level >= l_debug_level_medium
3916: THEN
3917: fnd_file.put_line
3918: (fnd_file.log,'Creating cost detail rows');
3919: END IF;
3920:
3921: FOR i in 1 .. new_cost_tab.COUNT
3922: LOOP

Line 3944: fnd_file.put_line

3940: IF l_return_status = 'S'
3941: THEN
3942: IF l_debug_level >= l_debug_level_medium
3943: THEN
3944: fnd_file.put_line
3945: (fnd_file.log,'Creating cost transaction');
3946: END IF;
3947:
3948: IF NOT old_cost_tab.EXISTS(1)

Line 3945: (fnd_file.log,'Creating cost transaction');

3941: THEN
3942: IF l_debug_level >= l_debug_level_medium
3943: THEN
3944: fnd_file.put_line
3945: (fnd_file.log,'Creating cost transaction');
3946: END IF;
3947:
3948: IF NOT old_cost_tab.EXISTS(1)
3949: THEN

Line 4010: fnd_file.put_line

4006: END IF;
4007: END IF;
4008: IF l_debug_level >= l_debug_level_medium
4009: THEN
4010: fnd_file.put_line
4011: (fnd_file.log,'Leaving Procedure: '||procedure_name);
4012: END IF;
4013: END process_receipt;
4014:

Line 4011: (fnd_file.log,'Leaving Procedure: '||procedure_name);

4007: END IF;
4008: IF l_debug_level >= l_debug_level_medium
4009: THEN
4010: fnd_file.put_line
4011: (fnd_file.log,'Leaving Procedure: '||procedure_name);
4012: END IF;
4013: END process_receipt;
4014:
4015:

Line 4054: fnd_file.put_line

4050: BEGIN
4051: procedure_name := 'Lot Cost Audit';
4052: IF l_debug_level >= l_debug_level_medium
4053: THEN
4054: fnd_file.put_line
4055: (fnd_file.log,'Entered Procedure: '||procedure_name);
4056: END IF;
4057:
4058: -- Retrieve data in a form that the user will understand

Line 4055: (fnd_file.log,'Entered Procedure: '||procedure_name);

4051: procedure_name := 'Lot Cost Audit';
4052: IF l_debug_level >= l_debug_level_medium
4053: THEN
4054: fnd_file.put_line
4055: (fnd_file.log,'Entered Procedure: '||procedure_name);
4056: END IF;
4057:
4058: -- Retrieve data in a form that the user will understand
4059:

Line 4066: fnd_file.put_line

4062: WHERE inventory_item_id = p_item_id AND organization_id = p_orgn_id;
4063:
4064:
4065:
4066: fnd_file.put_line
4067: (fnd_file.log, 'Lot cost breakdown for item '
4068: ||l_item_no
4069: ||' lot '
4070: ||l_lot_number

Line 4067: (fnd_file.log, 'Lot cost breakdown for item '

4063:
4064:
4065:
4066: fnd_file.put_line
4067: (fnd_file.log, 'Lot cost breakdown for item '
4068: ||l_item_no
4069: ||' lot '
4070: ||l_lot_number
4071: ||' created by batch '

Line 4081: fnd_file.put_line

4077: ||' on '
4078: ||to_char(p_date_costed)
4079: );
4080:
4081: fnd_file.put_line
4082: (fnd_file.log, '==============================================================================================');
4083:
4084: --
4085: -- umoogala 26-dec-03: program is failing with ORA error when there are no batch steps

Line 4082: (fnd_file.log, '==============================================================================================');

4078: ||to_char(p_date_costed)
4079: );
4080:
4081: fnd_file.put_line
4082: (fnd_file.log, '==============================================================================================');
4083:
4084: --
4085: -- umoogala 26-dec-03: program is failing with ORA error when there are no batch steps
4086: --

Line 4089: fnd_file.put_line

4085: -- umoogala 26-dec-03: program is failing with ORA error when there are no batch steps
4086: --
4087: IF NOT l_step_tab.EXISTS(1)
4088: THEN
4089: fnd_file.put_line
4090: (fnd_file.log,'No batch steps to print.');
4091: RETURN;
4092: END IF;
4093:

Line 4090: (fnd_file.log,'No batch steps to print.');

4086: --
4087: IF NOT l_step_tab.EXISTS(1)
4088: THEN
4089: fnd_file.put_line
4090: (fnd_file.log,'No batch steps to print.');
4091: RETURN;
4092: END IF;
4093:
4094: fnd_file.put_line

Line 4094: fnd_file.put_line

4090: (fnd_file.log,'No batch steps to print.');
4091: RETURN;
4092: END IF;
4093:
4094: fnd_file.put_line
4095: (fnd_file.log,' ');
4096:
4097: FOR i IN 1..l_step_tab.count
4098: LOOP

Line 4095: (fnd_file.log,' ');

4091: RETURN;
4092: END IF;
4093:
4094: fnd_file.put_line
4095: (fnd_file.log,' ');
4096:
4097: FOR i IN 1..l_step_tab.count
4098: LOOP
4099: fnd_file.put_line

Line 4099: fnd_file.put_line

4095: (fnd_file.log,' ');
4096:
4097: FOR i IN 1..l_step_tab.count
4098: LOOP
4099: fnd_file.put_line
4100: (fnd_file.log,'Dump of step index '||to_char(i));
4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line

Line 4100: (fnd_file.log,'Dump of step index '||to_char(i));

4096:
4097: FOR i IN 1..l_step_tab.count
4098: LOOP
4099: fnd_file.put_line
4100: (fnd_file.log,'Dump of step index '||to_char(i));
4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));

Line 4101: fnd_file.put_line

4097: FOR i IN 1..l_step_tab.count
4098: LOOP
4099: fnd_file.put_line
4100: (fnd_file.log,'Dump of step index '||to_char(i));
4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line

Line 4102: (fnd_file.log,'---------------------');

4098: LOOP
4099: fnd_file.put_line
4100: (fnd_file.log,'Dump of step index '||to_char(i));
4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '

Line 4103: fnd_file.put_line

4099: fnd_file.put_line
4100: (fnd_file.log,'Dump of step index '||to_char(i));
4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '
4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);

Line 4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));

4100: (fnd_file.log,'Dump of step index '||to_char(i));
4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '
4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);
4108: fnd_file.put_line

Line 4105: fnd_file.put_line

4101: fnd_file.put_line
4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '
4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);
4108: fnd_file.put_line
4109: (fnd_file.log,'Output qty = '

Line 4106: (fnd_file.log,'Step qty = '

4102: (fnd_file.log,'---------------------');
4103: fnd_file.put_line
4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '
4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);
4108: fnd_file.put_line
4109: (fnd_file.log,'Output qty = '
4110: ||to_char(ROUND(l_step_tab(i).output_qty,2))||' '||l_step_tab(i).step_qty_uom);

Line 4108: fnd_file.put_line

4104: (fnd_file.log,'Step ID = '||to_char(l_step_tab(i).current_step_id));
4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '
4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);
4108: fnd_file.put_line
4109: (fnd_file.log,'Output qty = '
4110: ||to_char(ROUND(l_step_tab(i).output_qty,2))||' '||l_step_tab(i).step_qty_uom);
4111: fnd_file.put_line
4112: (fnd_file.log,' ');

Line 4109: (fnd_file.log,'Output qty = '

4105: fnd_file.put_line
4106: (fnd_file.log,'Step qty = '
4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);
4108: fnd_file.put_line
4109: (fnd_file.log,'Output qty = '
4110: ||to_char(ROUND(l_step_tab(i).output_qty,2))||' '||l_step_tab(i).step_qty_uom);
4111: fnd_file.put_line
4112: (fnd_file.log,' ');
4113:

Line 4111: fnd_file.put_line

4107: ||to_char(ROUND(l_step_tab(i).step_qty,2))||' '||l_step_tab(i).step_qty_uom);
4108: fnd_file.put_line
4109: (fnd_file.log,'Output qty = '
4110: ||to_char(ROUND(l_step_tab(i).output_qty,2))||' '||l_step_tab(i).step_qty_uom);
4111: fnd_file.put_line
4112: (fnd_file.log,' ');
4113:
4114: fnd_file.put_line
4115: (fnd_file.log,' Current Costs');

Line 4112: (fnd_file.log,' ');

4108: fnd_file.put_line
4109: (fnd_file.log,'Output qty = '
4110: ||to_char(ROUND(l_step_tab(i).output_qty,2))||' '||l_step_tab(i).step_qty_uom);
4111: fnd_file.put_line
4112: (fnd_file.log,' ');
4113:
4114: fnd_file.put_line
4115: (fnd_file.log,' Current Costs');
4116: fnd_file.put_line

Line 4114: fnd_file.put_line

4110: ||to_char(ROUND(l_step_tab(i).output_qty,2))||' '||l_step_tab(i).step_qty_uom);
4111: fnd_file.put_line
4112: (fnd_file.log,' ');
4113:
4114: fnd_file.put_line
4115: (fnd_file.log,' Current Costs');
4116: fnd_file.put_line
4117: (fnd_file.log,' -------------');
4118:

Line 4115: (fnd_file.log,' Current Costs');

4111: fnd_file.put_line
4112: (fnd_file.log,' ');
4113:
4114: fnd_file.put_line
4115: (fnd_file.log,' Current Costs');
4116: fnd_file.put_line
4117: (fnd_file.log,' -------------');
4118:
4119: IF l_step_tab(i).current_costs.EXISTS(1)

Line 4116: fnd_file.put_line

4112: (fnd_file.log,' ');
4113:
4114: fnd_file.put_line
4115: (fnd_file.log,' Current Costs');
4116: fnd_file.put_line
4117: (fnd_file.log,' -------------');
4118:
4119: IF l_step_tab(i).current_costs.EXISTS(1)
4120: THEN

Line 4117: (fnd_file.log,' -------------');

4113:
4114: fnd_file.put_line
4115: (fnd_file.log,' Current Costs');
4116: fnd_file.put_line
4117: (fnd_file.log,' -------------');
4118:
4119: IF l_step_tab(i).current_costs.EXISTS(1)
4120: THEN
4121: FOR j IN 1..l_step_tab(i).current_costs.count

Line 4123: fnd_file.put_line

4119: IF l_step_tab(i).current_costs.EXISTS(1)
4120: THEN
4121: FOR j IN 1..l_step_tab(i).current_costs.count
4122: LOOP
4123: fnd_file.put_line
4124: (fnd_file.log,' Component Class ID = '
4125: ||to_char(l_step_tab(i).current_costs(j).cost_cmpntcls_id));
4126: fnd_file.put_line
4127: (fnd_file.log,' Cost Analysis Code = '

Line 4124: (fnd_file.log,' Component Class ID = '

4120: THEN
4121: FOR j IN 1..l_step_tab(i).current_costs.count
4122: LOOP
4123: fnd_file.put_line
4124: (fnd_file.log,' Component Class ID = '
4125: ||to_char(l_step_tab(i).current_costs(j).cost_cmpntcls_id));
4126: fnd_file.put_line
4127: (fnd_file.log,' Cost Analysis Code = '
4128: ||l_step_tab(i).current_costs(j).cost_analysis_code);

Line 4126: fnd_file.put_line

4122: LOOP
4123: fnd_file.put_line
4124: (fnd_file.log,' Component Class ID = '
4125: ||to_char(l_step_tab(i).current_costs(j).cost_cmpntcls_id));
4126: fnd_file.put_line
4127: (fnd_file.log,' Cost Analysis Code = '
4128: ||l_step_tab(i).current_costs(j).cost_analysis_code);
4129: fnd_file.put_line
4130: (fnd_file.log,' Cost Level = '

Line 4127: (fnd_file.log,' Cost Analysis Code = '

4123: fnd_file.put_line
4124: (fnd_file.log,' Component Class ID = '
4125: ||to_char(l_step_tab(i).current_costs(j).cost_cmpntcls_id));
4126: fnd_file.put_line
4127: (fnd_file.log,' Cost Analysis Code = '
4128: ||l_step_tab(i).current_costs(j).cost_analysis_code);
4129: fnd_file.put_line
4130: (fnd_file.log,' Cost Level = '
4131: ||to_char(l_step_tab(i).current_costs(j).cost_level));

Line 4129: fnd_file.put_line

4125: ||to_char(l_step_tab(i).current_costs(j).cost_cmpntcls_id));
4126: fnd_file.put_line
4127: (fnd_file.log,' Cost Analysis Code = '
4128: ||l_step_tab(i).current_costs(j).cost_analysis_code);
4129: fnd_file.put_line
4130: (fnd_file.log,' Cost Level = '
4131: ||to_char(l_step_tab(i).current_costs(j).cost_level));
4132: fnd_file.put_line
4133: (fnd_file.log,' Component Cost = '

Line 4130: (fnd_file.log,' Cost Level = '

4126: fnd_file.put_line
4127: (fnd_file.log,' Cost Analysis Code = '
4128: ||l_step_tab(i).current_costs(j).cost_analysis_code);
4129: fnd_file.put_line
4130: (fnd_file.log,' Cost Level = '
4131: ||to_char(l_step_tab(i).current_costs(j).cost_level));
4132: fnd_file.put_line
4133: (fnd_file.log,' Component Cost = '
4134: ||to_char(ROUND(l_step_tab(i).current_costs(j).component_cost,2)));

Line 4132: fnd_file.put_line

4128: ||l_step_tab(i).current_costs(j).cost_analysis_code);
4129: fnd_file.put_line
4130: (fnd_file.log,' Cost Level = '
4131: ||to_char(l_step_tab(i).current_costs(j).cost_level));
4132: fnd_file.put_line
4133: (fnd_file.log,' Component Cost = '
4134: ||to_char(ROUND(l_step_tab(i).current_costs(j).component_cost,2)));
4135: fnd_file.put_line(fnd_file.log,' ');
4136: END LOOP;

Line 4133: (fnd_file.log,' Component Cost = '

4129: fnd_file.put_line
4130: (fnd_file.log,' Cost Level = '
4131: ||to_char(l_step_tab(i).current_costs(j).cost_level));
4132: fnd_file.put_line
4133: (fnd_file.log,' Component Cost = '
4134: ||to_char(ROUND(l_step_tab(i).current_costs(j).component_cost,2)));
4135: fnd_file.put_line(fnd_file.log,' ');
4136: END LOOP;
4137: ELSE

Line 4135: fnd_file.put_line(fnd_file.log,' ');

4131: ||to_char(l_step_tab(i).current_costs(j).cost_level));
4132: fnd_file.put_line
4133: (fnd_file.log,' Component Cost = '
4134: ||to_char(ROUND(l_step_tab(i).current_costs(j).component_cost,2)));
4135: fnd_file.put_line(fnd_file.log,' ');
4136: END LOOP;
4137: ELSE
4138: fnd_file.put_line(fnd_file.log,' This step has no current costs');
4139: END IF;

Line 4138: fnd_file.put_line(fnd_file.log,' This step has no current costs');

4134: ||to_char(ROUND(l_step_tab(i).current_costs(j).component_cost,2)));
4135: fnd_file.put_line(fnd_file.log,' ');
4136: END LOOP;
4137: ELSE
4138: fnd_file.put_line(fnd_file.log,' This step has no current costs');
4139: END IF;
4140:
4141: fnd_file.put_line
4142: (fnd_file.log,' Inherited Costs');

Line 4141: fnd_file.put_line

4137: ELSE
4138: fnd_file.put_line(fnd_file.log,' This step has no current costs');
4139: END IF;
4140:
4141: fnd_file.put_line
4142: (fnd_file.log,' Inherited Costs');
4143: fnd_file.put_line
4144: (fnd_file.log,' ---------------');
4145: IF l_step_tab(i).inherited_costs.EXISTS(1)

Line 4142: (fnd_file.log,' Inherited Costs');

4138: fnd_file.put_line(fnd_file.log,' This step has no current costs');
4139: END IF;
4140:
4141: fnd_file.put_line
4142: (fnd_file.log,' Inherited Costs');
4143: fnd_file.put_line
4144: (fnd_file.log,' ---------------');
4145: IF l_step_tab(i).inherited_costs.EXISTS(1)
4146: THEN

Line 4143: fnd_file.put_line

4139: END IF;
4140:
4141: fnd_file.put_line
4142: (fnd_file.log,' Inherited Costs');
4143: fnd_file.put_line
4144: (fnd_file.log,' ---------------');
4145: IF l_step_tab(i).inherited_costs.EXISTS(1)
4146: THEN
4147: FOR j IN 1..l_step_tab(i).inherited_costs.count

Line 4144: (fnd_file.log,' ---------------');

4140:
4141: fnd_file.put_line
4142: (fnd_file.log,' Inherited Costs');
4143: fnd_file.put_line
4144: (fnd_file.log,' ---------------');
4145: IF l_step_tab(i).inherited_costs.EXISTS(1)
4146: THEN
4147: FOR j IN 1..l_step_tab(i).inherited_costs.count
4148: LOOP

Line 4149: fnd_file.put_line

4145: IF l_step_tab(i).inherited_costs.EXISTS(1)
4146: THEN
4147: FOR j IN 1..l_step_tab(i).inherited_costs.count
4148: LOOP
4149: fnd_file.put_line
4150: (fnd_file.log,' Component Class ID = '
4151: ||to_char(l_step_tab(i).inherited_costs(j).cost_cmpntcls_id));
4152: fnd_file.put_line
4153: (fnd_file.log,' Cost Analysis Code = '

Line 4150: (fnd_file.log,' Component Class ID = '

4146: THEN
4147: FOR j IN 1..l_step_tab(i).inherited_costs.count
4148: LOOP
4149: fnd_file.put_line
4150: (fnd_file.log,' Component Class ID = '
4151: ||to_char(l_step_tab(i).inherited_costs(j).cost_cmpntcls_id));
4152: fnd_file.put_line
4153: (fnd_file.log,' Cost Analysis Code = '
4154: ||l_step_tab(i).inherited_costs(j).cost_analysis_code);

Line 4152: fnd_file.put_line

4148: LOOP
4149: fnd_file.put_line
4150: (fnd_file.log,' Component Class ID = '
4151: ||to_char(l_step_tab(i).inherited_costs(j).cost_cmpntcls_id));
4152: fnd_file.put_line
4153: (fnd_file.log,' Cost Analysis Code = '
4154: ||l_step_tab(i).inherited_costs(j).cost_analysis_code);
4155: fnd_file.put_line
4156: (fnd_file.log,' Cost Level = '

Line 4153: (fnd_file.log,' Cost Analysis Code = '

4149: fnd_file.put_line
4150: (fnd_file.log,' Component Class ID = '
4151: ||to_char(l_step_tab(i).inherited_costs(j).cost_cmpntcls_id));
4152: fnd_file.put_line
4153: (fnd_file.log,' Cost Analysis Code = '
4154: ||l_step_tab(i).inherited_costs(j).cost_analysis_code);
4155: fnd_file.put_line
4156: (fnd_file.log,' Cost Level = '
4157: ||to_char(l_step_tab(i).inherited_costs(j).cost_level));

Line 4155: fnd_file.put_line

4151: ||to_char(l_step_tab(i).inherited_costs(j).cost_cmpntcls_id));
4152: fnd_file.put_line
4153: (fnd_file.log,' Cost Analysis Code = '
4154: ||l_step_tab(i).inherited_costs(j).cost_analysis_code);
4155: fnd_file.put_line
4156: (fnd_file.log,' Cost Level = '
4157: ||to_char(l_step_tab(i).inherited_costs(j).cost_level));
4158: fnd_file.put_line
4159: (fnd_file.log,' Component Cost = '

Line 4156: (fnd_file.log,' Cost Level = '

4152: fnd_file.put_line
4153: (fnd_file.log,' Cost Analysis Code = '
4154: ||l_step_tab(i).inherited_costs(j).cost_analysis_code);
4155: fnd_file.put_line
4156: (fnd_file.log,' Cost Level = '
4157: ||to_char(l_step_tab(i).inherited_costs(j).cost_level));
4158: fnd_file.put_line
4159: (fnd_file.log,' Component Cost = '
4160: ||to_char(ROUND(l_step_tab(i).inherited_costs(j).component_cost,2)));

Line 4158: fnd_file.put_line

4154: ||l_step_tab(i).inherited_costs(j).cost_analysis_code);
4155: fnd_file.put_line
4156: (fnd_file.log,' Cost Level = '
4157: ||to_char(l_step_tab(i).inherited_costs(j).cost_level));
4158: fnd_file.put_line
4159: (fnd_file.log,' Component Cost = '
4160: ||to_char(ROUND(l_step_tab(i).inherited_costs(j).component_cost,2)));
4161: fnd_file.put_line(fnd_file.log,' ');
4162: END LOOP;

Line 4159: (fnd_file.log,' Component Cost = '

4155: fnd_file.put_line
4156: (fnd_file.log,' Cost Level = '
4157: ||to_char(l_step_tab(i).inherited_costs(j).cost_level));
4158: fnd_file.put_line
4159: (fnd_file.log,' Component Cost = '
4160: ||to_char(ROUND(l_step_tab(i).inherited_costs(j).component_cost,2)));
4161: fnd_file.put_line(fnd_file.log,' ');
4162: END LOOP;
4163: ELSE

Line 4161: fnd_file.put_line(fnd_file.log,' ');

4157: ||to_char(l_step_tab(i).inherited_costs(j).cost_level));
4158: fnd_file.put_line
4159: (fnd_file.log,' Component Cost = '
4160: ||to_char(ROUND(l_step_tab(i).inherited_costs(j).component_cost,2)));
4161: fnd_file.put_line(fnd_file.log,' ');
4162: END LOOP;
4163: ELSE
4164: fnd_file.put_line(fnd_file.log,' This step has no inherited costs');
4165: END IF;

Line 4164: fnd_file.put_line(fnd_file.log,' This step has no inherited costs');

4160: ||to_char(ROUND(l_step_tab(i).inherited_costs(j).component_cost,2)));
4161: fnd_file.put_line(fnd_file.log,' ');
4162: END LOOP;
4163: ELSE
4164: fnd_file.put_line(fnd_file.log,' This step has no inherited costs');
4165: END IF;
4166:
4167: fnd_file.put_line
4168: (fnd_file.log,' Step Costs');

Line 4167: fnd_file.put_line

4163: ELSE
4164: fnd_file.put_line(fnd_file.log,' This step has no inherited costs');
4165: END IF;
4166:
4167: fnd_file.put_line
4168: (fnd_file.log,' Step Costs');
4169: fnd_file.put_line
4170: (fnd_file.log,' ---------------');
4171: IF l_step_tab(i).step_costs.EXISTS(1)

Line 4168: (fnd_file.log,' Step Costs');

4164: fnd_file.put_line(fnd_file.log,' This step has no inherited costs');
4165: END IF;
4166:
4167: fnd_file.put_line
4168: (fnd_file.log,' Step Costs');
4169: fnd_file.put_line
4170: (fnd_file.log,' ---------------');
4171: IF l_step_tab(i).step_costs.EXISTS(1)
4172: THEN

Line 4169: fnd_file.put_line

4165: END IF;
4166:
4167: fnd_file.put_line
4168: (fnd_file.log,' Step Costs');
4169: fnd_file.put_line
4170: (fnd_file.log,' ---------------');
4171: IF l_step_tab(i).step_costs.EXISTS(1)
4172: THEN
4173: FOR j IN 1..l_step_tab(i).step_costs.count

Line 4170: (fnd_file.log,' ---------------');

4166:
4167: fnd_file.put_line
4168: (fnd_file.log,' Step Costs');
4169: fnd_file.put_line
4170: (fnd_file.log,' ---------------');
4171: IF l_step_tab(i).step_costs.EXISTS(1)
4172: THEN
4173: FOR j IN 1..l_step_tab(i).step_costs.count
4174: LOOP

Line 4175: fnd_file.put_line

4171: IF l_step_tab(i).step_costs.EXISTS(1)
4172: THEN
4173: FOR j IN 1..l_step_tab(i).step_costs.count
4174: LOOP
4175: fnd_file.put_line
4176: (fnd_file.log,' Component Class ID = '
4177: ||to_char(l_step_tab(i).step_costs(j).cost_cmpntcls_id));
4178: fnd_file.put_line
4179: (fnd_file.log,' Cost Analysis Code = '

Line 4176: (fnd_file.log,' Component Class ID = '

4172: THEN
4173: FOR j IN 1..l_step_tab(i).step_costs.count
4174: LOOP
4175: fnd_file.put_line
4176: (fnd_file.log,' Component Class ID = '
4177: ||to_char(l_step_tab(i).step_costs(j).cost_cmpntcls_id));
4178: fnd_file.put_line
4179: (fnd_file.log,' Cost Analysis Code = '
4180: ||l_step_tab(i).step_costs(j).cost_analysis_code);

Line 4178: fnd_file.put_line

4174: LOOP
4175: fnd_file.put_line
4176: (fnd_file.log,' Component Class ID = '
4177: ||to_char(l_step_tab(i).step_costs(j).cost_cmpntcls_id));
4178: fnd_file.put_line
4179: (fnd_file.log,' Cost Analysis Code = '
4180: ||l_step_tab(i).step_costs(j).cost_analysis_code);
4181: fnd_file.put_line
4182: (fnd_file.log,' Cost Level = '

Line 4179: (fnd_file.log,' Cost Analysis Code = '

4175: fnd_file.put_line
4176: (fnd_file.log,' Component Class ID = '
4177: ||to_char(l_step_tab(i).step_costs(j).cost_cmpntcls_id));
4178: fnd_file.put_line
4179: (fnd_file.log,' Cost Analysis Code = '
4180: ||l_step_tab(i).step_costs(j).cost_analysis_code);
4181: fnd_file.put_line
4182: (fnd_file.log,' Cost Level = '
4183: ||to_char(l_step_tab(i).step_costs(j).cost_level));

Line 4181: fnd_file.put_line

4177: ||to_char(l_step_tab(i).step_costs(j).cost_cmpntcls_id));
4178: fnd_file.put_line
4179: (fnd_file.log,' Cost Analysis Code = '
4180: ||l_step_tab(i).step_costs(j).cost_analysis_code);
4181: fnd_file.put_line
4182: (fnd_file.log,' Cost Level = '
4183: ||to_char(l_step_tab(i).step_costs(j).cost_level));
4184: fnd_file.put_line
4185: (fnd_file.log,' Component Cost = '

Line 4182: (fnd_file.log,' Cost Level = '

4178: fnd_file.put_line
4179: (fnd_file.log,' Cost Analysis Code = '
4180: ||l_step_tab(i).step_costs(j).cost_analysis_code);
4181: fnd_file.put_line
4182: (fnd_file.log,' Cost Level = '
4183: ||to_char(l_step_tab(i).step_costs(j).cost_level));
4184: fnd_file.put_line
4185: (fnd_file.log,' Component Cost = '
4186: ||to_char(ROUND(l_step_tab(i).step_costs(j).component_cost,2)));

Line 4184: fnd_file.put_line

4180: ||l_step_tab(i).step_costs(j).cost_analysis_code);
4181: fnd_file.put_line
4182: (fnd_file.log,' Cost Level = '
4183: ||to_char(l_step_tab(i).step_costs(j).cost_level));
4184: fnd_file.put_line
4185: (fnd_file.log,' Component Cost = '
4186: ||to_char(ROUND(l_step_tab(i).step_costs(j).component_cost,2)));
4187: fnd_file.put_line(fnd_file.log,' ');
4188: END LOOP;

Line 4185: (fnd_file.log,' Component Cost = '

4181: fnd_file.put_line
4182: (fnd_file.log,' Cost Level = '
4183: ||to_char(l_step_tab(i).step_costs(j).cost_level));
4184: fnd_file.put_line
4185: (fnd_file.log,' Component Cost = '
4186: ||to_char(ROUND(l_step_tab(i).step_costs(j).component_cost,2)));
4187: fnd_file.put_line(fnd_file.log,' ');
4188: END LOOP;
4189: ELSE

Line 4187: fnd_file.put_line(fnd_file.log,' ');

4183: ||to_char(l_step_tab(i).step_costs(j).cost_level));
4184: fnd_file.put_line
4185: (fnd_file.log,' Component Cost = '
4186: ||to_char(ROUND(l_step_tab(i).step_costs(j).component_cost,2)));
4187: fnd_file.put_line(fnd_file.log,' ');
4188: END LOOP;
4189: ELSE
4190: fnd_file.put_line(fnd_file.log,' This step has no step costs - THIS SHOULD NEVER HAPPEN');
4191: END IF;

Line 4190: fnd_file.put_line(fnd_file.log,' This step has no step costs - THIS SHOULD NEVER HAPPEN');

4186: ||to_char(ROUND(l_step_tab(i).step_costs(j).component_cost,2)));
4187: fnd_file.put_line(fnd_file.log,' ');
4188: END LOOP;
4189: ELSE
4190: fnd_file.put_line(fnd_file.log,' This step has no step costs - THIS SHOULD NEVER HAPPEN');
4191: END IF;
4192:
4193:
4194: fnd_file.put_line(fnd_file.log,' ');

Line 4194: fnd_file.put_line(fnd_file.log,' ');

4190: fnd_file.put_line(fnd_file.log,' This step has no step costs - THIS SHOULD NEVER HAPPEN');
4191: END IF;
4192:
4193:
4194: fnd_file.put_line(fnd_file.log,' ');
4195: fnd_file.put_line
4196: (fnd_file.log,' Subsequent steps');
4197: fnd_file.put_line
4198: (fnd_file.log,' ----------------');

Line 4195: fnd_file.put_line

4191: END IF;
4192:
4193:
4194: fnd_file.put_line(fnd_file.log,' ');
4195: fnd_file.put_line
4196: (fnd_file.log,' Subsequent steps');
4197: fnd_file.put_line
4198: (fnd_file.log,' ----------------');
4199: IF l_step_tab(i).dependencies(1).step_index IS NULL

Line 4196: (fnd_file.log,' Subsequent steps');

4192:
4193:
4194: fnd_file.put_line(fnd_file.log,' ');
4195: fnd_file.put_line
4196: (fnd_file.log,' Subsequent steps');
4197: fnd_file.put_line
4198: (fnd_file.log,' ----------------');
4199: IF l_step_tab(i).dependencies(1).step_index IS NULL
4200: THEN

Line 4197: fnd_file.put_line

4193:
4194: fnd_file.put_line(fnd_file.log,' ');
4195: fnd_file.put_line
4196: (fnd_file.log,' Subsequent steps');
4197: fnd_file.put_line
4198: (fnd_file.log,' ----------------');
4199: IF l_step_tab(i).dependencies(1).step_index IS NULL
4200: THEN
4201: fnd_file.put_line(fnd_file.log,' This is a terminal step');

Line 4198: (fnd_file.log,' ----------------');

4194: fnd_file.put_line(fnd_file.log,' ');
4195: fnd_file.put_line
4196: (fnd_file.log,' Subsequent steps');
4197: fnd_file.put_line
4198: (fnd_file.log,' ----------------');
4199: IF l_step_tab(i).dependencies(1).step_index IS NULL
4200: THEN
4201: fnd_file.put_line(fnd_file.log,' This is a terminal step');
4202: ELSE

Line 4201: fnd_file.put_line(fnd_file.log,' This is a terminal step');

4197: fnd_file.put_line
4198: (fnd_file.log,' ----------------');
4199: IF l_step_tab(i).dependencies(1).step_index IS NULL
4200: THEN
4201: fnd_file.put_line(fnd_file.log,' This is a terminal step');
4202: ELSE
4203: FOR j IN 1..l_step_tab(i).dependencies.count
4204: LOOP
4205: fnd_file.put_line

Line 4205: fnd_file.put_line

4201: fnd_file.put_line(fnd_file.log,' This is a terminal step');
4202: ELSE
4203: FOR j IN 1..l_step_tab(i).dependencies.count
4204: LOOP
4205: fnd_file.put_line
4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));
4207: fnd_file.put_line
4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));
4209: fnd_file.put_line

Line 4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));

4202: ELSE
4203: FOR j IN 1..l_step_tab(i).dependencies.count
4204: LOOP
4205: fnd_file.put_line
4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));
4207: fnd_file.put_line
4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));
4209: fnd_file.put_line
4210: (fnd_file.log,' Step qty = '

Line 4207: fnd_file.put_line

4203: FOR j IN 1..l_step_tab(i).dependencies.count
4204: LOOP
4205: fnd_file.put_line
4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));
4207: fnd_file.put_line
4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));
4209: fnd_file.put_line
4210: (fnd_file.log,' Step qty = '
4211: ||to_char(ROUND(l_step_tab(i).dependencies(j).step_qty,2))

Line 4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));

4204: LOOP
4205: fnd_file.put_line
4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));
4207: fnd_file.put_line
4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));
4209: fnd_file.put_line
4210: (fnd_file.log,' Step qty = '
4211: ||to_char(ROUND(l_step_tab(i).dependencies(j).step_qty,2))
4212: ||l_step_tab(i).dependencies(j).step_qty_uom);

Line 4209: fnd_file.put_line

4205: fnd_file.put_line
4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));
4207: fnd_file.put_line
4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));
4209: fnd_file.put_line
4210: (fnd_file.log,' Step qty = '
4211: ||to_char(ROUND(l_step_tab(i).dependencies(j).step_qty,2))
4212: ||l_step_tab(i).dependencies(j).step_qty_uom);
4213: fnd_file.put_line(fnd_file.log,' ');

Line 4210: (fnd_file.log,' Step qty = '

4206: (fnd_file.log,' Step index = '||to_char(l_step_tab(i).dependencies(j).step_index));
4207: fnd_file.put_line
4208: (fnd_file.log,' Step ID = '||to_char(l_step_tab(i).dependencies(j).batchstep_id));
4209: fnd_file.put_line
4210: (fnd_file.log,' Step qty = '
4211: ||to_char(ROUND(l_step_tab(i).dependencies(j).step_qty,2))
4212: ||l_step_tab(i).dependencies(j).step_qty_uom);
4213: fnd_file.put_line(fnd_file.log,' ');
4214: END LOOP;

Line 4213: fnd_file.put_line(fnd_file.log,' ');

4209: fnd_file.put_line
4210: (fnd_file.log,' Step qty = '
4211: ||to_char(ROUND(l_step_tab(i).dependencies(j).step_qty,2))
4212: ||l_step_tab(i).dependencies(j).step_qty_uom);
4213: fnd_file.put_line(fnd_file.log,' ');
4214: END LOOP;
4215: END IF;
4216:
4217: fnd_file.put_line(fnd_file.log,' ');

Line 4217: fnd_file.put_line(fnd_file.log,' ');

4213: fnd_file.put_line(fnd_file.log,' ');
4214: END LOOP;
4215: END IF;
4216:
4217: fnd_file.put_line(fnd_file.log,' ');
4218: fnd_file.put_line
4219: (fnd_file.log,' Materials');
4220: fnd_file.put_line
4221: (fnd_file.log,' ---------');

Line 4218: fnd_file.put_line

4214: END LOOP;
4215: END IF;
4216:
4217: fnd_file.put_line(fnd_file.log,' ');
4218: fnd_file.put_line
4219: (fnd_file.log,' Materials');
4220: fnd_file.put_line
4221: (fnd_file.log,' ---------');
4222:

Line 4219: (fnd_file.log,' Materials');

4215: END IF;
4216:
4217: fnd_file.put_line(fnd_file.log,' ');
4218: fnd_file.put_line
4219: (fnd_file.log,' Materials');
4220: fnd_file.put_line
4221: (fnd_file.log,' ---------');
4222:
4223: IF l_step_tab(i).materials.EXISTS(1)

Line 4220: fnd_file.put_line

4216:
4217: fnd_file.put_line(fnd_file.log,' ');
4218: fnd_file.put_line
4219: (fnd_file.log,' Materials');
4220: fnd_file.put_line
4221: (fnd_file.log,' ---------');
4222:
4223: IF l_step_tab(i).materials.EXISTS(1)
4224: THEN

Line 4221: (fnd_file.log,' ---------');

4217: fnd_file.put_line(fnd_file.log,' ');
4218: fnd_file.put_line
4219: (fnd_file.log,' Materials');
4220: fnd_file.put_line
4221: (fnd_file.log,' ---------');
4222:
4223: IF l_step_tab(i).materials.EXISTS(1)
4224: THEN
4225: FOR j in 1..l_step_tab(i).materials.count

Line 4227: fnd_file.put_line

4223: IF l_step_tab(i).materials.EXISTS(1)
4224: THEN
4225: FOR j in 1..l_step_tab(i).materials.count
4226: LOOP
4227: fnd_file.put_line
4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));
4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line

Line 4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));

4224: THEN
4225: FOR j in 1..l_step_tab(i).materials.count
4226: LOOP
4227: fnd_file.put_line
4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));
4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));

Line 4229: fnd_file.put_line

4225: FOR j in 1..l_step_tab(i).materials.count
4226: LOOP
4227: fnd_file.put_line
4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));
4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line

Line 4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);

4226: LOOP
4227: fnd_file.put_line
4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));
4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));

Line 4231: fnd_file.put_line

4227: fnd_file.put_line
4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));
4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line

Line 4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));

4228: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).materials(j).trans_id));
4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));

Line 4233: fnd_file.put_line

4229: fnd_file.put_line
4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line

Line 4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));

4230: (fnd_file.log,' Legal Entity = '||l_step_tab(i).materials(j).legal_entity_id);
4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));

Line 4235: fnd_file.put_line

4231: fnd_file.put_line
4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line

Line 4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));

4232: (fnd_file.log,' Organization = '||l_org_tab(l_step_tab(i).materials(j).organization_id));
4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)

Line 4237: fnd_file.put_line

4233: fnd_file.put_line
4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)
4241: ||l_step_tab(i).materials(j).trans_um);

Line 4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));

4234: (fnd_file.log,' Item ID = '||to_char(l_step_tab(i).materials(j).item_id));
4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)
4241: ||l_step_tab(i).materials(j).trans_um);
4242: fnd_file.put_line

Line 4239: fnd_file.put_line

4235: fnd_file.put_line
4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)
4241: ||l_step_tab(i).materials(j).trans_um);
4242: fnd_file.put_line
4243: (fnd_file.log,' Trans Date = '

Line 4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)

4236: (fnd_file.log,' Lot Number = '||to_char(l_step_tab(i).materials(j).lot_number));
4237: fnd_file.put_line
4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)
4241: ||l_step_tab(i).materials(j).trans_um);
4242: fnd_file.put_line
4243: (fnd_file.log,' Trans Date = '
4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));

Line 4242: fnd_file.put_line

4238: (fnd_file.log,' Line type = '||to_char(l_step_tab(i).materials(j).line_type));
4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)
4241: ||l_step_tab(i).materials(j).trans_um);
4242: fnd_file.put_line
4243: (fnd_file.log,' Trans Date = '
4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));

Line 4243: (fnd_file.log,' Trans Date = '

4239: fnd_file.put_line
4240: (fnd_file.log,' Trans Qty = '||to_char(l_step_tab(i).materials(j).trans_qty)
4241: ||l_step_tab(i).materials(j).trans_um);
4242: fnd_file.put_line
4243: (fnd_file.log,' Trans Date = '
4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line

Line 4245: fnd_file.put_line

4241: ||l_step_tab(i).materials(j).trans_um);
4242: fnd_file.put_line
4243: (fnd_file.log,' Trans Date = '
4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line

Line 4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));

4242: fnd_file.put_line
4243: (fnd_file.log,' Trans Date = '
4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));

Line 4247: fnd_file.put_line

4243: (fnd_file.log,' Trans Date = '
4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line

Line 4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));

4244: ||to_char(l_step_tab(i).materials(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');

Line 4249: fnd_file.put_line

4245: fnd_file.put_line
4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');
4253: fnd_file.put_line

Line 4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));

4246: (fnd_file.log,' Lot Cost Flag = '||to_char(l_step_tab(i).materials(j).lot_costed_flag));
4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');
4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '

Line 4251: fnd_file.put_line

4247: fnd_file.put_line
4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');
4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '
4255: ||to_char(l_step_tab(i).materials(j).trans_id));

Line 4252: (fnd_file.log,' ');

4248: (fnd_file.log,' Contribution = '||to_char(l_step_tab(i).materials(j).step_contribution));
4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');
4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '
4255: ||to_char(l_step_tab(i).materials(j).trans_id));
4256: fnd_file.put_line

Line 4253: fnd_file.put_line

4249: fnd_file.put_line
4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');
4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '
4255: ||to_char(l_step_tab(i).materials(j).trans_id));
4256: fnd_file.put_line
4257: (fnd_file.log,' ----------------------------------------------');

Line 4254: (fnd_file.log,' Cost Details for material transaction '

4250: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).materials(j).trans_cost,2)));
4251: fnd_file.put_line
4252: (fnd_file.log,' ');
4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '
4255: ||to_char(l_step_tab(i).materials(j).trans_id));
4256: fnd_file.put_line
4257: (fnd_file.log,' ----------------------------------------------');
4258:

Line 4256: fnd_file.put_line

4252: (fnd_file.log,' ');
4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '
4255: ||to_char(l_step_tab(i).materials(j).trans_id));
4256: fnd_file.put_line
4257: (fnd_file.log,' ----------------------------------------------');
4258:
4259: IF l_step_tab(i).materials(j).cost_details.EXISTS(1)
4260: THEN

Line 4257: (fnd_file.log,' ----------------------------------------------');

4253: fnd_file.put_line
4254: (fnd_file.log,' Cost Details for material transaction '
4255: ||to_char(l_step_tab(i).materials(j).trans_id));
4256: fnd_file.put_line
4257: (fnd_file.log,' ----------------------------------------------');
4258:
4259: IF l_step_tab(i).materials(j).cost_details.EXISTS(1)
4260: THEN
4261: FOR k IN 1..l_step_tab(i).materials(j).cost_details.count

Line 4263: fnd_file.put_line

4259: IF l_step_tab(i).materials(j).cost_details.EXISTS(1)
4260: THEN
4261: FOR k IN 1..l_step_tab(i).materials(j).cost_details.count
4262: LOOP
4263: fnd_file.put_line
4264: (fnd_file.log,' Component Class ID = '
4265: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_cmpntcls_id));
4266: fnd_file.put_line
4267: (fnd_file.log,' Cost Analysis Code = '

Line 4264: (fnd_file.log,' Component Class ID = '

4260: THEN
4261: FOR k IN 1..l_step_tab(i).materials(j).cost_details.count
4262: LOOP
4263: fnd_file.put_line
4264: (fnd_file.log,' Component Class ID = '
4265: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_cmpntcls_id));
4266: fnd_file.put_line
4267: (fnd_file.log,' Cost Analysis Code = '
4268: ||l_step_tab(i).materials(j).cost_details(k).cost_analysis_code);

Line 4266: fnd_file.put_line

4262: LOOP
4263: fnd_file.put_line
4264: (fnd_file.log,' Component Class ID = '
4265: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_cmpntcls_id));
4266: fnd_file.put_line
4267: (fnd_file.log,' Cost Analysis Code = '
4268: ||l_step_tab(i).materials(j).cost_details(k).cost_analysis_code);
4269: fnd_file.put_line
4270: (fnd_file.log,' Cost Level = '

Line 4267: (fnd_file.log,' Cost Analysis Code = '

4263: fnd_file.put_line
4264: (fnd_file.log,' Component Class ID = '
4265: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_cmpntcls_id));
4266: fnd_file.put_line
4267: (fnd_file.log,' Cost Analysis Code = '
4268: ||l_step_tab(i).materials(j).cost_details(k).cost_analysis_code);
4269: fnd_file.put_line
4270: (fnd_file.log,' Cost Level = '
4271: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_level));

Line 4269: fnd_file.put_line

4265: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_cmpntcls_id));
4266: fnd_file.put_line
4267: (fnd_file.log,' Cost Analysis Code = '
4268: ||l_step_tab(i).materials(j).cost_details(k).cost_analysis_code);
4269: fnd_file.put_line
4270: (fnd_file.log,' Cost Level = '
4271: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_level));
4272: fnd_file.put_line
4273: (fnd_file.log,' Component Cost = '

Line 4270: (fnd_file.log,' Cost Level = '

4266: fnd_file.put_line
4267: (fnd_file.log,' Cost Analysis Code = '
4268: ||l_step_tab(i).materials(j).cost_details(k).cost_analysis_code);
4269: fnd_file.put_line
4270: (fnd_file.log,' Cost Level = '
4271: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_level));
4272: fnd_file.put_line
4273: (fnd_file.log,' Component Cost = '
4274: ||to_char(ROUND(l_step_tab(i).materials(j).cost_details(k).component_cost,2)));

Line 4272: fnd_file.put_line

4268: ||l_step_tab(i).materials(j).cost_details(k).cost_analysis_code);
4269: fnd_file.put_line
4270: (fnd_file.log,' Cost Level = '
4271: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_level));
4272: fnd_file.put_line
4273: (fnd_file.log,' Component Cost = '
4274: ||to_char(ROUND(l_step_tab(i).materials(j).cost_details(k).component_cost,2)));
4275: fnd_file.put_line(fnd_file.log,' ');
4276: END LOOP;

Line 4273: (fnd_file.log,' Component Cost = '

4269: fnd_file.put_line
4270: (fnd_file.log,' Cost Level = '
4271: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_level));
4272: fnd_file.put_line
4273: (fnd_file.log,' Component Cost = '
4274: ||to_char(ROUND(l_step_tab(i).materials(j).cost_details(k).component_cost,2)));
4275: fnd_file.put_line(fnd_file.log,' ');
4276: END LOOP;
4277: ELSE

Line 4275: fnd_file.put_line(fnd_file.log,' ');

4271: ||to_char(l_step_tab(i).materials(j).cost_details(k).cost_level));
4272: fnd_file.put_line
4273: (fnd_file.log,' Component Cost = '
4274: ||to_char(ROUND(l_step_tab(i).materials(j).cost_details(k).component_cost,2)));
4275: fnd_file.put_line(fnd_file.log,' ');
4276: END LOOP;
4277: ELSE
4278: fnd_file.put_line(fnd_file.log,' No costs exist for this material');
4279: END IF;

Line 4278: fnd_file.put_line(fnd_file.log,' No costs exist for this material');

4274: ||to_char(ROUND(l_step_tab(i).materials(j).cost_details(k).component_cost,2)));
4275: fnd_file.put_line(fnd_file.log,' ');
4276: END LOOP;
4277: ELSE
4278: fnd_file.put_line(fnd_file.log,' No costs exist for this material');
4279: END IF;
4280: END LOOP;
4281: ELSE
4282: fnd_file.put_line(fnd_file.log,' This step has no associated materials');

Line 4282: fnd_file.put_line(fnd_file.log,' This step has no associated materials');

4278: fnd_file.put_line(fnd_file.log,' No costs exist for this material');
4279: END IF;
4280: END LOOP;
4281: ELSE
4282: fnd_file.put_line(fnd_file.log,' This step has no associated materials');
4283: END IF;
4284:
4285: fnd_file.put_line(fnd_file.log,' ');
4286: fnd_file.put_line

Line 4285: fnd_file.put_line(fnd_file.log,' ');

4281: ELSE
4282: fnd_file.put_line(fnd_file.log,' This step has no associated materials');
4283: END IF;
4284:
4285: fnd_file.put_line(fnd_file.log,' ');
4286: fnd_file.put_line
4287: (fnd_file.log,' Resources');
4288: fnd_file.put_line
4289: (fnd_file.log,' ---------');

Line 4286: fnd_file.put_line

4282: fnd_file.put_line(fnd_file.log,' This step has no associated materials');
4283: END IF;
4284:
4285: fnd_file.put_line(fnd_file.log,' ');
4286: fnd_file.put_line
4287: (fnd_file.log,' Resources');
4288: fnd_file.put_line
4289: (fnd_file.log,' ---------');
4290:

Line 4287: (fnd_file.log,' Resources');

4283: END IF;
4284:
4285: fnd_file.put_line(fnd_file.log,' ');
4286: fnd_file.put_line
4287: (fnd_file.log,' Resources');
4288: fnd_file.put_line
4289: (fnd_file.log,' ---------');
4290:
4291: IF l_step_tab(i).resources.EXISTS(1)

Line 4288: fnd_file.put_line

4284:
4285: fnd_file.put_line(fnd_file.log,' ');
4286: fnd_file.put_line
4287: (fnd_file.log,' Resources');
4288: fnd_file.put_line
4289: (fnd_file.log,' ---------');
4290:
4291: IF l_step_tab(i).resources.EXISTS(1)
4292: THEN

Line 4289: (fnd_file.log,' ---------');

4285: fnd_file.put_line(fnd_file.log,' ');
4286: fnd_file.put_line
4287: (fnd_file.log,' Resources');
4288: fnd_file.put_line
4289: (fnd_file.log,' ---------');
4290:
4291: IF l_step_tab(i).resources.EXISTS(1)
4292: THEN
4293: FOR j in 1..l_step_tab(i).resources.count

Line 4295: fnd_file.put_line

4291: IF l_step_tab(i).resources.EXISTS(1)
4292: THEN
4293: FOR j in 1..l_step_tab(i).resources.count
4294: LOOP
4295: fnd_file.put_line
4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));
4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line

Line 4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));

4292: THEN
4293: FOR j in 1..l_step_tab(i).resources.count
4294: LOOP
4295: fnd_file.put_line
4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));
4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);

Line 4297: fnd_file.put_line

4293: FOR j in 1..l_step_tab(i).resources.count
4294: LOOP
4295: fnd_file.put_line
4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));
4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line

Line 4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));

4294: LOOP
4295: fnd_file.put_line
4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));
4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)

Line 4299: fnd_file.put_line

4295: fnd_file.put_line
4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));
4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)
4303: ||l_step_tab(i).resources(j).trans_um);

Line 4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);

4296: (fnd_file.log,' Trans ID = '||to_char(l_step_tab(i).resources(j).trans_id));
4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)
4303: ||l_step_tab(i).resources(j).trans_um);
4304: fnd_file.put_line

Line 4301: fnd_file.put_line

4297: fnd_file.put_line
4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)
4303: ||l_step_tab(i).resources(j).trans_um);
4304: fnd_file.put_line
4305: (fnd_file.log,' Trans Date = '

Line 4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)

4298: (fnd_file.log,' Orgn Id = '||l_org_tab(l_step_tab(i).resources(j).organization_id));
4299: fnd_file.put_line
4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)
4303: ||l_step_tab(i).resources(j).trans_um);
4304: fnd_file.put_line
4305: (fnd_file.log,' Trans Date = '
4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));

Line 4304: fnd_file.put_line

4300: (fnd_file.log,' Resource = '||l_step_tab(i).resources(j).resources);
4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)
4303: ||l_step_tab(i).resources(j).trans_um);
4304: fnd_file.put_line
4305: (fnd_file.log,' Trans Date = '
4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));

Line 4305: (fnd_file.log,' Trans Date = '

4301: fnd_file.put_line
4302: (fnd_file.log,' Resource Usage= '||to_char(l_step_tab(i).resources(j).resource_usage)
4303: ||l_step_tab(i).resources(j).trans_um);
4304: fnd_file.put_line
4305: (fnd_file.log,' Trans Date = '
4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line

Line 4307: fnd_file.put_line

4303: ||l_step_tab(i).resources(j).trans_um);
4304: fnd_file.put_line
4305: (fnd_file.log,' Trans Date = '
4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line
4310: (fnd_file.log,' ');
4311: fnd_file.put_line

Line 4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));

4304: fnd_file.put_line
4305: (fnd_file.log,' Trans Date = '
4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line
4310: (fnd_file.log,' ');
4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '

Line 4309: fnd_file.put_line

4305: (fnd_file.log,' Trans Date = '
4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line
4310: (fnd_file.log,' ');
4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '
4313: ||to_char(l_step_tab(i).resources(j).trans_id));

Line 4310: (fnd_file.log,' ');

4306: ||to_char(l_step_tab(i).resources(j).trans_date,'DD-Mon-YYYY HH24:MI:SS'));
4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line
4310: (fnd_file.log,' ');
4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '
4313: ||to_char(l_step_tab(i).resources(j).trans_id));
4314: fnd_file.put_line

Line 4311: fnd_file.put_line

4307: fnd_file.put_line
4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line
4310: (fnd_file.log,' ');
4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '
4313: ||to_char(l_step_tab(i).resources(j).trans_id));
4314: fnd_file.put_line
4315: (fnd_file.log,' ---------------------------------------------');

Line 4312: (fnd_file.log,' Cost Details for resource transaction '

4308: (fnd_file.log,' Trans Cost = '||to_char(ROUND(l_step_tab(i).resources(j).trans_cost,2)));
4309: fnd_file.put_line
4310: (fnd_file.log,' ');
4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '
4313: ||to_char(l_step_tab(i).resources(j).trans_id));
4314: fnd_file.put_line
4315: (fnd_file.log,' ---------------------------------------------');
4316:

Line 4314: fnd_file.put_line

4310: (fnd_file.log,' ');
4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '
4313: ||to_char(l_step_tab(i).resources(j).trans_id));
4314: fnd_file.put_line
4315: (fnd_file.log,' ---------------------------------------------');
4316:
4317: IF l_step_tab(i).resources(j).cost_details.EXISTS(1)
4318: THEN

Line 4315: (fnd_file.log,' ---------------------------------------------');

4311: fnd_file.put_line
4312: (fnd_file.log,' Cost Details for resource transaction '
4313: ||to_char(l_step_tab(i).resources(j).trans_id));
4314: fnd_file.put_line
4315: (fnd_file.log,' ---------------------------------------------');
4316:
4317: IF l_step_tab(i).resources(j).cost_details.EXISTS(1)
4318: THEN
4319: FOR k IN 1..l_step_tab(i).resources(j).cost_details.count

Line 4321: fnd_file.put_line

4317: IF l_step_tab(i).resources(j).cost_details.EXISTS(1)
4318: THEN
4319: FOR k IN 1..l_step_tab(i).resources(j).cost_details.count
4320: LOOP
4321: fnd_file.put_line
4322: (fnd_file.log,' Component Class ID = '
4323: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_cmpntcls_id));
4324: fnd_file.put_line
4325: (fnd_file.log,' Cost Analysis Code = '

Line 4322: (fnd_file.log,' Component Class ID = '

4318: THEN
4319: FOR k IN 1..l_step_tab(i).resources(j).cost_details.count
4320: LOOP
4321: fnd_file.put_line
4322: (fnd_file.log,' Component Class ID = '
4323: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_cmpntcls_id));
4324: fnd_file.put_line
4325: (fnd_file.log,' Cost Analysis Code = '
4326: ||l_step_tab(i).resources(j).cost_details(k).cost_analysis_code);

Line 4324: fnd_file.put_line

4320: LOOP
4321: fnd_file.put_line
4322: (fnd_file.log,' Component Class ID = '
4323: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_cmpntcls_id));
4324: fnd_file.put_line
4325: (fnd_file.log,' Cost Analysis Code = '
4326: ||l_step_tab(i).resources(j).cost_details(k).cost_analysis_code);
4327: fnd_file.put_line
4328: (fnd_file.log,' Cost Level = '

Line 4325: (fnd_file.log,' Cost Analysis Code = '

4321: fnd_file.put_line
4322: (fnd_file.log,' Component Class ID = '
4323: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_cmpntcls_id));
4324: fnd_file.put_line
4325: (fnd_file.log,' Cost Analysis Code = '
4326: ||l_step_tab(i).resources(j).cost_details(k).cost_analysis_code);
4327: fnd_file.put_line
4328: (fnd_file.log,' Cost Level = '
4329: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_level));

Line 4327: fnd_file.put_line

4323: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_cmpntcls_id));
4324: fnd_file.put_line
4325: (fnd_file.log,' Cost Analysis Code = '
4326: ||l_step_tab(i).resources(j).cost_details(k).cost_analysis_code);
4327: fnd_file.put_line
4328: (fnd_file.log,' Cost Level = '
4329: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_level));
4330: fnd_file.put_line
4331: (fnd_file.log,' Component Cost = '

Line 4328: (fnd_file.log,' Cost Level = '

4324: fnd_file.put_line
4325: (fnd_file.log,' Cost Analysis Code = '
4326: ||l_step_tab(i).resources(j).cost_details(k).cost_analysis_code);
4327: fnd_file.put_line
4328: (fnd_file.log,' Cost Level = '
4329: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_level));
4330: fnd_file.put_line
4331: (fnd_file.log,' Component Cost = '
4332: ||to_char(ROUND(l_step_tab(i).resources(j).cost_details(k).component_cost,2)));

Line 4330: fnd_file.put_line

4326: ||l_step_tab(i).resources(j).cost_details(k).cost_analysis_code);
4327: fnd_file.put_line
4328: (fnd_file.log,' Cost Level = '
4329: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_level));
4330: fnd_file.put_line
4331: (fnd_file.log,' Component Cost = '
4332: ||to_char(ROUND(l_step_tab(i).resources(j).cost_details(k).component_cost,2)));
4333: fnd_file.put_line(fnd_file.log,' ');
4334: END LOOP;

Line 4331: (fnd_file.log,' Component Cost = '

4327: fnd_file.put_line
4328: (fnd_file.log,' Cost Level = '
4329: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_level));
4330: fnd_file.put_line
4331: (fnd_file.log,' Component Cost = '
4332: ||to_char(ROUND(l_step_tab(i).resources(j).cost_details(k).component_cost,2)));
4333: fnd_file.put_line(fnd_file.log,' ');
4334: END LOOP;
4335: ELSE

Line 4333: fnd_file.put_line(fnd_file.log,' ');

4329: ||to_char(l_step_tab(i).resources(j).cost_details(k).cost_level));
4330: fnd_file.put_line
4331: (fnd_file.log,' Component Cost = '
4332: ||to_char(ROUND(l_step_tab(i).resources(j).cost_details(k).component_cost,2)));
4333: fnd_file.put_line(fnd_file.log,' ');
4334: END LOOP;
4335: ELSE
4336: fnd_file.put_line(fnd_file.log,' This resource has no costs');
4337: END IF;

Line 4336: fnd_file.put_line(fnd_file.log,' This resource has no costs');

4332: ||to_char(ROUND(l_step_tab(i).resources(j).cost_details(k).component_cost,2)));
4333: fnd_file.put_line(fnd_file.log,' ');
4334: END LOOP;
4335: ELSE
4336: fnd_file.put_line(fnd_file.log,' This resource has no costs');
4337: END IF;
4338: END LOOP;
4339: ELSE
4340: fnd_file.put_line(fnd_file.log,' This step has no associated resources');

Line 4340: fnd_file.put_line(fnd_file.log,' This step has no associated resources');

4336: fnd_file.put_line(fnd_file.log,' This resource has no costs');
4337: END IF;
4338: END LOOP;
4339: ELSE
4340: fnd_file.put_line(fnd_file.log,' This step has no associated resources');
4341: END IF;
4342: END LOOP;
4343: IF l_debug_level >= l_debug_level_medium
4344: THEN

Line 4345: fnd_file.put_line

4341: END IF;
4342: END LOOP;
4343: IF l_debug_level >= l_debug_level_medium
4344: THEN
4345: fnd_file.put_line
4346: (fnd_file.log,'Leaving Procedure: '||procedure_name);
4347: END IF;
4348:
4349: END lot_cost_audit;

Line 4346: (fnd_file.log,'Leaving Procedure: '||procedure_name);

4342: END LOOP;
4343: IF l_debug_level >= l_debug_level_medium
4344: THEN
4345: fnd_file.put_line
4346: (fnd_file.log,'Leaving Procedure: '||procedure_name);
4347: END IF;
4348:
4349: END lot_cost_audit;
4350:

Line 4461: fnd_file.put_line

4457:
4458: procedure_name := 'Process Batch';
4459: IF l_debug_level >= l_debug_level_medium
4460: THEN
4461: fnd_file.put_line
4462: (fnd_file.log,'Entered Procedure: '||procedure_name);
4463: END IF;
4464:
4465: l_skip_this_batch := FALSE;

Line 4462: (fnd_file.log,'Entered Procedure: '||procedure_name);

4458: procedure_name := 'Process Batch';
4459: IF l_debug_level >= l_debug_level_medium
4460: THEN
4461: fnd_file.put_line
4462: (fnd_file.log,'Entered Procedure: '||procedure_name);
4463: END IF;
4464:
4465: l_skip_this_batch := FALSE;
4466: l_skip_this_txn := FALSE;

Line 4475: fnd_file.put_line

4471: -- We're in business . Will reach here only if batch_status is in (3,4)
4472:
4473: IF l_debug_level >= l_debug_level_medium
4474: THEN
4475: fnd_file.put_line
4476: (fnd_file.log,'Batch is eligible for lot costing');
4477: END IF;
4478:
4479: l_skip_this_batch := FALSE;

Line 4476: (fnd_file.log,'Batch is eligible for lot costing');

4472:
4473: IF l_debug_level >= l_debug_level_medium
4474: THEN
4475: fnd_file.put_line
4476: (fnd_file.log,'Batch is eligible for lot costing');
4477: END IF;
4478:
4479: l_skip_this_batch := FALSE;
4480:

Line 4489: fnd_file.put_line

4485: IF transaction_row.line_type = 1 -- Don't explode for byproducts
4486: THEN
4487: IF l_debug_level >= l_debug_level_medium
4488: THEN
4489: fnd_file.put_line
4490: (fnd_file.log,'About to explode batch');
4491: END IF;
4492:
4493: -- Explode the batch

Line 4490: (fnd_file.log,'About to explode batch');

4486: THEN
4487: IF l_debug_level >= l_debug_level_medium
4488: THEN
4489: fnd_file.put_line
4490: (fnd_file.log,'About to explode batch');
4491: END IF;
4492:
4493: -- Explode the batch
4494:

Line 4502: fnd_file.put_line(fnd_file.log,' Opening nr cursor');

4498: AND batch_id = transaction_row.doc_id;
4499:
4500: IF l_routing = 0
4501: THEN
4502: fnd_file.put_line(fnd_file.log,' Opening nr cursor');
4503: OPEN explosion_cursor_nr;
4504: FETCH explosion_cursor_nr BULK COLLECT INTO l_step_lev, l_step_tab;
4505: CLOSE explosion_cursor_nr;
4506:

Line 4512: fnd_file.put_line(fnd_file.log,'Error Cannot find the value for the FM_YIELD_TYPE' );

4508: P_parm_name => 'FM_YIELD_TYPE',
4509: P_parm_value => l_um_type,
4510: X_return_status => l_return_status);
4511: IF l_return_status = 'E' THEN
4512: fnd_file.put_line(fnd_file.log,'Error Cannot find the value for the FM_YIELD_TYPE' );
4513: RETURN;
4514: END IF;
4515:
4516:

Line 4522: fnd_file.put_line(fnd_file.log,' Entering else part of l_routing=0');

4518: FROM mtl_units_of_measure
4519: WHERE uom_class = l_um_type AND base_uom_flag = 'Y';
4520:
4521: ELSE
4522: fnd_file.put_line(fnd_file.log,' Entering else part of l_routing=0');
4523:
4524: SELECT count(*) INTO l_dep_steps
4525: FROM gme_batch_step_dependencies
4526: WHERE batch_id = transaction_row.doc_id;

Line 4538: fnd_file.put_line(fnd_file.log,

4534: l_independent_steps_cnt := NVL(l_independent_steps.COUNT,0) ;
4535:
4536: IF l_debug_level >= l_debug_level_medium
4537: THEN
4538: fnd_file.put_line(fnd_file.log,
4539: ' Before all the CASES...' ||
4540: '# of dep steps : '|| l_dep_steps || '...' ||
4541: '# of independent steps : '|| l_independent_steps_cnt );
4542: fnd_file.put_line(fnd_file.log,

Line 4542: fnd_file.put_line(fnd_file.log,

4538: fnd_file.put_line(fnd_file.log,
4539: ' Before all the CASES...' ||
4540: '# of dep steps : '|| l_dep_steps || '...' ||
4541: '# of independent steps : '|| l_independent_steps_cnt );
4542: fnd_file.put_line(fnd_file.log,
4543: ' Independent steps(ids), if any, are: ' );
4544: FOR i in 1.. l_independent_steps_cnt LOOP
4545: fnd_file.put_line(fnd_file.log, ' i = '||i||'. step_id --> '||l_independent_steps(i));
4546: END LOOP;

Line 4545: fnd_file.put_line(fnd_file.log, ' i = '||i||'. step_id --> '||l_independent_steps(i));

4541: '# of independent steps : '|| l_independent_steps_cnt );
4542: fnd_file.put_line(fnd_file.log,
4543: ' Independent steps(ids), if any, are: ' );
4544: FOR i in 1.. l_independent_steps_cnt LOOP
4545: fnd_file.put_line(fnd_file.log, ' i = '||i||'. step_id --> '||l_independent_steps(i));
4546: END LOOP;
4547: END IF;
4548:
4549:

Line 4556: fnd_file.put_line(fnd_file.log,' Opening the Normal Explosion Cursor at CASE 1. All dependency already defined ');

4552: IF (l_independent_steps_cnt = 0 AND l_dep_steps > 0) THEN
4553:
4554: IF l_debug_level >= l_debug_level_medium
4555: THEN
4556: fnd_file.put_line(fnd_file.log,' Opening the Normal Explosion Cursor at CASE 1. All dependency already defined ');
4557: END IF;
4558:
4559: OPEN explosion_cursor (transaction_row.doc_id);
4560: FETCH explosion_cursor BULK COLLECT INTO l_step_lev, l_step_tab;

Line 4569: fnd_file.put_line(fnd_file.log,' Opening the Single Step Explosion Cursor at CASE 2');

4565: ELSIF (l_independent_steps_cnt = 1 AND l_dep_steps = 0) THEN
4566:
4567: IF l_debug_level >= l_debug_level_medium
4568: THEN
4569: fnd_file.put_line(fnd_file.log,' Opening the Single Step Explosion Cursor at CASE 2');
4570: END IF;
4571:
4572: OPEN explosion_cursor_ss (transaction_row.doc_id);
4573: FETCH explosion_cursor_ss BULK COLLECT INTO l_step_lev, l_step_tab;

Line 4582: fnd_file.put_line(fnd_file.log,

4578: ELSIF ( l_independent_steps_cnt > 1 AND l_dep_steps = 0) THEN
4579:
4580: IF l_debug_level >= l_debug_level_medium
4581: THEN
4582: fnd_file.put_line(fnd_file.log,
4583: ' Inside CASE 3 : All steps are independent. So we are
4584: building virtual dependency chain. ');
4585: END IF;
4586:

Line 4637: fnd_file.put_line(fnd_file.log,

4633: ELSIF(l_independent_steps_cnt > 0 AND l_dep_steps > 0) THEN
4634:
4635: IF l_debug_level >= l_debug_level_medium
4636: THEN
4637: fnd_file.put_line(fnd_file.log,
4638: ' Inside CASE 4 : Few steps are independent. So we are
4639: building virtual dependency chain only for those
4640: independent rows. ');
4641: END IF;

Line 4655: fnd_file.put_line(fnd_file.log,' CASE 4 : The minimum step id is '||l_min_dep_step_id);

4651: AND batch_id = PRIOR batch_id;
4652:
4653: IF l_debug_level >= l_debug_level_medium
4654: THEN
4655: fnd_file.put_line(fnd_file.log,' CASE 4 : The minimum step id is '||l_min_dep_step_id);
4656: END IF;
4657:
4658: i:= 0;
4659: l_cur_step_id := l_min_dep_step_id;

Line 4732: fnd_file.put_line

4728: END IF; /* End if of l_routing = 0 */
4729:
4730: IF NOT l_step_tab.EXISTS(1)
4731: THEN
4732: fnd_file.put_line
4733: (fnd_file.log,'ERROR: Could not explode steps of batch ID '||to_char(transaction_row.doc_id));
4734: l_tmp := FALSE;
4735: RETURN;
4736: END IF;

Line 4733: (fnd_file.log,'ERROR: Could not explode steps of batch ID '||to_char(transaction_row.doc_id));

4729:
4730: IF NOT l_step_tab.EXISTS(1)
4731: THEN
4732: fnd_file.put_line
4733: (fnd_file.log,'ERROR: Could not explode steps of batch ID '||to_char(transaction_row.doc_id));
4734: l_tmp := FALSE;
4735: RETURN;
4736: END IF;
4737:

Line 4740: fnd_file.put_line

4736: END IF;
4737:
4738: IF l_debug_level >= l_debug_level_medium
4739: THEN
4740: fnd_file.put_line
4741: (fnd_file.log,'After explosion, '||to_char(l_step_tab.count)||' steps loaded');
4742: END IF;
4743:
4744: -- Load the transactions and cost them individually

Line 4741: (fnd_file.log,'After explosion, '||to_char(l_step_tab.count)||' steps loaded');

4737:
4738: IF l_debug_level >= l_debug_level_medium
4739: THEN
4740: fnd_file.put_line
4741: (fnd_file.log,'After explosion, '||to_char(l_step_tab.count)||' steps loaded');
4742: END IF;
4743:
4744: -- Load the transactions and cost them individually
4745:

Line 4756: fnd_file.put_line /* Bug 4297815 - Debug Msg Tuning */

4752: IF (l_routing <> 0 AND l_step_tab(i).step_qty = 0)
4753: THEN
4754: l_skip_this_batch := TRUE;
4755:
4756: fnd_file.put_line /* Bug 4297815 - Debug Msg Tuning */
4757: ( fnd_file.log,'ERROR: The Actual Step Qty of one of the steps in Batch_Id '||transaction_row.doc_id||' is zero. The Batch will be skipped from being costed.');
4758:
4759: l_return_status := 'E';
4760: l_uncostable_lots_tab(transaction_row.orgn_id||'-'||transaction_row.inventory_item_id||'-'||transaction_row.lot_number) := transaction_row.inventory_item_id;

Line 4757: ( fnd_file.log,'ERROR: The Actual Step Qty of one of the steps in Batch_Id '||transaction_row.doc_id||' is zero. The Batch will be skipped from being costed.');

4753: THEN
4754: l_skip_this_batch := TRUE;
4755:
4756: fnd_file.put_line /* Bug 4297815 - Debug Msg Tuning */
4757: ( fnd_file.log,'ERROR: The Actual Step Qty of one of the steps in Batch_Id '||transaction_row.doc_id||' is zero. The Batch will be skipped from being costed.');
4758:
4759: l_return_status := 'E';
4760: l_uncostable_lots_tab(transaction_row.orgn_id||'-'||transaction_row.inventory_item_id||'-'||transaction_row.lot_number) := transaction_row.inventory_item_id;
4761: l_tmp := FALSE;

Line 4773: fnd_file.put_line

4769: -- Load all resource transactions for each step and calculate the cost of each
4770:
4771: IF l_debug_level >= l_debug_level_medium
4772: THEN
4773: fnd_file.put_line
4774: (fnd_file.log,'Loading resource transactions for step ID '
4775: ||to_char(l_step_tab(i).current_step_id)
4776: );
4777: END IF;

Line 4774: (fnd_file.log,'Loading resource transactions for step ID '

4770:
4771: IF l_debug_level >= l_debug_level_medium
4772: THEN
4773: fnd_file.put_line
4774: (fnd_file.log,'Loading resource transactions for step ID '
4775: ||to_char(l_step_tab(i).current_step_id)
4776: );
4777: END IF;
4778:

Line 4785: fnd_file.put_line

4781: CLOSE resources_cursor;
4782:
4783: IF l_debug_level >= l_debug_level_medium
4784: THEN
4785: fnd_file.put_line
4786: (fnd_file.log,'Loaded '
4787: ||to_char(l_step_tab(i).resources.count)||' resource txns'
4788: );
4789: END IF;

Line 4786: (fnd_file.log,'Loaded '

4782:
4783: IF l_debug_level >= l_debug_level_medium
4784: THEN
4785: fnd_file.put_line
4786: (fnd_file.log,'Loaded '
4787: ||to_char(l_step_tab(i).resources.count)||' resource txns'
4788: );
4789: END IF;
4790:

Line 4809: fnd_file.put_line

4805:
4806: IF NOT l_step_tab(i).resources(j).cost_details.EXISTS(1)
4807: THEN
4808:
4809: fnd_file.put_line
4810: (fnd_file.log, 'Warning: The resource '
4811: ||l_step_tab(i).resources(j).resources
4812: ||' transaction is ignored as the resource has no cost'
4813: );

Line 4810: (fnd_file.log, 'Warning: The resource '

4806: IF NOT l_step_tab(i).resources(j).cost_details.EXISTS(1)
4807: THEN
4808:
4809: fnd_file.put_line
4810: (fnd_file.log, 'Warning: The resource '
4811: ||l_step_tab(i).resources(j).resources
4812: ||' transaction is ignored as the resource has no cost'
4813: );
4814:

Line 4971: fnd_file.put_line

4967: THEN
4968:
4969: IF l_debug_level < l_debug_level_high
4970: THEN
4971: fnd_file.put_line
4972: (fnd_file.log,'ERROR: Unable to convert from '
4973: ||l_step_tab(1).materials(j).trans_um
4974: ||' to '||l_step_tab(1).step_qty_uom||' for transaction ID '
4975: ||l_step_tab(1).materials(j).trans_id

Line 4972: (fnd_file.log,'ERROR: Unable to convert from '

4968:
4969: IF l_debug_level < l_debug_level_high
4970: THEN
4971: fnd_file.put_line
4972: (fnd_file.log,'ERROR: Unable to convert from '
4973: ||l_step_tab(1).materials(j).trans_um
4974: ||' to '||l_step_tab(1).step_qty_uom||' for transaction ID '
4975: ||l_step_tab(1).materials(j).trans_id
4976: );

Line 4978: fnd_file.put_line

4974: ||' to '||l_step_tab(1).step_qty_uom||' for transaction ID '
4975: ||l_step_tab(1).materials(j).trans_id
4976: );
4977: ELSE
4978: fnd_file.put_line
4979: (fnd_file.log,'ERROR: Unable to convert from '
4980: ||l_step_tab(1).materials(j).trans_um
4981: ||' to '||l_step_tab(1).step_qty_uom||' for transaction ID '
4982: ||l_step_tab(1).materials(j).trans_id

Line 4979: (fnd_file.log,'ERROR: Unable to convert from '

4975: ||l_step_tab(1).materials(j).trans_id
4976: );
4977: ELSE
4978: fnd_file.put_line
4979: (fnd_file.log,'ERROR: Unable to convert from '
4980: ||l_step_tab(1).materials(j).trans_um
4981: ||' to '||l_step_tab(1).step_qty_uom||' for transaction ID '
4982: ||l_step_tab(1).materials(j).trans_id
4983: ||' for item ID '

Line 5004: fnd_file.put_line (fnd_file.log, 'Cost Allocation Factor : Just before entering the cost allocation factor code , l_cost_alloc_profile value is '||l_cost_alloc_profile);

5000:
5001: /***** Bug 4057323 - To check whether all the Products are yielded in one single step - Start *****/
5002: IF l_debug_level >= l_debug_level_high
5003: THEN
5004: fnd_file.put_line (fnd_file.log, 'Cost Allocation Factor : Just before entering the cost allocation factor code , l_cost_alloc_profile value is '||l_cost_alloc_profile);
5005: END IF;
5006: IF (l_cost_alloc_profile = 1)
5007: THEN
5008: IF l_debug_level >= l_debug_level_high

Line 5010: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : l_Step_tab.COUNT is '||l_step_tab.COUNT);

5006: IF (l_cost_alloc_profile = 1)
5007: THEN
5008: IF l_debug_level >= l_debug_level_high
5009: THEN
5010: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : l_Step_tab.COUNT is '||l_step_tab.COUNT);
5011: END IF;
5012: IF (l_step_tab.COUNT = 1)
5013: THEN
5014: IF l_debug_level >= l_debug_level_high

Line 5016: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : Go ahead as there is only one total step ');

5012: IF (l_step_tab.COUNT = 1)
5013: THEN
5014: IF l_debug_level >= l_debug_level_high
5015: THEN
5016: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : Go ahead as there is only one total step ');
5017: END IF;
5018: -- Go ahead... There is only one step available. So all products should be attached to this step only.
5019: l_cost_alloc_profile := 1;
5020: ELSIF (l_step_tab.COUNT > 1)

Line 5024: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : Wait, there are many steps. So have to process others. Before the distinct batchstep_id area');

5020: ELSIF (l_step_tab.COUNT > 1)
5021: THEN
5022: IF l_debug_level >= l_debug_level_high
5023: THEN
5024: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : Wait, there are many steps. So have to process others. Before the distinct batchstep_id area');
5025: END IF;
5026:
5027: /* Check whether the number of Distinct steps having step material association is 1.
5028: If not don't use Cost Allocation Factor */

Line 5039: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : After the distinct batchstep_id area. the l_count is '||l_count);

5035: AND gmd.batch_id = transaction_row.doc_id;
5036:
5037: IF l_debug_level >= l_debug_level_high
5038: THEN
5039: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : After the distinct batchstep_id area. the l_count is '||l_count);
5040: END IF;
5041:
5042: IF (NVL (l_count, 0) = 1)
5043: THEN

Line 5046: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : There are some Step Matl Association. So check any unassociated products ');

5042: IF (NVL (l_count, 0) = 1)
5043: THEN
5044: IF l_debug_level >= l_debug_level_high
5045: THEN
5046: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : There are some Step Matl Association. So check any unassociated products ');
5047: END IF;
5048:
5049: -- If l_count is 1 then there is only one step having step material association
5050: /* Get Unassociated Products */

Line 5070: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : The number of unassociated products are '||l_unassociated_prds);

5066: WHERE batch_id = transaction_row.doc_id);
5067:
5068: IF l_debug_level >= l_debug_level_high
5069: THEN
5070: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : The number of unassociated products are '||l_unassociated_prds);
5071: END IF;
5072:
5073: IF (l_unassociated_prds = 0)
5074: THEN

Line 5078: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : unassociated prds are zero. so Go Ahead');

5074: THEN
5075:
5076: IF l_debug_level >= l_debug_level_high
5077: THEN
5078: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : unassociated prds are zero. so Go Ahead');
5079: END IF;
5080:
5081: -- Go ahead and use the profile
5082: l_cost_alloc_profile := 1;

Line 5091: fnd_file.put_line

5087: -- and some unassociated products.
5088: -- Although there is a chance that all the products which have explicit step association
5089: -- is on terminal step and our logic considers the unassociated products
5090: -- to be attached with the terminal step, BUT WE DONOT SUPPORT THIS CASE
5091: fnd_file.put_line
5092: ( fnd_file.log, ' NOTE : The profile GMF: Use Cost Alloc Factor in Lot Costing has been set to ''Yes''.
5093: Since few products have step association defined and few does not, this profile will NOT be used.');
5094: l_cost_alloc_profile := 0;
5095: END IF;

Line 5092: ( fnd_file.log, ' NOTE : The profile GMF: Use Cost Alloc Factor in Lot Costing has been set to ''Yes''.

5088: -- Although there is a chance that all the products which have explicit step association
5089: -- is on terminal step and our logic considers the unassociated products
5090: -- to be attached with the terminal step, BUT WE DONOT SUPPORT THIS CASE
5091: fnd_file.put_line
5092: ( fnd_file.log, ' NOTE : The profile GMF: Use Cost Alloc Factor in Lot Costing has been set to ''Yes''.
5093: Since few products have step association defined and few does not, this profile will NOT be used.');
5094: l_cost_alloc_profile := 0;
5095: END IF;
5096:

Line 5100: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : No Step material Associations. So Go Ahead ');

5096:
5097: ELSIF (NVL (l_count, 0) = 0) THEN
5098: IF l_debug_level >= l_debug_level_high
5099: THEN
5100: fnd_file.put_line (fnd_file.log, ' Cost Allocation Factor : No Step material Associations. So Go Ahead ');
5101: END IF;
5102:
5103: -- Go Ahead.. The Number of steps having step material Association is zero.
5104: -- So all steps should have been attached to a single step by default which is the terminal step

Line 5108: fnd_file.put_line

5104: -- So all steps should have been attached to a single step by default which is the terminal step
5105: l_cost_alloc_profile := 1;
5106:
5107: ELSE -- The Products are associated with multiple steps. So don't use the profile
5108: fnd_file.put_line
5109: ( fnd_file.log, ' NOTE : The profile GMF: Use Cost Alloc Factor in Lot Costing has been set to ''Yes''.
5110: Since all the products are not yielded in a single step this profile will NOT be used.');
5111: l_cost_alloc_profile := 0;
5112: END IF; /* End if of IF( NVL(l_count,0) = 1) */

Line 5109: ( fnd_file.log, ' NOTE : The profile GMF: Use Cost Alloc Factor in Lot Costing has been set to ''Yes''.

5105: l_cost_alloc_profile := 1;
5106:
5107: ELSE -- The Products are associated with multiple steps. So don't use the profile
5108: fnd_file.put_line
5109: ( fnd_file.log, ' NOTE : The profile GMF: Use Cost Alloc Factor in Lot Costing has been set to ''Yes''.
5110: Since all the products are not yielded in a single step this profile will NOT be used.');
5111: l_cost_alloc_profile := 0;
5112: END IF; /* End if of IF( NVL(l_count,0) = 1) */
5113: END IF; /* End of IF (l_step_tab.COUNT = 1) */

Line 5156: fnd_file.put_line

5152: THEN
5153:
5154: IF l_debug_level < l_debug_level_high
5155: THEN
5156: fnd_file.put_line
5157: (fnd_file.log,'ERROR: Unable to convert from '
5158: ||l_step_tab(i).materials(j).trans_um
5159: ||' to '||l_step_tab(i).step_qty_uom||' for transaction ID '
5160: ||l_step_tab(i).materials(j).trans_id

Line 5157: (fnd_file.log,'ERROR: Unable to convert from '

5153:
5154: IF l_debug_level < l_debug_level_high
5155: THEN
5156: fnd_file.put_line
5157: (fnd_file.log,'ERROR: Unable to convert from '
5158: ||l_step_tab(i).materials(j).trans_um
5159: ||' to '||l_step_tab(i).step_qty_uom||' for transaction ID '
5160: ||l_step_tab(i).materials(j).trans_id
5161: );

Line 5163: fnd_file.put_line

5159: ||' to '||l_step_tab(i).step_qty_uom||' for transaction ID '
5160: ||l_step_tab(i).materials(j).trans_id
5161: );
5162: ELSE
5163: fnd_file.put_line
5164: (fnd_file.log,'ERROR: Unable to convert from '
5165: ||l_step_tab(i).materials(j).trans_um
5166: ||' to '||l_step_tab(i).step_qty_uom||' for transaction ID '
5167: ||l_step_tab(i).materials(j).trans_id

Line 5164: (fnd_file.log,'ERROR: Unable to convert from '

5160: ||l_step_tab(i).materials(j).trans_id
5161: );
5162: ELSE
5163: fnd_file.put_line
5164: (fnd_file.log,'ERROR: Unable to convert from '
5165: ||l_step_tab(i).materials(j).trans_um
5166: ||' to '||l_step_tab(i).step_qty_uom||' for transaction ID '
5167: ||l_step_tab(i).materials(j).trans_id
5168: ||' for item ID '

Line 5187: fnd_file.put_line

5183: END LOOP;
5184:
5185: IF l_debug_level >= l_debug_level_medium
5186: THEN
5187: fnd_file.put_line
5188: (fnd_file.log,'Loaded '||to_char(l_step_tab(i).materials.count)||' material txns');
5189: END IF;
5190:
5191: FOR j in 1..l_step_tab(i).materials.count

Line 5188: (fnd_file.log,'Loaded '||to_char(l_step_tab(i).materials.count)||' material txns');

5184:
5185: IF l_debug_level >= l_debug_level_medium
5186: THEN
5187: fnd_file.put_line
5188: (fnd_file.log,'Loaded '||to_char(l_step_tab(i).materials.count)||' material txns');
5189: END IF;
5190:
5191: FOR j in 1..l_step_tab(i).materials.count
5192: LOOP

Line 5276: fnd_file.put_line

5272: END IF;
5273:
5274: IF l_skip_this_batch
5275: THEN
5276: fnd_file.put_line
5277: (fnd_file.log, 'ERROR: Cannot calculate cost of lot '
5278: ||to_char(transaction_row.lot_number)
5279: ||' because material transaction '
5280: ||to_char(l_step_tab(i).materials(j).trans_id)

Line 5277: (fnd_file.log, 'ERROR: Cannot calculate cost of lot '

5273:
5274: IF l_skip_this_batch
5275: THEN
5276: fnd_file.put_line
5277: (fnd_file.log, 'ERROR: Cannot calculate cost of lot '
5278: ||to_char(transaction_row.lot_number)
5279: ||' because material transaction '
5280: ||to_char(l_step_tab(i).materials(j).trans_id)
5281: ||' cannot be costed'

Line 5365: fnd_file.put_line

5361: CLOSE item_cost_cursor;
5362:
5363: IF NOT l_step_tab(i).materials(j).cost_details.EXISTS(1)
5364: THEN
5365: fnd_file.put_line
5366: (fnd_file.log, 'ERROR: Cannot calculate cost of Lot Number '
5367: ||to_char(transaction_row.lot_number)
5368: ||' because item ID / Lot Number '
5369: ||to_char(l_step_tab(i).materials(j).item_id)

Line 5366: (fnd_file.log, 'ERROR: Cannot calculate cost of Lot Number '

5362:
5363: IF NOT l_step_tab(i).materials(j).cost_details.EXISTS(1)
5364: THEN
5365: fnd_file.put_line
5366: (fnd_file.log, 'ERROR: Cannot calculate cost of Lot Number '
5367: ||to_char(transaction_row.lot_number)
5368: ||' because item ID / Lot Number '
5369: ||to_char(l_step_tab(i).materials(j).item_id)
5370: ||'/'

Line 5426: fnd_file.put_line

5422: END LOOP;
5423:
5424: IF l_debug_level >= l_debug_level_medium
5425: THEN
5426: fnd_file.put_line
5427: (fnd_file.log,'Setting up step dependency index and quantities');
5428: END IF;
5429:
5430: -- Set up the step_index field in the 'next steps' nested tables

Line 5427: (fnd_file.log,'Setting up step dependency index and quantities');

5423:
5424: IF l_debug_level >= l_debug_level_medium
5425: THEN
5426: fnd_file.put_line
5427: (fnd_file.log,'Setting up step dependency index and quantities');
5428: END IF;
5429:
5430: -- Set up the step_index field in the 'next steps' nested tables
5431:

Line 5441: fnd_file.put_line

5437: THEN
5438:
5439: IF l_debug_level >= l_debug_level_medium
5440: THEN
5441: fnd_file.put_line
5442: (fnd_file.log,'Setting ('||to_char(i)||','||to_char(j)||') to '||to_char(k));
5443: END IF;
5444:
5445: l_step_tab(i).dependencies(j).step_index := k;

Line 5442: (fnd_file.log,'Setting ('||to_char(i)||','||to_char(j)||') to '||to_char(k));

5438:
5439: IF l_debug_level >= l_debug_level_medium
5440: THEN
5441: fnd_file.put_line
5442: (fnd_file.log,'Setting ('||to_char(i)||','||to_char(j)||') to '||to_char(k));
5443: END IF;
5444:
5445: l_step_tab(i).dependencies(j).step_index := k;
5446:

Line 5454: fnd_file.put_line

5450: END LOOP;
5451:
5452: IF l_debug_level >= l_debug_level_medium
5453: THEN
5454: fnd_file.put_line
5455: (fnd_file.log,'End of transaction load/costing loop for iteration '||to_char(i));
5456: END IF;
5457:
5458: END LOOP; -- End of loop that retrieves and costs the transactions

Line 5455: (fnd_file.log,'End of transaction load/costing loop for iteration '||to_char(i));

5451:
5452: IF l_debug_level >= l_debug_level_medium
5453: THEN
5454: fnd_file.put_line
5455: (fnd_file.log,'End of transaction load/costing loop for iteration '||to_char(i));
5456: END IF;
5457:
5458: END LOOP; -- End of loop that retrieves and costs the transactions
5459:

Line 5465: fnd_file.put_line

5461:
5462: IF l_skip_this_batch
5463: THEN
5464: -- For one reason or another we cannot cost this lot.
5465: fnd_file.put_line
5466: ( fnd_file.log,'ERROR: Batch ID '
5467: ||to_char(transaction_row.doc_id)
5468: ||' was skipped because of missing cost(s)');
5469: l_return_status := 'E';

Line 5466: ( fnd_file.log,'ERROR: Batch ID '

5462: IF l_skip_this_batch
5463: THEN
5464: -- For one reason or another we cannot cost this lot.
5465: fnd_file.put_line
5466: ( fnd_file.log,'ERROR: Batch ID '
5467: ||to_char(transaction_row.doc_id)
5468: ||' was skipped because of missing cost(s)');
5469: l_return_status := 'E';
5470: l_uncostable_lots_tab(transaction_row.orgn_id||'-'||transaction_row.inventory_item_id||'-'||transaction_row.lot_number) := transaction_row.inventory_item_id;

Line 5513: fnd_file.put_line

5509: -- step_index (this is the index of the step in l_step_tab)
5510:
5511: IF l_debug_level >= l_debug_level_low
5512: THEN
5513: fnd_file.put_line
5514: (fnd_file.log,'Transaction costs complete. Starting rollup for batch ID '
5515: ||to_char(transaction_row.doc_id)
5516: );
5517: END IF;

Line 5514: (fnd_file.log,'Transaction costs complete. Starting rollup for batch ID '

5510:
5511: IF l_debug_level >= l_debug_level_low
5512: THEN
5513: fnd_file.put_line
5514: (fnd_file.log,'Transaction costs complete. Starting rollup for batch ID '
5515: ||to_char(transaction_row.doc_id)
5516: );
5517: END IF;
5518:

Line 5524: fnd_file.put_line

5520: FOR i in 1..l_step_tab.count
5521: LOOP
5522: IF l_debug_level >= l_debug_level_medium
5523: THEN
5524: fnd_file.put_line
5525: (fnd_file.log,'Inside rollup loop for step index '||to_char(i));
5526: END IF;
5527:
5528: -- We need to set up the step_costs table. This holds the combined inherited costs (that is

Line 5525: (fnd_file.log,'Inside rollup loop for step index '||to_char(i));

5521: LOOP
5522: IF l_debug_level >= l_debug_level_medium
5523: THEN
5524: fnd_file.put_line
5525: (fnd_file.log,'Inside rollup loop for step index '||to_char(i));
5526: END IF;
5527:
5528: -- We need to set up the step_costs table. This holds the combined inherited costs (that is
5529: -- those that have come from prior steps) and the current costs (ie those that have been

Line 5583: fnd_file.put_line

5579: cur_cost_tab.delete; /* Bug 3533452 */
5580:
5581: IF l_debug_level >= l_debug_level_medium
5582: THEN
5583: fnd_file.put_line
5584: (fnd_file.log,'Setting up new_cost_tab');
5585: END IF;
5586:
5587: -- Bug 3548217

Line 5584: (fnd_file.log,'Setting up new_cost_tab');

5580:
5581: IF l_debug_level >= l_debug_level_medium
5582: THEN
5583: fnd_file.put_line
5584: (fnd_file.log,'Setting up new_cost_tab');
5585: END IF;
5586:
5587: -- Bug 3548217
5588: IF l_step_tab(i).step_qty_uom <> l_step_tab(i).materials(j).trans_um

Line 5605: fnd_file.put_line

5601: );
5602:
5603: IF l_tran_qty < 0
5604: THEN
5605: fnd_file.put_line
5606: (fnd_file.log,'ERROR: Unable to convert to step qty uom for transaction ID '
5607: ||l_step_tab(i).materials(j).trans_id
5608: );
5609: l_return_status := 'E';

Line 5606: (fnd_file.log,'ERROR: Unable to convert to step qty uom for transaction ID '

5602:
5603: IF l_tran_qty < 0
5604: THEN
5605: fnd_file.put_line
5606: (fnd_file.log,'ERROR: Unable to convert to step qty uom for transaction ID '
5607: ||l_step_tab(i).materials(j).trans_id
5608: );
5609: l_return_status := 'E';
5610: l_tmp := FALSE;

Line 5645: fnd_file.put_line (fnd_file.log,' Setting Cost Allocation Factor to zero as output_qty is zero.');

5641: IF l_step_tab(i).output_qty<>0 THEN /*Condition Added - Bug 5985680, pmarada */
5642: l_cost_factor := l_tran_qty /l_step_tab(i).output_qty;
5643: ELSE
5644: l_cost_factor := 0;
5645: fnd_file.put_line (fnd_file.log,' Setting Cost Allocation Factor to zero as output_qty is zero.');
5646: END IF;
5647: END IF;
5648: /***** Bug 4057323 - Use Cost Allocation Factor Depending on Profile value - End *****/
5649:

Line 5652: fnd_file.put_line (fnd_file.log,' Cost Allocation Factor : For the transaction of '||l_step_tab(i).materials(j).trans_id

5648: /***** Bug 4057323 - Use Cost Allocation Factor Depending on Profile value - End *****/
5649:
5650: IF l_debug_level >= l_debug_level_high
5651: THEN
5652: fnd_file.put_line (fnd_file.log,' Cost Allocation Factor : For the transaction of '||l_step_tab(i).materials(j).trans_id
5653: || ' the new cost_factor is '|| l_cost_factor);
5654: END IF;
5655:
5656: -- Reduce remaining output_qty for next time around

Line 5671: fnd_file.put_line (fnd_file.log,' Setting Cost Allocation Factor to zero as step_qty is zero.');

5667: IF l_step_tab(i).step_qty <> 0 THEN /*Condition Added - Bug 5985680, pmarada */
5668: l_cost_factor := l_tran_qty / l_step_tab(i).step_qty;
5669: ELSE
5670: l_cost_factor := 0;
5671: fnd_file.put_line (fnd_file.log,' Setting Cost Allocation Factor to zero as step_qty is zero.');
5672: END IF;
5673: END IF;
5674: /***** Bug 4057323 - Use Cost Allocation Factor Depending on Profile value - End *****/
5675: END IF;

Line 5679: fnd_file.put_line

5675: END IF;
5676:
5677: IF l_debug_level >= l_debug_level_low
5678: THEN
5679: fnd_file.put_line
5680: (fnd_file.log,'Cost factor for yield costs calculation is '||l_cost_factor);
5681:
5682: fnd_file.put_line(fnd_file.log,'Step costs before are');
5683: FOR jj IN 1..l_step_tab(i).step_costs.COUNT

Line 5680: (fnd_file.log,'Cost factor for yield costs calculation is '||l_cost_factor);

5676:
5677: IF l_debug_level >= l_debug_level_low
5678: THEN
5679: fnd_file.put_line
5680: (fnd_file.log,'Cost factor for yield costs calculation is '||l_cost_factor);
5681:
5682: fnd_file.put_line(fnd_file.log,'Step costs before are');
5683: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5684: LOOP

Line 5682: fnd_file.put_line(fnd_file.log,'Step costs before are');

5678: THEN
5679: fnd_file.put_line
5680: (fnd_file.log,'Cost factor for yield costs calculation is '||l_cost_factor);
5681:
5682: fnd_file.put_line(fnd_file.log,'Step costs before are');
5683: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5684: LOOP
5685: fnd_file.put_line
5686: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);

Line 5685: fnd_file.put_line

5681:
5682: fnd_file.put_line(fnd_file.log,'Step costs before are');
5683: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5684: LOOP
5685: fnd_file.put_line
5686: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);
5687: END LOOP;
5688: END IF;
5689:

Line 5686: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);

5682: fnd_file.put_line(fnd_file.log,'Step costs before are');
5683: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5684: LOOP
5685: fnd_file.put_line
5686: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);
5687: END LOOP;
5688: END IF;
5689:
5690: -- Now calculate the costs of the yielded lot and reduce the step costs by the same amounts

Line 5723: fnd_file.put_line(fnd_file.log,'Step costs after are');

5719: -- End 3548217
5720:
5721: IF l_debug_level >= l_debug_level_low
5722: THEN
5723: fnd_file.put_line(fnd_file.log,'Step costs after are');
5724: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5725: LOOP
5726: fnd_file.put_line
5727: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);

Line 5726: fnd_file.put_line

5722: THEN
5723: fnd_file.put_line(fnd_file.log,'Step costs after are');
5724: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5725: LOOP
5726: fnd_file.put_line
5727: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);
5728: END LOOP;
5729: fnd_file.put_line(fnd_file.log,'New costs after are');
5730: FOR jj IN 1..new_cost_tab.COUNT

Line 5727: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);

5723: fnd_file.put_line(fnd_file.log,'Step costs after are');
5724: FOR jj IN 1..l_step_tab(i).step_costs.COUNT
5725: LOOP
5726: fnd_file.put_line
5727: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);
5728: END LOOP;
5729: fnd_file.put_line(fnd_file.log,'New costs after are');
5730: FOR jj IN 1..new_cost_tab.COUNT
5731: LOOP

Line 5729: fnd_file.put_line(fnd_file.log,'New costs after are');

5725: LOOP
5726: fnd_file.put_line
5727: (fnd_file.log,l_step_tab(i).step_costs(jj).component_cost);
5728: END LOOP;
5729: fnd_file.put_line(fnd_file.log,'New costs after are');
5730: FOR jj IN 1..new_cost_tab.COUNT
5731: LOOP
5732: fnd_file.put_line
5733: (fnd_file.log,new_cost_tab(jj).component_cost);

Line 5732: fnd_file.put_line

5728: END LOOP;
5729: fnd_file.put_line(fnd_file.log,'New costs after are');
5730: FOR jj IN 1..new_cost_tab.COUNT
5731: LOOP
5732: fnd_file.put_line
5733: (fnd_file.log,new_cost_tab(jj).component_cost);
5734: END LOOP;
5735: END IF;
5736:

Line 5733: (fnd_file.log,new_cost_tab(jj).component_cost);

5729: fnd_file.put_line(fnd_file.log,'New costs after are');
5730: FOR jj IN 1..new_cost_tab.COUNT
5731: LOOP
5732: fnd_file.put_line
5733: (fnd_file.log,new_cost_tab(jj).component_cost);
5734: END LOOP;
5735: END IF;
5736:
5737: -- See if this transaction is the transaction that has yielded the lot being costed

Line 5761: fnd_file.put_line

5757: LOOP
5758: l_burden_costs_tab(l).component_cost := l_burden_costs_tab(l).component_cost * transaction_row.trans_qty;
5759: IF l_debug_level >= l_debug_level_medium
5760: THEN
5761: fnd_file.put_line
5762: (fnd_file.log,'l_burden_costs_tab['||l||'] is '||l_burden_costs_tab(l).component_cost);
5763: END IF;
5764: END LOOP;
5765:

Line 5762: (fnd_file.log,'l_burden_costs_tab['||l||'] is '||l_burden_costs_tab(l).component_cost);

5758: l_burden_costs_tab(l).component_cost := l_burden_costs_tab(l).component_cost * transaction_row.trans_qty;
5759: IF l_debug_level >= l_debug_level_medium
5760: THEN
5761: fnd_file.put_line
5762: (fnd_file.log,'l_burden_costs_tab['||l||'] is '||l_burden_costs_tab(l).component_cost);
5763: END IF;
5764: END LOOP;
5765:
5766:

Line 5822: fnd_file.put_line (fnd_file.log, 'Before create_cost_header in process_batch ');

5818:
5819: l_new_cost := new_cost.unit_cost;
5820: IF l_debug_level >= l_debug_level_low
5821: THEN
5822: fnd_file.put_line (fnd_file.log, 'Before create_cost_header in process_batch ');
5823: fnd_file.put_line (fnd_file.log, 'new unit cost: '||new_cost.unit_cost);
5824: fnd_file.put_line (fnd_file.log, 'l_new unit cost: '||l_new_cost);
5825: fnd_file.put_line (fnd_file.log, 'trans qty: '||transaction_row.trans_qty);
5826: fnd_file.put_line (fnd_file.log, 'onhand qty: '||old_cost.onhand_qty);

Line 5823: fnd_file.put_line (fnd_file.log, 'new unit cost: '||new_cost.unit_cost);

5819: l_new_cost := new_cost.unit_cost;
5820: IF l_debug_level >= l_debug_level_low
5821: THEN
5822: fnd_file.put_line (fnd_file.log, 'Before create_cost_header in process_batch ');
5823: fnd_file.put_line (fnd_file.log, 'new unit cost: '||new_cost.unit_cost);
5824: fnd_file.put_line (fnd_file.log, 'l_new unit cost: '||l_new_cost);
5825: fnd_file.put_line (fnd_file.log, 'trans qty: '||transaction_row.trans_qty);
5826: fnd_file.put_line (fnd_file.log, 'onhand qty: '||old_cost.onhand_qty);
5827: END IF;

Line 5824: fnd_file.put_line (fnd_file.log, 'l_new unit cost: '||l_new_cost);

5820: IF l_debug_level >= l_debug_level_low
5821: THEN
5822: fnd_file.put_line (fnd_file.log, 'Before create_cost_header in process_batch ');
5823: fnd_file.put_line (fnd_file.log, 'new unit cost: '||new_cost.unit_cost);
5824: fnd_file.put_line (fnd_file.log, 'l_new unit cost: '||l_new_cost);
5825: fnd_file.put_line (fnd_file.log, 'trans qty: '||transaction_row.trans_qty);
5826: fnd_file.put_line (fnd_file.log, 'onhand qty: '||old_cost.onhand_qty);
5827: END IF;
5828:

Line 5825: fnd_file.put_line (fnd_file.log, 'trans qty: '||transaction_row.trans_qty);

5821: THEN
5822: fnd_file.put_line (fnd_file.log, 'Before create_cost_header in process_batch ');
5823: fnd_file.put_line (fnd_file.log, 'new unit cost: '||new_cost.unit_cost);
5824: fnd_file.put_line (fnd_file.log, 'l_new unit cost: '||l_new_cost);
5825: fnd_file.put_line (fnd_file.log, 'trans qty: '||transaction_row.trans_qty);
5826: fnd_file.put_line (fnd_file.log, 'onhand qty: '||old_cost.onhand_qty);
5827: END IF;
5828:
5829: -- At this stage we have all the header and cost component information we need

Line 5826: fnd_file.put_line (fnd_file.log, 'onhand qty: '||old_cost.onhand_qty);

5822: fnd_file.put_line (fnd_file.log, 'Before create_cost_header in process_batch ');
5823: fnd_file.put_line (fnd_file.log, 'new unit cost: '||new_cost.unit_cost);
5824: fnd_file.put_line (fnd_file.log, 'l_new unit cost: '||l_new_cost);
5825: fnd_file.put_line (fnd_file.log, 'trans qty: '||transaction_row.trans_qty);
5826: fnd_file.put_line (fnd_file.log, 'onhand qty: '||old_cost.onhand_qty);
5827: END IF;
5828:
5829: -- At this stage we have all the header and cost component information we need
5830: -- to store the costs in the database.

Line 5916: fnd_file.put_line (fnd_file.log, 'Completed inserts into tables in process_batch ');

5912: );
5913:
5914: IF l_debug_level >= l_debug_level_low
5915: THEN
5916: fnd_file.put_line (fnd_file.log, 'Completed inserts into tables in process_batch ');
5917: END IF;
5918:
5919: IF l_return_status <> 'S'
5920: THEN

Line 5933: fnd_file.put_line

5929:
5930: IF l_debug_level >= l_debug_level_medium
5931: THEN
5932:
5933: fnd_file.put_line
5934: ( fnd_file.log,'New cost tab has '||to_char(new_cost_tab.count)||' entries:');
5935:
5936: FOR k IN 1 .. new_cost_tab.COUNT
5937: LOOP

Line 5934: ( fnd_file.log,'New cost tab has '||to_char(new_cost_tab.count)||' entries:');

5930: IF l_debug_level >= l_debug_level_medium
5931: THEN
5932:
5933: fnd_file.put_line
5934: ( fnd_file.log,'New cost tab has '||to_char(new_cost_tab.count)||' entries:');
5935:
5936: FOR k IN 1 .. new_cost_tab.COUNT
5937: LOOP
5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

Line 5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

5934: ( fnd_file.log,'New cost tab has '||to_char(new_cost_tab.count)||' entries:');
5935:
5936: FOR k IN 1 .. new_cost_tab.COUNT
5937: LOOP
5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
5939: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
5940: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
5942: fnd_file.put_line(fnd_file.log,'====================================');

Line 5939: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

5935:
5936: FOR k IN 1 .. new_cost_tab.COUNT
5937: LOOP
5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
5939: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
5940: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
5942: fnd_file.put_line(fnd_file.log,'====================================');
5943: END LOOP;

Line 5940: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);

5936: FOR k IN 1 .. new_cost_tab.COUNT
5937: LOOP
5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
5939: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
5940: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
5942: fnd_file.put_line(fnd_file.log,'====================================');
5943: END LOOP;
5944:

Line 5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

5937: LOOP
5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
5939: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
5940: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
5942: fnd_file.put_line(fnd_file.log,'====================================');
5943: END LOOP;
5944:
5945: fnd_file.put_line(fnd_file.log,' New total cost is : '||new_cost.unit_cost);

Line 5942: fnd_file.put_line(fnd_file.log,'====================================');

5938: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
5939: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
5940: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
5942: fnd_file.put_line(fnd_file.log,'====================================');
5943: END LOOP;
5944:
5945: fnd_file.put_line(fnd_file.log,' New total cost is : '||new_cost.unit_cost);
5946: fnd_file.put_line(fnd_file.log,' New unit cost is : '||new_cost.unit_cost/transaction_row.trans_qty);

Line 5945: fnd_file.put_line(fnd_file.log,' New total cost is : '||new_cost.unit_cost);

5941: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
5942: fnd_file.put_line(fnd_file.log,'====================================');
5943: END LOOP;
5944:
5945: fnd_file.put_line(fnd_file.log,' New total cost is : '||new_cost.unit_cost);
5946: fnd_file.put_line(fnd_file.log,' New unit cost is : '||new_cost.unit_cost/transaction_row.trans_qty);
5947:
5948: END IF;
5949:

Line 5946: fnd_file.put_line(fnd_file.log,' New unit cost is : '||new_cost.unit_cost/transaction_row.trans_qty);

5942: fnd_file.put_line(fnd_file.log,'====================================');
5943: END LOOP;
5944:
5945: fnd_file.put_line(fnd_file.log,' New total cost is : '||new_cost.unit_cost);
5946: fnd_file.put_line(fnd_file.log,' New unit cost is : '||new_cost.unit_cost/transaction_row.trans_qty);
5947:
5948: END IF;
5949:
5950: create_cost_header

Line 6024: fnd_file.put_line

6020: END LOOP;
6021:
6022: IF l_debug_level >= l_debug_level_medium
6023: THEN
6024: fnd_file.put_line
6025: (fnd_file.log,'After yield check');
6026: END IF;
6027:
6028: -- If we are not on a terminal step, we have to roll the costs into

Line 6025: (fnd_file.log,'After yield check');

6021:
6022: IF l_debug_level >= l_debug_level_medium
6023: THEN
6024: fnd_file.put_line
6025: (fnd_file.log,'After yield check');
6026: END IF;
6027:
6028: -- If we are not on a terminal step, we have to roll the costs into
6029: -- the next step(s) in the dependency chain. Also, if the route divides

Line 6038: fnd_file.put_line

6034: THEN
6035:
6036: IF l_debug_level >= l_debug_level_medium
6037: THEN
6038: fnd_file.put_line
6039: (fnd_file.log,'Before quantity accumulation');
6040: END IF;
6041:
6042: l_total_qty := 0;

Line 6039: (fnd_file.log,'Before quantity accumulation');

6035:
6036: IF l_debug_level >= l_debug_level_medium
6037: THEN
6038: fnd_file.put_line
6039: (fnd_file.log,'Before quantity accumulation');
6040: END IF;
6041:
6042: l_total_qty := 0;
6043:

Line 6051: fnd_file.put_line

6047: END LOOP;
6048:
6049: IF l_debug_level >= l_debug_level_medium
6050: THEN
6051: fnd_file.put_line
6052: (fnd_file.log,'After quantity accumulation, total_qty is'
6053: ||to_char(l_total_qty,'999999999.99')
6054: );
6055: END IF;

Line 6052: (fnd_file.log,'After quantity accumulation, total_qty is'

6048:
6049: IF l_debug_level >= l_debug_level_medium
6050: THEN
6051: fnd_file.put_line
6052: (fnd_file.log,'After quantity accumulation, total_qty is'
6053: ||to_char(l_total_qty,'999999999.99')
6054: );
6055: END IF;
6056:

Line 6064: fnd_file.put_line

6060: l_cost_factor := l_step_tab(i).dependencies(j).step_qty / l_total_qty;
6061:
6062: IF l_debug_level >= l_debug_level_medium
6063: THEN
6064: fnd_file.put_line
6065: (fnd_file.log,'Cost factor is '||to_char(l_cost_factor,'9999.99'));
6066: END IF;
6067:
6068: -- Roll current costs into next step(s). We loop through all costs accumulated

Line 6065: (fnd_file.log,'Cost factor is '||to_char(l_cost_factor,'9999.99'));

6061:
6062: IF l_debug_level >= l_debug_level_medium
6063: THEN
6064: fnd_file.put_line
6065: (fnd_file.log,'Cost factor is '||to_char(l_cost_factor,'9999.99'));
6066: END IF;
6067:
6068: -- Roll current costs into next step(s). We loop through all costs accumulated
6069: -- and apply the above factor to each cost when rolling them forward

Line 6082: fnd_file.put_line

6078: THEN
6079:
6080: IF l_debug_level >= l_debug_level_medium
6081: THEN
6082: fnd_file.put_line
6083: (fnd_file.log,'Rolling costs of step '
6084: ||to_char(i)||' into step '||to_char(l_step_index));
6085: END IF;
6086:

Line 6083: (fnd_file.log,'Rolling costs of step '

6079:
6080: IF l_debug_level >= l_debug_level_medium
6081: THEN
6082: fnd_file.put_line
6083: (fnd_file.log,'Rolling costs of step '
6084: ||to_char(i)||' into step '||to_char(l_step_index));
6085: END IF;
6086:
6087: -- Now roll current costs into the next step

Line 6168: fnd_file.put_line

6164:
6165: END IF;
6166: IF l_debug_level >= l_debug_level_medium
6167: THEN
6168: fnd_file.put_line
6169: (fnd_file.log,'Entered Procedure: '||procedure_name);
6170: END IF;
6171:
6172: END process_batch;

Line 6169: (fnd_file.log,'Entered Procedure: '||procedure_name);

6165: END IF;
6166: IF l_debug_level >= l_debug_level_medium
6167: THEN
6168: fnd_file.put_line
6169: (fnd_file.log,'Entered Procedure: '||procedure_name);
6170: END IF;
6171:
6172: END process_batch;
6173:

Line 6195: fnd_file.put_line

6191:
6192: procedure_name := 'Process Creation';
6193: IF l_debug_level >= l_debug_level_medium
6194: THEN
6195: fnd_file.put_line
6196: (fnd_file.log,'Entered Procedure: '||procedure_name);
6197: END IF;
6198:
6199: -- We assume that no lot cost exists, as the lot is being created by this transaction.

Line 6196: (fnd_file.log,'Entered Procedure: '||procedure_name);

6192: procedure_name := 'Process Creation';
6193: IF l_debug_level >= l_debug_level_medium
6194: THEN
6195: fnd_file.put_line
6196: (fnd_file.log,'Entered Procedure: '||procedure_name);
6197: END IF;
6198:
6199: -- We assume that no lot cost exists, as the lot is being created by this transaction.
6200: -- The only costs we can determine come from burdens.

Line 6235: fnd_file.put_line

6231: IF l_burdens_total <> 0
6232: THEN
6233: IF l_debug_level >= l_debug_level_medium
6234: THEN
6235: fnd_file.put_line
6236: (fnd_file.log,'Processing' || l_burden_costs_tab.count ||' burdens for CREI transaction ID '||transaction_row.transaction_id);
6237: END IF;
6238:
6239: FOR i IN 1..l_burden_costs_tab.COUNT

Line 6236: (fnd_file.log,'Processing' || l_burden_costs_tab.count ||' burdens for CREI transaction ID '||transaction_row.transaction_id);

6232: THEN
6233: IF l_debug_level >= l_debug_level_medium
6234: THEN
6235: fnd_file.put_line
6236: (fnd_file.log,'Processing' || l_burden_costs_tab.count ||' burdens for CREI transaction ID '||transaction_row.transaction_id);
6237: END IF;
6238:
6239: FOR i IN 1..l_burden_costs_tab.COUNT
6240: LOOP

Line 6260: fnd_file.put_line

6256: ELSE
6257:
6258: IF l_debug_level >= l_debug_level_medium
6259: THEN
6260: fnd_file.put_line
6261: (fnd_file.log,'No burdens found, retrieving default component class and analysis code for cost details');
6262: END IF;
6263:
6264:

Line 6261: (fnd_file.log,'No burdens found, retrieving default component class and analysis code for cost details');

6257:
6258: IF l_debug_level >= l_debug_level_medium
6259: THEN
6260: fnd_file.put_line
6261: (fnd_file.log,'No burdens found, retrieving default component class and analysis code for cost details');
6262: END IF;
6263:
6264:
6265: OPEN component_class_cursor

Line 6272: fnd_file.put_line

6268: CLOSE component_class_cursor;
6269:
6270: IF l_debug_level >= l_debug_level_medium
6271: THEN
6272: fnd_file.put_line
6273: (fnd_file.log,'Creating new cost detail row');
6274: END IF;
6275:
6276: create_cost_detail

Line 6273: (fnd_file.log,'Creating new cost detail row');

6269:
6270: IF l_debug_level >= l_debug_level_medium
6271: THEN
6272: fnd_file.put_line
6273: (fnd_file.log,'Creating new cost detail row');
6274: END IF;
6275:
6276: create_cost_detail
6277: ( l_header_id

Line 6296: fnd_file.put_line

6292: THEN
6293:
6294: IF l_debug_level >= l_debug_level_medium
6295: THEN
6296: fnd_file.put_line
6297: (fnd_file.log,'Creating new material cost transaction');
6298: END IF;
6299:
6300: create_material_transaction

Line 6297: (fnd_file.log,'Creating new material cost transaction');

6293:
6294: IF l_debug_level >= l_debug_level_medium
6295: THEN
6296: fnd_file.put_line
6297: (fnd_file.log,'Creating new material cost transaction');
6298: END IF;
6299:
6300: create_material_transaction
6301: ( l_header_id

Line 6328: fnd_file.put_line

6324: END IF;
6325: END IF;
6326: IF l_debug_level >= l_debug_level_medium
6327: THEN
6328: fnd_file.put_line
6329: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6330: END IF;
6331:
6332: EXCEPTION

Line 6329: (fnd_file.log,'Leaving Procedure: '||procedure_name);

6325: END IF;
6326: IF l_debug_level >= l_debug_level_medium
6327: THEN
6328: fnd_file.put_line
6329: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6330: END IF;
6331:
6332: EXCEPTION
6333: WHEN OTHERS

Line 6334: THEN fnd_file.put_line

6330: END IF;
6331:
6332: EXCEPTION
6333: WHEN OTHERS
6334: THEN fnd_file.put_line
6335: (fnd_file.log,'Failed in procedure process_creation with error');
6336: fnd_file.put_line
6337: (fnd_file.log,SQLERRM);
6338: l_return_status := 'U';

Line 6335: (fnd_file.log,'Failed in procedure process_creation with error');

6331:
6332: EXCEPTION
6333: WHEN OTHERS
6334: THEN fnd_file.put_line
6335: (fnd_file.log,'Failed in procedure process_creation with error');
6336: fnd_file.put_line
6337: (fnd_file.log,SQLERRM);
6338: l_return_status := 'U';
6339: END process_creation;

Line 6336: fnd_file.put_line

6332: EXCEPTION
6333: WHEN OTHERS
6334: THEN fnd_file.put_line
6335: (fnd_file.log,'Failed in procedure process_creation with error');
6336: fnd_file.put_line
6337: (fnd_file.log,SQLERRM);
6338: l_return_status := 'U';
6339: END process_creation;
6340:

Line 6337: (fnd_file.log,SQLERRM);

6333: WHEN OTHERS
6334: THEN fnd_file.put_line
6335: (fnd_file.log,'Failed in procedure process_creation with error');
6336: fnd_file.put_line
6337: (fnd_file.log,SQLERRM);
6338: l_return_status := 'U';
6339: END process_creation;
6340:
6341:

Line 6361: fnd_file.put_line

6357:
6358: procedure_name := 'Process Sales Order';
6359: IF l_debug_level >= l_debug_level_medium
6360: THEN
6361: fnd_file.put_line
6362: (fnd_file.log,'Entered Procedure: '||procedure_name);
6363: END IF;
6364: -- This is a debit on the source organization so treat this as an adjustment. Returns are handled
6365: -- as PORC transactions.

Line 6362: (fnd_file.log,'Entered Procedure: '||procedure_name);

6358: procedure_name := 'Process Sales Order';
6359: IF l_debug_level >= l_debug_level_medium
6360: THEN
6361: fnd_file.put_line
6362: (fnd_file.log,'Entered Procedure: '||procedure_name);
6363: END IF;
6364: -- This is a debit on the source organization so treat this as an adjustment. Returns are handled
6365: -- as PORC transactions.
6366:

Line 6371: fnd_file.put_line

6367: process_adjustment;
6368:
6369: IF l_debug_level >= l_debug_level_medium
6370: THEN
6371: fnd_file.put_line
6372: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6373: END IF;
6374:
6375: END process_sales_order;

Line 6372: (fnd_file.log,'Leaving Procedure: '||procedure_name);

6368:
6369: IF l_debug_level >= l_debug_level_medium
6370: THEN
6371: fnd_file.put_line
6372: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6373: END IF;
6374:
6375: END process_sales_order;
6376:

Line 6395: fnd_file.put_line

6391:
6392: procedure_name := 'Process cycle count';
6393: IF l_debug_level >= l_debug_level_medium
6394: THEN
6395: fnd_file.put_line
6396: (fnd_file.log,'Entered Procedure: '||procedure_name);
6397: END IF;
6398:
6399: -- For costing purposes this is equivalent to an adjustment

Line 6396: (fnd_file.log,'Entered Procedure: '||procedure_name);

6392: procedure_name := 'Process cycle count';
6393: IF l_debug_level >= l_debug_level_medium
6394: THEN
6395: fnd_file.put_line
6396: (fnd_file.log,'Entered Procedure: '||procedure_name);
6397: END IF;
6398:
6399: -- For costing purposes this is equivalent to an adjustment
6400:

Line 6404: fnd_file.put_line

6400:
6401: process_adjustment;
6402: IF l_debug_level >= l_debug_level_medium
6403: THEN
6404: fnd_file.put_line
6405: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6406: END IF;
6407:
6408: END process_cycle_count;

Line 6405: (fnd_file.log,'Leaving Procedure: '||procedure_name);

6401: process_adjustment;
6402: IF l_debug_level >= l_debug_level_medium
6403: THEN
6404: fnd_file.put_line
6405: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6406: END IF;
6407:
6408: END process_cycle_count;
6409:

Line 6450: fnd_file.put_line

6446: BEGIN
6447: procedure_name := 'Delete Lot Costs';
6448: IF l_debug_level >= l_debug_level_medium
6449: THEN
6450: fnd_file.put_line
6451: (fnd_file.log,'Entered Procedure: '||procedure_name);
6452: END IF;
6453:
6454: l_rows_to_delete := 1000;

Line 6451: (fnd_file.log,'Entered Procedure: '||procedure_name);

6447: procedure_name := 'Delete Lot Costs';
6448: IF l_debug_level >= l_debug_level_medium
6449: THEN
6450: fnd_file.put_line
6451: (fnd_file.log,'Entered Procedure: '||procedure_name);
6452: END IF;
6453:
6454: l_rows_to_delete := 1000;
6455: l_matl_rows_deleted := 0;

Line 6502: fnd_file.put_line(fnd_File.LOG, '#of rows to delete in cost header: ' || l_header_ids_tab.count);

6498: l_max_loop_cnt := ceil(l_header_ids_tab.count/l_rows_to_delete);
6499: END IF;
6500:
6501:
6502: fnd_file.put_line(fnd_File.LOG, '#of rows to delete in cost header: ' || l_header_ids_tab.count);
6503: fnd_file.put_line(fnd_File.LOG, 'l_max_loop_cnt: ' || l_max_loop_cnt);
6504:
6505: FOR i in 1..l_max_loop_cnt
6506: LOOP

Line 6503: fnd_file.put_line(fnd_File.LOG, 'l_max_loop_cnt: ' || l_max_loop_cnt);

6499: END IF;
6500:
6501:
6502: fnd_file.put_line(fnd_File.LOG, '#of rows to delete in cost header: ' || l_header_ids_tab.count);
6503: fnd_file.put_line(fnd_File.LOG, 'l_max_loop_cnt: ' || l_max_loop_cnt);
6504:
6505: FOR i in 1..l_max_loop_cnt
6506: LOOP
6507:

Line 6558: fnd_file.put_line(fnd_File.LOG, ' ' || l_matl_rows_deleted || ' rows deleted from gmf_material_lot_cost_txns.');

6554: DELETE FROM gmf_lot_costs
6555: WHERE rowid in l_rowids_tab(indx);
6556:
6557:
6558: fnd_file.put_line(fnd_File.LOG, ' ' || l_matl_rows_deleted || ' rows deleted from gmf_material_lot_cost_txns.');
6559: fnd_file.put_line(fnd_File.LOG, ' ' || l_cdtl_rows_deleted || ' rows deleted from gmf_lot_cost_details.');
6560: fnd_file.put_line(fnd_File.LOG, ' ' || SQL%ROWCOUNT || ' rows deleted from gmf_lot_costs.');
6561:
6562:

Line 6559: fnd_file.put_line(fnd_File.LOG, ' ' || l_cdtl_rows_deleted || ' rows deleted from gmf_lot_cost_details.');

6555: WHERE rowid in l_rowids_tab(indx);
6556:
6557:
6558: fnd_file.put_line(fnd_File.LOG, ' ' || l_matl_rows_deleted || ' rows deleted from gmf_material_lot_cost_txns.');
6559: fnd_file.put_line(fnd_File.LOG, ' ' || l_cdtl_rows_deleted || ' rows deleted from gmf_lot_cost_details.');
6560: fnd_file.put_line(fnd_File.LOG, ' ' || SQL%ROWCOUNT || ' rows deleted from gmf_lot_costs.');
6561:
6562:
6563: COMMIT;

Line 6560: fnd_file.put_line(fnd_File.LOG, ' ' || SQL%ROWCOUNT || ' rows deleted from gmf_lot_costs.');

6556:
6557:
6558: fnd_file.put_line(fnd_File.LOG, ' ' || l_matl_rows_deleted || ' rows deleted from gmf_material_lot_cost_txns.');
6559: fnd_file.put_line(fnd_File.LOG, ' ' || l_cdtl_rows_deleted || ' rows deleted from gmf_lot_cost_details.');
6560: fnd_file.put_line(fnd_File.LOG, ' ' || SQL%ROWCOUNT || ' rows deleted from gmf_lot_costs.');
6561:
6562:
6563: COMMIT;
6564:

Line 6596: fnd_file.put_line(fnd_File.LOG, ' No rows found to delete.');

6592: l_matl_rows_deleted := l_matl_rows_deleted + SQL%ROWCOUNT;
6593:
6594:
6595: IF l_matl_rows_deleted = 0 THEN
6596: fnd_file.put_line(fnd_File.LOG, ' No rows found to delete.');
6597: END IF;
6598:
6599: COMMIT;
6600: /***** Bug 4094132 - Added the above Delete - End *****/

Line 6603: fnd_file.put_line

6599: COMMIT;
6600: /***** Bug 4094132 - Added the above Delete - End *****/
6601: IF l_debug_level >= l_debug_level_medium
6602: THEN
6603: fnd_file.put_line
6604: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6605: END IF;
6606:
6607: END delete_lot_costs;

Line 6604: (fnd_file.log,'Leaving Procedure: '||procedure_name);

6600: /***** Bug 4094132 - Added the above Delete - End *****/
6601: IF l_debug_level >= l_debug_level_medium
6602: THEN
6603: fnd_file.put_line
6604: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6605: END IF;
6606:
6607: END delete_lot_costs;
6608:

Line 6632: fnd_file.put_line

6628: BEGIN
6629: procedure_name := 'Process Lot Cost Adjustments';
6630: IF l_debug_level >= l_debug_level_medium
6631: THEN
6632: fnd_file.put_line
6633: (fnd_file.log,'Entered Procedure: '||procedure_name);
6634: END IF;
6635:
6636: IF l_debug_level >= l_debug_level_medium

Line 6633: (fnd_file.log,'Entered Procedure: '||procedure_name);

6629: procedure_name := 'Process Lot Cost Adjustments';
6630: IF l_debug_level >= l_debug_level_medium
6631: THEN
6632: fnd_file.put_line
6633: (fnd_file.log,'Entered Procedure: '||procedure_name);
6634: END IF;
6635:
6636: IF l_debug_level >= l_debug_level_medium
6637: THEN

Line 6638: fnd_file.put_line

6634: END IF;
6635:
6636: IF l_debug_level >= l_debug_level_medium
6637: THEN
6638: fnd_file.put_line
6639: (fnd_file.log,'INSIDE lot_cost_adjustments for transaction ID '||transaction_row.transaction_id);
6640: END IF;
6641:
6642: -- Load adjustment cost details

Line 6639: (fnd_file.log,'INSIDE lot_cost_adjustments for transaction ID '||transaction_row.transaction_id);

6635:
6636: IF l_debug_level >= l_debug_level_medium
6637: THEN
6638: fnd_file.put_line
6639: (fnd_file.log,'INSIDE lot_cost_adjustments for transaction ID '||transaction_row.transaction_id);
6640: END IF;
6641:
6642: -- Load adjustment cost details
6643:

Line 6742: fnd_file.put_line

6738: END IF;
6739: END IF;
6740: IF l_debug_level >= l_debug_level_medium
6741: THEN
6742: fnd_file.put_line
6743: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6744: END IF;
6745:
6746: END process_lot_cost_adjustments;

Line 6743: (fnd_file.log,'Leaving Procedure: '||procedure_name);

6739: END IF;
6740: IF l_debug_level >= l_debug_level_medium
6741: THEN
6742: fnd_file.put_line
6743: (fnd_file.log,'Leaving Procedure: '||procedure_name);
6744: END IF;
6745:
6746: END process_lot_cost_adjustments;
6747:

Line 6771: fnd_file.put_line (fnd_file.log,' Entering process_wip_batch');

6767: BEGIN
6768: procedure_name := 'Process WIP Batch';
6769: IF l_debug_level >= l_debug_level_medium
6770: THEN
6771: fnd_file.put_line (fnd_file.log,' Entering process_wip_batch');
6772: END IF;
6773:
6774: old_cost_tab.delete;
6775:

Line 6787: fnd_file.put_line

6783: IF lot_cost_cursor%FOUND
6784: THEN
6785: IF l_debug_level >= l_debug_level_high
6786: THEN
6787: fnd_file.put_line
6788: (fnd_file.log,'Reading existing costs for header ID '||old_cost.header_id);
6789: END IF;
6790:
6791: OPEN lot_cost_detail_cursor (old_cost.header_id);

Line 6788: (fnd_file.log,'Reading existing costs for header ID '||old_cost.header_id);

6784: THEN
6785: IF l_debug_level >= l_debug_level_high
6786: THEN
6787: fnd_file.put_line
6788: (fnd_file.log,'Reading existing costs for header ID '||old_cost.header_id);
6789: END IF;
6790:
6791: OPEN lot_cost_detail_cursor (old_cost.header_id);
6792: FETCH lot_cost_detail_cursor BULK COLLECT INTO old_cost_tab;

Line 6802: fnd_file.put_line

6798: IF old_cost_tab.EXISTS(1)
6799: THEN
6800: IF l_debug_level >= l_debug_level_high
6801: THEN
6802: fnd_file.put_line
6803: (fnd_file.log,'Lot Cost before this transaction is '||to_char(old_cost.unit_cost,'999999999.99'));
6804: END IF;
6805:
6806:

Line 6803: (fnd_file.log,'Lot Cost before this transaction is '||to_char(old_cost.unit_cost,'999999999.99'));

6799: THEN
6800: IF l_debug_level >= l_debug_level_high
6801: THEN
6802: fnd_file.put_line
6803: (fnd_file.log,'Lot Cost before this transaction is '||to_char(old_cost.unit_cost,'999999999.99'));
6804: END IF;
6805:
6806:
6807: -- At this stage we have all the header and cost component information we need

Line 6905: fnd_file.put_line( fnd_file.log,' Previous Cost is NULL');

6901: -- No cost currently exists, create one and all associated details
6902: -- and transactions. Again, this is only for the invoking transaction
6903: IF l_debug_level >= l_debug_level_high
6904: THEN
6905: fnd_file.put_line( fnd_file.log,' Previous Cost is NULL');
6906: END IF;
6907:
6908: create_cost_header
6909: ( transaction_row.inventory_item_id

Line 6937: fnd_file.put_line

6933: CLOSE component_class_cursor;
6934:
6935: IF l_debug_level >= l_debug_level_medium
6936: THEN
6937: fnd_file.put_line
6938: (fnd_file.log,'Creating new cost detail row');
6939: END IF;
6940:
6941: create_cost_detail

Line 6938: (fnd_file.log,'Creating new cost detail row');

6934:
6935: IF l_debug_level >= l_debug_level_medium
6936: THEN
6937: fnd_file.put_line
6938: (fnd_file.log,'Creating new cost detail row');
6939: END IF;
6940:
6941: create_cost_detail
6942: ( new_cost.header_id

Line 6981: fnd_file.put_line (fnd_file.log,' Entering process_wip_batch');

6977:
6978: END IF;
6979: IF l_debug_level >= l_debug_level_medium
6980: THEN
6981: fnd_file.put_line (fnd_file.log,' Entering process_wip_batch');
6982: END IF;
6983:
6984: END process_wip_batch;
6985:

Line 7014: fnd_file.put_line

7010: procedure_name := 'Weighted Average';
7011:
7012: IF l_debug_level >= l_debug_level_medium
7013: THEN
7014: fnd_file.put_line
7015: (fnd_file.log,'Entered Procedure: '||procedure_name);
7016: END IF;
7017:
7018: IF l_debug_level >= l_debug_level_high

Line 7015: (fnd_file.log,'Entered Procedure: '||procedure_name);

7011:
7012: IF l_debug_level >= l_debug_level_medium
7013: THEN
7014: fnd_file.put_line
7015: (fnd_file.log,'Entered Procedure: '||procedure_name);
7016: END IF;
7017:
7018: IF l_debug_level >= l_debug_level_high
7019: THEN

Line 7020: fnd_file.put_line(fnd_file.log,'trans_qty = '||trans_qty);

7016: END IF;
7017:
7018: IF l_debug_level >= l_debug_level_high
7019: THEN
7020: fnd_file.put_line(fnd_file.log,'trans_qty = '||trans_qty);
7021:
7022: fnd_file.put_line(fnd_file.log,'Previous Copy of new_cost_tab is:');
7023:
7024: FOR k IN 1 .. new_cost_tab.COUNT

Line 7022: fnd_file.put_line(fnd_file.log,'Previous Copy of new_cost_tab is:');

7018: IF l_debug_level >= l_debug_level_high
7019: THEN
7020: fnd_file.put_line(fnd_file.log,'trans_qty = '||trans_qty);
7021:
7022: fnd_file.put_line(fnd_file.log,'Previous Copy of new_cost_tab is:');
7023:
7024: FOR k IN 1 .. new_cost_tab.COUNT
7025: LOOP
7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

Line 7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

7022: fnd_file.put_line(fnd_file.log,'Previous Copy of new_cost_tab is:');
7023:
7024: FOR k IN 1 .. new_cost_tab.COUNT
7025: LOOP
7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7027: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7028: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7029: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7030: fnd_file.put_line(fnd_file.log,'====================================');

Line 7027: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

7023:
7024: FOR k IN 1 .. new_cost_tab.COUNT
7025: LOOP
7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7027: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7028: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7029: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7030: fnd_file.put_line(fnd_file.log,'====================================');
7031: END LOOP;

Line 7028: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);

7024: FOR k IN 1 .. new_cost_tab.COUNT
7025: LOOP
7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7027: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7028: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7029: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7030: fnd_file.put_line(fnd_file.log,'====================================');
7031: END LOOP;
7032:

Line 7029: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

7025: LOOP
7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7027: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7028: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7029: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7030: fnd_file.put_line(fnd_file.log,'====================================');
7031: END LOOP;
7032:
7033: IF costs_table.EXISTS(1)

Line 7030: fnd_file.put_line(fnd_file.log,'====================================');

7026: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7027: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7028: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7029: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7030: fnd_file.put_line(fnd_file.log,'====================================');
7031: END LOOP;
7032:
7033: IF costs_table.EXISTS(1)
7034: THEN

Line 7035: fnd_file.put_line(fnd_file.log,'Before Average costs_tab is:');

7031: END LOOP;
7032:
7033: IF costs_table.EXISTS(1)
7034: THEN
7035: fnd_file.put_line(fnd_file.log,'Before Average costs_tab is:');
7036: FOR k IN 1 .. costs_table.COUNT
7037: LOOP
7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

Line 7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);

7034: THEN
7035: fnd_file.put_line(fnd_file.log,'Before Average costs_tab is:');
7036: FOR k IN 1 .. costs_table.COUNT
7037: LOOP
7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7040: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7042: fnd_file.put_line(fnd_file.log,'====================================');

Line 7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

7035: fnd_file.put_line(fnd_file.log,'Before Average costs_tab is:');
7036: FOR k IN 1 .. costs_table.COUNT
7037: LOOP
7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7040: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7042: fnd_file.put_line(fnd_file.log,'====================================');
7043: END LOOP;

Line 7040: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);

7036: FOR k IN 1 .. costs_table.COUNT
7037: LOOP
7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7040: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7042: fnd_file.put_line(fnd_file.log,'====================================');
7043: END LOOP;
7044: ELSE

Line 7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);

7037: LOOP
7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7040: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7042: fnd_file.put_line(fnd_file.log,'====================================');
7043: END LOOP;
7044: ELSE
7045: fnd_file.put_line(fnd_file.log,'No costs to merge');

Line 7042: fnd_file.put_line(fnd_file.log,'====================================');

7038: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7039: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7040: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7042: fnd_file.put_line(fnd_file.log,'====================================');
7043: END LOOP;
7044: ELSE
7045: fnd_file.put_line(fnd_file.log,'No costs to merge');
7046: END IF;

Line 7045: fnd_file.put_line(fnd_file.log,'No costs to merge');

7041: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7042: fnd_file.put_line(fnd_file.log,'====================================');
7043: END LOOP;
7044: ELSE
7045: fnd_file.put_line(fnd_file.log,'No costs to merge');
7046: END IF;
7047: END IF;
7048:
7049: IF costs_table.EXISTS(1)

Line 7058: fnd_file.put_line(fnd_file.log,'Divisor is '||divisor);

7054: THEN
7055: divisor := 1;
7056: END IF;
7057:
7058: fnd_file.put_line(fnd_file.log,'Divisor is '||divisor);
7059:
7060: FOR k in 1 .. costs_table.COUNT
7061: LOOP
7062: costs_table(k).component_cost := costs_table(k).component_cost * trans_qty / divisor;

Line 7067: fnd_file.put_line(fnd_file.log,' new_qty = '||trans_qty);

7063: END LOOP;
7064:
7065: IF l_debug_level >= l_debug_level_high
7066: THEN
7067: fnd_file.put_line(fnd_file.log,' new_qty = '||trans_qty);
7068:
7069: -- fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
7070:
7071: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');

Line 7069: -- fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');

7065: IF l_debug_level >= l_debug_level_high
7066: THEN
7067: fnd_file.put_line(fnd_file.log,' new_qty = '||trans_qty);
7068:
7069: -- fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
7070:
7071: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
7072: FOR k IN 1 .. costs_table.COUNT
7073: LOOP

Line 7071: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');

7067: fnd_file.put_line(fnd_file.log,' new_qty = '||trans_qty);
7068:
7069: -- fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
7070:
7071: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
7072: FOR k IN 1 .. costs_table.COUNT
7073: LOOP
7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

Line 7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);

7070:
7071: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
7072: FOR k IN 1 .. costs_table.COUNT
7073: LOOP
7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7076: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7077: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7078: fnd_file.put_line(fnd_file.log,'====================================');

Line 7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);

7071: fnd_file.put_line(fnd_file.log,'After averaging costs_tab is:');
7072: FOR k IN 1 .. costs_table.COUNT
7073: LOOP
7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7076: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7077: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7078: fnd_file.put_line(fnd_file.log,'====================================');
7079: END LOOP;

Line 7076: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);

7072: FOR k IN 1 .. costs_table.COUNT
7073: LOOP
7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7076: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7077: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7078: fnd_file.put_line(fnd_file.log,'====================================');
7079: END LOOP;
7080: END IF;

Line 7077: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);

7073: LOOP
7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7076: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7077: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7078: fnd_file.put_line(fnd_file.log,'====================================');
7079: END LOOP;
7080: END IF;
7081:

Line 7078: fnd_file.put_line(fnd_file.log,'====================================');

7074: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||costs_table(k).cost_cmpntcls_id);
7075: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||costs_table(k).cost_analysis_code);
7076: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||costs_table(k).cost_level);
7077: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||costs_table(k).component_cost);
7078: fnd_file.put_line(fnd_file.log,'====================================');
7079: END LOOP;
7080: END IF;
7081:
7082: IF (new_cost_tab.COUNT = 0) THEN

Line 7100: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');

7096:
7097:
7098:
7099:
7100: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
7101: FOR k IN 1 .. new_cost_tab.COUNT
7102: LOOP
7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

Line 7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);

7099:
7100: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
7101: FOR k IN 1 .. new_cost_tab.COUNT
7102: LOOP
7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7105: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7106: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7107: fnd_file.put_line(fnd_file.log,'====================================');

Line 7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);

7100: fnd_file.put_line(fnd_file.log,'After averaging new_cost_tab is:');
7101: FOR k IN 1 .. new_cost_tab.COUNT
7102: LOOP
7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7105: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7106: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7107: fnd_file.put_line(fnd_file.log,'====================================');
7108: END LOOP;

Line 7105: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);

7101: FOR k IN 1 .. new_cost_tab.COUNT
7102: LOOP
7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7105: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7106: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7107: fnd_file.put_line(fnd_file.log,'====================================');
7108: END LOOP;
7109: END IF;

Line 7106: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);

7102: LOOP
7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7105: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7106: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7107: fnd_file.put_line(fnd_file.log,'====================================');
7108: END LOOP;
7109: END IF;
7110:

Line 7107: fnd_file.put_line(fnd_file.log,'====================================');

7103: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||new_cost_tab(k).cost_cmpntcls_id);
7104: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||new_cost_tab(k).cost_analysis_code);
7105: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||new_cost_tab(k).cost_level);
7106: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||new_cost_tab(k).component_cost);
7107: fnd_file.put_line(fnd_file.log,'====================================');
7108: END LOOP;
7109: END IF;
7110:
7111: IF l_debug_level >= l_debug_level_medium

Line 7113: fnd_file.put_line

7109: END IF;
7110:
7111: IF l_debug_level >= l_debug_level_medium
7112: THEN
7113: fnd_file.put_line
7114: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7115: END IF;
7116: END;
7117:

Line 7114: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7110:
7111: IF l_debug_level >= l_debug_level_medium
7112: THEN
7113: fnd_file.put_line
7114: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7115: END IF;
7116: END;
7117:
7118:

Line 7148: fnd_file.put_line

7144: BEGIN
7145: procedure_name := 'Get New Cost';
7146: IF l_debug_level >= l_debug_level_medium
7147: THEN
7148: fnd_file.put_line
7149: (fnd_file.log,'Entered Procedure: '||procedure_name);
7150: END IF;
7151:
7152: IF (p_cost_tab.COUNT > 0) THEN

Line 7149: (fnd_file.log,'Entered Procedure: '||procedure_name);

7145: procedure_name := 'Get New Cost';
7146: IF l_debug_level >= l_debug_level_medium
7147: THEN
7148: fnd_file.put_line
7149: (fnd_file.log,'Entered Procedure: '||procedure_name);
7150: END IF;
7151:
7152: IF (p_cost_tab.COUNT > 0) THEN
7153: FOR i IN 1..p_cost_tab.COUNT LOOP

Line 7173: fnd_file.put_line(fnd_file.log,'After weighted average new_cost_tab is:');

7169: FROM TABLE ( CAST(l_cost_table AS SYSTEM.gmf_cost_tab) ) nct;
7170:
7171: IF l_debug_level >= l_debug_level_high
7172: THEN
7173: fnd_file.put_line(fnd_file.log,'After weighted average new_cost_tab is:');
7174: FOR k IN 1 .. new_cost_tab.COUNT
7175: LOOP
7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);
7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);

Line 7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);

7172: THEN
7173: fnd_file.put_line(fnd_file.log,'After weighted average new_cost_tab is:');
7174: FOR k IN 1 .. new_cost_tab.COUNT
7175: LOOP
7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);
7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);
7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);
7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);
7180: fnd_file.put_line(fnd_file.log,'====================================');

Line 7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);

7173: fnd_file.put_line(fnd_file.log,'After weighted average new_cost_tab is:');
7174: FOR k IN 1 .. new_cost_tab.COUNT
7175: LOOP
7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);
7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);
7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);
7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);
7180: fnd_file.put_line(fnd_file.log,'====================================');
7181: END LOOP;

Line 7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);

7174: FOR k IN 1 .. new_cost_tab.COUNT
7175: LOOP
7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);
7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);
7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);
7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);
7180: fnd_file.put_line(fnd_file.log,'====================================');
7181: END LOOP;
7182: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||x_total_cost);

Line 7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);

7175: LOOP
7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);
7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);
7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);
7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);
7180: fnd_file.put_line(fnd_file.log,'====================================');
7181: END LOOP;
7182: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||x_total_cost);
7183: END IF;

Line 7180: fnd_file.put_line(fnd_file.log,'====================================');

7176: fnd_file.put_line(fnd_file.log,'CCC/ID['||k||']: '||x_new_cost_tab(k).cost_cmpntcls_id);
7177: fnd_file.put_line(fnd_file.log,'A/Code['||k||']: '||x_new_cost_tab(k).cost_analysis_code);
7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);
7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);
7180: fnd_file.put_line(fnd_file.log,'====================================');
7181: END LOOP;
7182: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||x_total_cost);
7183: END IF;
7184: IF l_debug_level >= l_debug_level_medium

Line 7182: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||x_total_cost);

7178: fnd_file.put_line(fnd_file.log,'Level['||k||'] : '||x_new_cost_tab(k).cost_level);
7179: fnd_file.put_line(fnd_file.log,'C/Cost['||k||']: '||x_new_cost_tab(k).component_cost);
7180: fnd_file.put_line(fnd_file.log,'====================================');
7181: END LOOP;
7182: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||x_total_cost);
7183: END IF;
7184: IF l_debug_level >= l_debug_level_medium
7185: THEN
7186: fnd_file.put_line

Line 7186: fnd_file.put_line

7182: fnd_file.put_line(fnd_file.log,'After merging, new unit cost is: '||x_total_cost);
7183: END IF;
7184: IF l_debug_level >= l_debug_level_medium
7185: THEN
7186: fnd_file.put_line
7187: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7188: END IF;
7189: END;
7190:

Line 7187: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7183: END IF;
7184: IF l_debug_level >= l_debug_level_medium
7185: THEN
7186: fnd_file.put_line
7187: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7188: END IF;
7189: END;
7190:
7191: /*=========================================================

Line 7229: fnd_file.put_line

7225: BEGIN
7226: procedure_name := 'load Lot Costed Items GT';
7227: IF l_debug_level >= l_debug_level_medium
7228: THEN
7229: fnd_file.put_line
7230: (fnd_file.log,'Entered Procedure: '||procedure_name);
7231: END IF;
7232: IF (p_le_id IS NOT NULL) THEN
7233: -- Always load all organizations. There may be transfers across orgs

Line 7230: (fnd_file.log,'Entered Procedure: '||procedure_name);

7226: procedure_name := 'load Lot Costed Items GT';
7227: IF l_debug_level >= l_debug_level_medium
7228: THEN
7229: fnd_file.put_line
7230: (fnd_file.log,'Entered Procedure: '||procedure_name);
7231: END IF;
7232: IF (p_le_id IS NOT NULL) THEN
7233: -- Always load all organizations. There may be transfers across orgs
7234: /*

Line 7391: fnd_file.put_line

7387: END IF;
7388: x_return_status := 0;
7389: IF l_debug_level >= l_debug_level_medium
7390: THEN
7391: fnd_file.put_line
7392: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7393: END IF;
7394: EXCEPTION
7395: WHEN OTHERS THEN

Line 7392: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7388: x_return_status := 0;
7389: IF l_debug_level >= l_debug_level_medium
7390: THEN
7391: fnd_file.put_line
7392: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7393: END IF;
7394: EXCEPTION
7395: WHEN OTHERS THEN
7396: x_return_status := -1;

Line 7420: fnd_file.put_line

7416: BEGIN
7417: procedure_name := 'Process Lot Split';
7418: IF l_debug_level >= l_debug_level_medium
7419: THEN
7420: fnd_file.put_line
7421: (fnd_file.log,'Entered Procedure: '||procedure_name);
7422: END IF;
7423:
7424: IF (transaction_row.transaction_id = transaction_row.transfer_transaction_id)

Line 7421: (fnd_file.log,'Entered Procedure: '||procedure_name);

7417: procedure_name := 'Process Lot Split';
7418: IF l_debug_level >= l_debug_level_medium
7419: THEN
7420: fnd_file.put_line
7421: (fnd_file.log,'Entered Procedure: '||procedure_name);
7422: END IF;
7423:
7424: IF (transaction_row.transaction_id = transaction_row.transfer_transaction_id)
7425: THEN /* This is a parent lot from which split happened */

Line 7453: fnd_file.put_line

7449: IF lot_cost_cursor%FOUND
7450: THEN
7451: IF l_debug_level >= l_debug_level_high
7452: THEN
7453: fnd_file.put_line
7454: (fnd_file.log,'Reading existing costs for header ID '||l_old_cost.header_id);
7455: END IF;
7456:
7457: OPEN lot_cost_detail_cursor (l_old_cost.header_id);

Line 7454: (fnd_file.log,'Reading existing costs for header ID '||l_old_cost.header_id);

7450: THEN
7451: IF l_debug_level >= l_debug_level_high
7452: THEN
7453: fnd_file.put_line
7454: (fnd_file.log,'Reading existing costs for header ID '||l_old_cost.header_id);
7455: END IF;
7456:
7457: OPEN lot_cost_detail_cursor (l_old_cost.header_id);
7458: FETCH lot_cost_detail_cursor BULK COLLECT INTO l_old_cost_tab;

Line 7513: fnd_file.put_line

7509:
7510:
7511: IF l_debug_level >= l_debug_level_medium
7512: THEN
7513: fnd_file.put_line
7514: (fnd_file.log,'Creating new cost detail row');
7515: END IF;
7516:
7517: FOR i IN 1..new_cost_tab.COUNT

Line 7514: (fnd_file.log,'Creating new cost detail row');

7510:
7511: IF l_debug_level >= l_debug_level_medium
7512: THEN
7513: fnd_file.put_line
7514: (fnd_file.log,'Creating new cost detail row');
7515: END IF;
7516:
7517: FOR i IN 1..new_cost_tab.COUNT
7518: LOOP

Line 7533: fnd_file.put_line

7529: IF l_return_status = 'S'
7530: THEN
7531: IF l_debug_level >= l_debug_level_medium
7532: THEN
7533: fnd_file.put_line
7534: (fnd_file.log,'Creating new material cost transaction');
7535: END IF;
7536: create_material_transaction
7537: ( new_cost.header_id

Line 7534: (fnd_file.log,'Creating new material cost transaction');

7530: THEN
7531: IF l_debug_level >= l_debug_level_medium
7532: THEN
7533: fnd_file.put_line
7534: (fnd_file.log,'Creating new material cost transaction');
7535: END IF;
7536: create_material_transaction
7537: ( new_cost.header_id
7538: ,l_cost_type_id

Line 7557: fnd_file.put_line

7553: END IF;
7554: END IF;
7555: IF l_debug_level >= l_debug_level_medium
7556: THEN
7557: fnd_file.put_line
7558: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7559: END IF;
7560: END;
7561:

Line 7558: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7554: END IF;
7555: IF l_debug_level >= l_debug_level_medium
7556: THEN
7557: fnd_file.put_line
7558: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7559: END IF;
7560: END;
7561:
7562: /* INVCONV sschinch New procedure*/

Line 7596: fnd_file.put_line

7592: BEGIN
7593: procedure_name := 'Process Merged Lot';
7594: IF l_debug_level >= l_debug_level_medium
7595: THEN
7596: fnd_file.put_line
7597: (fnd_file.log,'Entered Procedure: '||procedure_name);
7598: END IF;
7599:
7600: IF (transaction_row.transaction_id = transaction_row.transfer_transaction_id)

Line 7597: (fnd_file.log,'Entered Procedure: '||procedure_name);

7593: procedure_name := 'Process Merged Lot';
7594: IF l_debug_level >= l_debug_level_medium
7595: THEN
7596: fnd_file.put_line
7597: (fnd_file.log,'Entered Procedure: '||procedure_name);
7598: END IF;
7599:
7600: IF (transaction_row.transaction_id = transaction_row.transfer_transaction_id)
7601: THEN

Line 7626: fnd_file.put_line

7622: child_lot_row.trans_qty,
7623: transaction_row.trans_qty
7624: );
7625: ELSE
7626: fnd_file.put_line
7627: (fnd_File.LOG,'PROCEDURE Process_Lot_Merge '||'Warning : Child Lot :'||child_lot_row.lot_number||' has no cost will be using 0 cost ');
7628: END IF;
7629:
7630: CLOSE lot_cost_cursor;

Line 7627: (fnd_File.LOG,'PROCEDURE Process_Lot_Merge '||'Warning : Child Lot :'||child_lot_row.lot_number||' has no cost will be using 0 cost ');

7623: transaction_row.trans_qty
7624: );
7625: ELSE
7626: fnd_file.put_line
7627: (fnd_File.LOG,'PROCEDURE Process_Lot_Merge '||'Warning : Child Lot :'||child_lot_row.lot_number||' has no cost will be using 0 cost ');
7628: END IF;
7629:
7630: CLOSE lot_cost_cursor;
7631: FETCH child_lots_cursor INTO child_lot_row;

Line 7676: fnd_file.put_line

7672: IF l_return_status = 'S'
7673: THEN
7674: IF l_debug_level >= l_debug_level_medium
7675: THEN
7676: fnd_file.put_line
7677: (fnd_file.log,'Creating cost detail rows');
7678: END IF;
7679:
7680: FOR i in 1 .. new_cost_tab.COUNT

Line 7677: (fnd_file.log,'Creating cost detail rows');

7673: THEN
7674: IF l_debug_level >= l_debug_level_medium
7675: THEN
7676: fnd_file.put_line
7677: (fnd_file.log,'Creating cost detail rows');
7678: END IF;
7679:
7680: FOR i in 1 .. new_cost_tab.COUNT
7681: LOOP

Line 7701: fnd_file.put_line

7697:
7698:
7699: IF l_debug_level >= l_debug_level_medium
7700: THEN
7701: fnd_file.put_line
7702: (fnd_file.log,'Procedure : '||procedure_name||' Creating cost transaction');
7703: END IF;
7704:
7705: create_material_transaction

Line 7702: (fnd_file.log,'Procedure : '||procedure_name||' Creating cost transaction');

7698:
7699: IF l_debug_level >= l_debug_level_medium
7700: THEN
7701: fnd_file.put_line
7702: (fnd_file.log,'Procedure : '||procedure_name||' Creating cost transaction');
7703: END IF;
7704:
7705: create_material_transaction
7706: ( new_cost.header_id

Line 7729: fnd_file.put_line

7725: process_adjustment;
7726: END IF;
7727: IF l_debug_level >= l_debug_level_medium
7728: THEN
7729: fnd_file.put_line
7730: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7731: END IF;
7732:
7733: END process_lot_merge;

Line 7730: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7726: END IF;
7727: IF l_debug_level >= l_debug_level_medium
7728: THEN
7729: fnd_file.put_line
7730: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7731: END IF;
7732:
7733: END process_lot_merge;
7734: /*=========================================================

Line 7754: fnd_file.put_line

7750: BEGIN
7751: procedure_name := 'Process Lot Translate';
7752: IF l_debug_level >= l_debug_level_medium
7753: THEN
7754: fnd_file.put_line
7755: (fnd_file.log,'Entered Procedure: '||procedure_name);
7756: END IF;
7757:
7758: IF (transaction_row.transaction_id = transaction_row.transfer_transaction_id) THEN

Line 7755: (fnd_file.log,'Entered Procedure: '||procedure_name);

7751: procedure_name := 'Process Lot Translate';
7752: IF l_debug_level >= l_debug_level_medium
7753: THEN
7754: fnd_file.put_line
7755: (fnd_file.log,'Entered Procedure: '||procedure_name);
7756: END IF;
7757:
7758: IF (transaction_row.transaction_id = transaction_row.transfer_transaction_id) THEN
7759: process_adjustment;

Line 7873: fnd_file.put_line

7869: END IF;
7870: END IF;
7871: IF l_debug_level >= l_debug_level_medium
7872: THEN
7873: fnd_file.put_line
7874: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7875: END IF;
7876: END process_lot_translate;
7877:

Line 7874: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7870: END IF;
7871: IF l_debug_level >= l_debug_level_medium
7872: THEN
7873: fnd_file.put_line
7874: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7875: END IF;
7876: END process_lot_translate;
7877:
7878:

Line 7897: fnd_file.put_line

7893: procedure_name := 'Process Consigned Inventory';
7894:
7895: IF l_debug_level >= l_debug_level_medium
7896: THEN
7897: fnd_file.put_line
7898: (fnd_file.log,'Entered Procedure: '||procedure_name);
7899: END IF;
7900:
7901: OPEN component_class_cursor

Line 7898: (fnd_file.log,'Entered Procedure: '||procedure_name);

7894:
7895: IF l_debug_level >= l_debug_level_medium
7896: THEN
7897: fnd_file.put_line
7898: (fnd_file.log,'Entered Procedure: '||procedure_name);
7899: END IF;
7900:
7901: OPEN component_class_cursor
7902: ( l_le_id

Line 7982: fnd_file.put_line

7978: END IF;
7979:
7980: IF l_debug_level >= l_debug_level_medium
7981: THEN
7982: fnd_file.put_line
7983: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7984: END IF;
7985: END;
7986:

Line 7983: (fnd_file.log,'Leaving Procedure: '||procedure_name);

7979:
7980: IF l_debug_level >= l_debug_level_medium
7981: THEN
7982: fnd_file.put_line
7983: (fnd_file.log,'Leaving Procedure: '||procedure_name);
7984: END IF;
7985: END;
7986:
7987: /*=========================================================

Line 8027: fnd_file.put_line

8023:
8024: procedure_name := 'process_pdtxf_cost';
8025: IF l_debug_level >= l_debug_level_medium
8026: THEN
8027: fnd_file.put_line
8028: (fnd_file.log,'Entered Procedure: '||procedure_name);
8029: END IF;
8030: OPEN component_class_cursor(l_le_id,
8031: transaction_row.inventory_item_id,

Line 8028: (fnd_file.log,'Entered Procedure: '||procedure_name);

8024: procedure_name := 'process_pdtxf_cost';
8025: IF l_debug_level >= l_debug_level_medium
8026: THEN
8027: fnd_file.put_line
8028: (fnd_file.log,'Entered Procedure: '||procedure_name);
8029: END IF;
8030: OPEN component_class_cursor(l_le_id,
8031: transaction_row.inventory_item_id,
8032: transaction_row.orgn_id,

Line 8041: fnd_file.put_line

8037: IF(transaction_row.trans_qty <> 0) THEN
8038: l_new_cost := transaction_row.transfer_price;
8039: l_trp_cost := transaction_row.transportation_cost/transaction_row.trans_qty;
8040: ELSE
8041: fnd_file.put_line
8042: (fnd_file.log,'ERROR Procedure : '||procedure_name||' Transaction qty is zero.Cannot proceed');
8043: l_return_status := 'E';
8044: RETURN;
8045: END IF;

Line 8042: (fnd_file.log,'ERROR Procedure : '||procedure_name||' Transaction qty is zero.Cannot proceed');

8038: l_new_cost := transaction_row.transfer_price;
8039: l_trp_cost := transaction_row.transportation_cost/transaction_row.trans_qty;
8040: ELSE
8041: fnd_file.put_line
8042: (fnd_file.log,'ERROR Procedure : '||procedure_name||' Transaction qty is zero.Cannot proceed');
8043: l_return_status := 'E';
8044: RETURN;
8045: END IF;
8046:

Line 8053: fnd_file.put_line

8049: l_cost_tab(1) := SYSTEM.gmf_cost_type(l_ccc_id,l_a_code,0,l_new_cost,0);
8050: ELSE
8051: l_return_status := 'E';
8052: -- PK added this message as above
8053: fnd_file.put_line
8054: (fnd_file.log,'ERROR Procedure : '||procedure_name||' l_ccc_id has value NULL. Cannot proceed');
8055:
8056: RETURN;
8057: END IF;

Line 8054: (fnd_file.log,'ERROR Procedure : '||procedure_name||' l_ccc_id has value NULL. Cannot proceed');

8050: ELSE
8051: l_return_status := 'E';
8052: -- PK added this message as above
8053: fnd_file.put_line
8054: (fnd_file.log,'ERROR Procedure : '||procedure_name||' l_ccc_id has value NULL. Cannot proceed');
8055:
8056: RETURN;
8057: END IF;
8058:

Line 8065: fnd_file.put_line (fnd_file.log,'Procedure : '||procedure_name||' Overhead default component/analysis code in fiscal policies table is not defined. Ignoring the transportation cost');

8061: FETCH cur_get_default_cmpt INTO l_cmpntcls_id,l_cost_analysis_code,l_cost_level,l_component_cost,l_burden_ind;
8062: CLOSE cur_get_default_cmpt;
8063:
8064: IF(l_cmpntcls_id IS NULL OR l_cost_analysis_code IS NULL) THEN
8065: fnd_file.put_line (fnd_file.log,'Procedure : '||procedure_name||' Overhead default component/analysis code in fiscal policies table is not defined. Ignoring the transportation cost');
8066: ELSE
8067: l_cost_tab(2) := SYSTEM.gmf_cost_type(l_cmpntcls_id,l_cost_analysis_code,l_cost_level,l_component_cost,l_burden_ind);
8068: END IF;
8069: END IF;

Line 8092: fnd_file.put_line

8088: l_onhand_qty := transaction_row.trans_qty;
8089: new_cost_tab(1) := SYSTEM.gmf_cost_type(l_ccc_id,l_a_code,0,l_new_cost,0);
8090: ELSE
8091: l_return_status := 'E';
8092: fnd_file.put_line
8093: (fnd_file.log,'ERROR Procedure : '||procedure_name||' loc2 l_ccc_id has value NULL. Cannot proceed');
8094: RETURN;
8095: END IF;
8096: END IF;

Line 8093: (fnd_file.log,'ERROR Procedure : '||procedure_name||' loc2 l_ccc_id has value NULL. Cannot proceed');

8089: new_cost_tab(1) := SYSTEM.gmf_cost_type(l_ccc_id,l_a_code,0,l_new_cost,0);
8090: ELSE
8091: l_return_status := 'E';
8092: fnd_file.put_line
8093: (fnd_file.log,'ERROR Procedure : '||procedure_name||' loc2 l_ccc_id has value NULL. Cannot proceed');
8094: RETURN;
8095: END IF;
8096: END IF;
8097:

Line 8155: fnd_file.put_line

8151: END LOOP;
8152:
8153: IF l_debug_level >= l_debug_level_medium
8154: THEN
8155: fnd_file.put_line
8156: (fnd_file.log,'Procedure : '||procedure_name||' Creating cost transaction');
8157: END IF;
8158:
8159: create_material_transaction

Line 8156: (fnd_file.log,'Procedure : '||procedure_name||' Creating cost transaction');

8152:
8153: IF l_debug_level >= l_debug_level_medium
8154: THEN
8155: fnd_file.put_line
8156: (fnd_file.log,'Procedure : '||procedure_name||' Creating cost transaction');
8157: END IF;
8158:
8159: create_material_transaction
8160: ( new_cost.header_id

Line 8178: fnd_file.put_line

8174: );
8175: END IF;
8176: IF l_debug_level >= l_debug_level_medium
8177: THEN
8178: fnd_file.put_line
8179: (fnd_file.log,'Leaving Procedure: '||procedure_name);
8180: END IF;
8181: END;
8182:

Line 8179: (fnd_file.log,'Leaving Procedure: '||procedure_name);

8175: END IF;
8176: IF l_debug_level >= l_debug_level_medium
8177: THEN
8178: fnd_file.put_line
8179: (fnd_file.log,'Leaving Procedure: '||procedure_name);
8180: END IF;
8181: END;
8182:
8183:

Line 8203: fnd_file.put_line

8199: BEGIN
8200: procedure_name := 'Process Pd Transfer';
8201: IF l_debug_level >= l_debug_level_medium
8202: THEN
8203: fnd_file.put_line
8204: (fnd_file.log,'Entered Procedure: '||procedure_name);
8205: END IF;
8206:
8207: IF new_cost_tab.EXISTS(1)

Line 8204: (fnd_file.log,'Entered Procedure: '||procedure_name);

8200: procedure_name := 'Process Pd Transfer';
8201: IF l_debug_level >= l_debug_level_medium
8202: THEN
8203: fnd_file.put_line
8204: (fnd_file.log,'Entered Procedure: '||procedure_name);
8205: END IF;
8206:
8207: IF new_cost_tab.EXISTS(1)
8208: THEN

Line 8270: fnd_file.put_line

8266: );
8267: END IF;
8268: IF l_debug_level >= l_debug_level_medium
8269: THEN
8270: fnd_file.put_line
8271: (fnd_file.log,'Leaving Procedure: '||procedure_name);
8272: END IF;
8273: EXCEPTION
8274: WHEN OTHERS THEN

Line 8271: (fnd_file.log,'Leaving Procedure: '||procedure_name);

8267: END IF;
8268: IF l_debug_level >= l_debug_level_medium
8269: THEN
8270: fnd_file.put_line
8271: (fnd_file.log,'Leaving Procedure: '||procedure_name);
8272: END IF;
8273: EXCEPTION
8274: WHEN OTHERS THEN
8275: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);

Line 8275: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);

8271: (fnd_file.log,'Leaving Procedure: '||procedure_name);
8272: END IF;
8273: EXCEPTION
8274: WHEN OTHERS THEN
8275: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);
8276: l_return_status := 'E';
8277: END;
8278:
8279:

Line 8406: --FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/appslog/opm_top/utl/opmm0dv/log');

8402: procedure_name := 'Rollup Lot Costs';
8403:
8404:
8405: /* uncomment the call below to write to a local file */
8406: --FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/appslog/opm_top/utl/opmm0dv/log');
8407: -- FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/slot05/oracle/opml0mtddb/9.2.0/temp');
8408:
8409: fnd_file.put_line
8410: (fnd_File.LOG,'Lot Cost Rollup v 0.1 started on '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));

Line 8407: -- FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/slot05/oracle/opml0mtddb/9.2.0/temp');

8403:
8404:
8405: /* uncomment the call below to write to a local file */
8406: --FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/appslog/opm_top/utl/opmm0dv/log');
8407: -- FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/slot05/oracle/opml0mtddb/9.2.0/temp');
8408:
8409: fnd_file.put_line
8410: (fnd_File.LOG,'Lot Cost Rollup v 0.1 started on '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));
8411:

Line 8409: fnd_file.put_line

8405: /* uncomment the call below to write to a local file */
8406: --FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/appslog/opm_top/utl/opmm0dv/log');
8407: -- FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/slot05/oracle/opml0mtddb/9.2.0/temp');
8408:
8409: fnd_file.put_line
8410: (fnd_File.LOG,'Lot Cost Rollup v 0.1 started on '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));
8411:
8412: -- l_calendar_code := p_calendar_code; umoogala - replaced with co_code
8413: --l_co_code := p_co_code;

Line 8410: (fnd_File.LOG,'Lot Cost Rollup v 0.1 started on '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));

8406: --FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/appslog/opm_top/utl/opmm0dv/log');
8407: -- FND_FILE.PUT_NAMES('gmfplcrb.log','gmfplcrb.out','/slot05/oracle/opml0mtddb/9.2.0/temp');
8408:
8409: fnd_file.put_line
8410: (fnd_File.LOG,'Lot Cost Rollup v 0.1 started on '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));
8411:
8412: -- l_calendar_code := p_calendar_code; umoogala - replaced with co_code
8413: --l_co_code := p_co_code;
8414: l_le_id := p_le_id;

Line 8478: fnd_file.put_line(fnd_file.log,'Parameters for this run are:');

8474:
8475: /******** Bug 4038722 - Dinesh Vadivel - End**********/
8476:
8477:
8478: fnd_file.put_line(fnd_file.log,'Parameters for this run are:');
8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);
8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);

Line 8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);

8475: /******** Bug 4038722 - Dinesh Vadivel - End**********/
8476:
8477:
8478: fnd_file.put_line(fnd_file.log,'Parameters for this run are:');
8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);
8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);

Line 8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);

8476:
8477:
8478: fnd_file.put_line(fnd_file.log,'Parameters for this run are:');
8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);
8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);

Line 8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);

8477:
8478: fnd_file.put_line(fnd_file.log,'Parameters for this run are:');
8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);
8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);

Line 8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);

8478: fnd_file.put_line(fnd_file.log,'Parameters for this run are:');
8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);
8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);

Line 8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);

8479: fnd_file.put_line(fnd_file.log,'Legal Entity Id = '||p_le_id);
8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);

Line 8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);

8480: fnd_file.put_line(fnd_file.log,'Cost Type = '||l_cost_mthd_code);
8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);

Line 8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);

8481: fnd_file.put_line(fnd_file.log,'Default Cost Type = '||l_default_cost_mthd);
8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));

Line 8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);

8482: fnd_file.put_line(fnd_file.log,'Rate Type Code = '||l_rate_type_code);
8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);

Line 8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);

8483: fnd_file.put_line(fnd_file.log,'Base Currency Code = '||l_base_ccy_code);
8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));

Line 8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);

8484: fnd_file.put_line(fnd_file.log,'trans start date = '||l_trans_start_date);
8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));
8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);

Line 8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));

8485: fnd_file.put_line(fnd_file.log,'Item Category Id = '||p_category_id);
8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));
8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);
8493: fnd_file.put_line(fnd_file.log,'Cost Alloc Factor Profile = '|| l_cost_alloc_profile);

Line 8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);

8486: fnd_file.put_line(fnd_file.log,'Item Id = '||p_item_id);
8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));
8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);
8493: fnd_file.put_line(fnd_file.log,'Cost Alloc Factor Profile = '|| l_cost_alloc_profile);
8494:

Line 8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));

8487: fnd_file.put_line(fnd_file.log,'Lot Number = '||p_lot_no);
8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));
8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);
8493: fnd_file.put_line(fnd_file.log,'Cost Alloc Factor Profile = '|| l_cost_alloc_profile);
8494:
8495: -- BUG 3476427

Line 8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);

8488: --fnd_file.put_line(fnd_file.log,'Sub-Lot Number = '||p_sublot_no);
8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));
8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);
8493: fnd_file.put_line(fnd_file.log,'Cost Alloc Factor Profile = '|| l_cost_alloc_profile);
8494:
8495: -- BUG 3476427
8496: -- If this is a final run, and the user has entered limiting parameters then

Line 8493: fnd_file.put_line(fnd_file.log,'Cost Alloc Factor Profile = '|| l_cost_alloc_profile);

8489: fnd_file.put_line(fnd_file.log,'Debug Level = '||to_char(l_debug_level));
8490: fnd_file.put_line(fnd_file.log,'User = '||l_user);
8491: fnd_file.put_line(fnd_file.log,'Final Date = '||to_char(l_final_run_date,'DD-MON-YYYY HH24:MI:SS'));
8492: fnd_file.put_line(fnd_file.log,'Final Run? = '|| p_final_run_flag);
8493: fnd_file.put_line(fnd_file.log,'Cost Alloc Factor Profile = '|| l_cost_alloc_profile);
8494:
8495: -- BUG 3476427
8496: -- If this is a final run, and the user has entered limiting parameters then
8497: -- let them know that they will be ignored.

Line 8507: fnd_file.put_line

8503: OR p_lot_no IS NOT NULL
8504: OR p_orgn_id IS NOT NULL
8505: )
8506: THEN
8507: fnd_file.put_line
8508: ( fnd_file.log, 'WARNING : Rollup submitted in final mode, limiting parameters will be ignored');
8509:
8510: l_cost_category_id := NULL;
8511: l_item_id := NULL;

Line 8508: ( fnd_file.log, 'WARNING : Rollup submitted in final mode, limiting parameters will be ignored');

8504: OR p_orgn_id IS NOT NULL
8505: )
8506: THEN
8507: fnd_file.put_line
8508: ( fnd_file.log, 'WARNING : Rollup submitted in final mode, limiting parameters will be ignored');
8509:
8510: l_cost_category_id := NULL;
8511: l_item_id := NULL;
8512: l_lot_no := NULL;

Line 8518: fnd_file.put_line

8514: l_tmp := FALSE;
8515: ELSE
8516: IF p_item_id IS NOT NULL AND p_category_id IS NOT NULL
8517: THEN
8518: fnd_file.put_line
8519: ( fnd_file.log, 'WARNING : Cost Category and item have both been specified, item will be used');
8520: l_cost_category_id := NULL;
8521: l_tmp := FALSE;
8522: END IF;

Line 8519: ( fnd_file.log, 'WARNING : Cost Category and item have both been specified, item will be used');

8515: ELSE
8516: IF p_item_id IS NOT NULL AND p_category_id IS NOT NULL
8517: THEN
8518: fnd_file.put_line
8519: ( fnd_file.log, 'WARNING : Cost Category and item have both been specified, item will be used');
8520: l_cost_category_id := NULL;
8521: l_tmp := FALSE;
8522: END IF;
8523: END IF;

Line 8582: fnd_file.put_line

8578: END IF;
8579:
8580: -- PK Bug 6822310 always make l_orgn_id as NULL.
8581: IF l_final_run_flag = 0 AND p_orgn_id IS NOT NULL THEN
8582: fnd_file.put_line
8583: ( fnd_file.log, 'WARNING : Lot cost process should consider all lot transactions. Setting l_orgn_id to NULL');
8584: l_orgn_id := NULL;
8585: END IF;
8586:

Line 8583: ( fnd_file.log, 'WARNING : Lot cost process should consider all lot transactions. Setting l_orgn_id to NULL');

8579:
8580: -- PK Bug 6822310 always make l_orgn_id as NULL.
8581: IF l_final_run_flag = 0 AND p_orgn_id IS NOT NULL THEN
8582: fnd_file.put_line
8583: ( fnd_file.log, 'WARNING : Lot cost process should consider all lot transactions. Setting l_orgn_id to NULL');
8584: l_orgn_id := NULL;
8585: END IF;
8586:
8587: /* INVCONV sschinch Load Lot costed items and process organizations */

Line 8595: fnd_file.put_line

8591: p_category_id => l_cost_category_id,
8592: x_return_status => x_return_status
8593: );
8594: IF (x_return_status <> 0) THEN
8595: fnd_file.put_line
8596: (fnd_file.log,'ERROR Procedure : '||procedure_name||' Load_Lot_Costed_Items_gt returned error. Cannot proceed');
8597: l_return_status := 'E';
8598: RETURN;
8599: END IF;

Line 8596: (fnd_file.log,'ERROR Procedure : '||procedure_name||' Load_Lot_Costed_Items_gt returned error. Cannot proceed');

8592: x_return_status => x_return_status
8593: );
8594: IF (x_return_status <> 0) THEN
8595: fnd_file.put_line
8596: (fnd_file.log,'ERROR Procedure : '||procedure_name||' Load_Lot_Costed_Items_gt returned error. Cannot proceed');
8597: l_return_status := 'E';
8598: RETURN;
8599: END IF;
8600:

Line 8611: fnd_file.put_line(fnd_File.LOG, 'Removing rows of previous trial run.');

8607:
8608:
8609: -- umoogala 05-Dec-2003
8610: -- remove rows from previous trial run.
8611: fnd_file.put_line(fnd_File.LOG, 'Removing rows of previous trial run.');
8612: delete_lot_costs;
8613:
8614: fnd_file.put_line(fnd_File.LOG,'Reading uncosted transactions');
8615:

Line 8614: fnd_file.put_line(fnd_File.LOG,'Reading uncosted transactions');

8610: -- remove rows from previous trial run.
8611: fnd_file.put_line(fnd_File.LOG, 'Removing rows of previous trial run.');
8612: delete_lot_costs;
8613:
8614: fnd_file.put_line(fnd_File.LOG,'Reading uncosted transactions');
8615:
8616:
8617: -- Cursors to retrieve all transactions for items that are costed by lot
8618: -- that have not yet been processed. The above type is used to store the

Line 8910: fnd_file.put_line

8906: IF l_acqui_cost_tab.exists(1) THEN l_acqui_cost_tab.delete; END IF;
8907:
8908: IF l_debug_level >= l_debug_level_high
8909: THEN
8910: fnd_file.put_line
8911: (fnd_file.log,'Inside inv_tran_cursor, inventory_item_id = ' || transaction_row.inventory_item_id ||
8912: ' lot_number = '||transaction_row.lot_number ||
8913: ' orgn = '||l_org_tab(transaction_row.orgn_id) ||
8914: ' transaction_id = '||to_char(transaction_row.transaction_id) ||

Line 8911: (fnd_file.log,'Inside inv_tran_cursor, inventory_item_id = ' || transaction_row.inventory_item_id ||

8907:
8908: IF l_debug_level >= l_debug_level_high
8909: THEN
8910: fnd_file.put_line
8911: (fnd_file.log,'Inside inv_tran_cursor, inventory_item_id = ' || transaction_row.inventory_item_id ||
8912: ' lot_number = '||transaction_row.lot_number ||
8913: ' orgn = '||l_org_tab(transaction_row.orgn_id) ||
8914: ' transaction_id = '||to_char(transaction_row.transaction_id) ||
8915: ' reverse_id = '||to_char(transaction_row.reverse_id) ||

Line 8924: fnd_file.put_line

8920: ' ' || transaction_row.trans_um ||
8921: ' source = ' || transaction_row.source ||
8922: ' transfer orgn id = ' || transaction_row.transfer_orgn_id ||
8923: ' line id = ' || transaction_row.line_id);
8924: fnd_file.put_line
8925: (fnd_File.LOG,'Loading existing cost for lot_id '||to_char(transaction_row.lot_number)||' in organization '
8926: ||l_org_tab(transaction_row.orgn_id));
8927: END IF;
8928:

Line 8925: (fnd_File.LOG,'Loading existing cost for lot_id '||to_char(transaction_row.lot_number)||' in organization '

8921: ' source = ' || transaction_row.source ||
8922: ' transfer orgn id = ' || transaction_row.transfer_orgn_id ||
8923: ' line id = ' || transaction_row.line_id);
8924: fnd_file.put_line
8925: (fnd_File.LOG,'Loading existing cost for lot_id '||to_char(transaction_row.lot_number)||' in organization '
8926: ||l_org_tab(transaction_row.orgn_id));
8927: END IF;
8928:
8929: -- Bug 4130869 Added Date field as NULL.. Because, the Date field has no significance here.

Line 8948: fnd_file.put_line

8944: IF lot_cost_cursor%FOUND
8945: THEN
8946: IF l_debug_level >= l_debug_level_high
8947: THEN
8948: fnd_file.put_line
8949: (fnd_file.log,'Reading existing costs for header ID '||old_cost.header_id);
8950: END IF;
8951:
8952: OPEN lot_cost_detail_cursor (old_cost.header_id);

Line 8949: (fnd_file.log,'Reading existing costs for header ID '||old_cost.header_id);

8945: THEN
8946: IF l_debug_level >= l_debug_level_high
8947: THEN
8948: fnd_file.put_line
8949: (fnd_file.log,'Reading existing costs for header ID '||old_cost.header_id);
8950: END IF;
8951:
8952: OPEN lot_cost_detail_cursor (old_cost.header_id);
8953: FETCH lot_cost_detail_cursor BULK COLLECT INTO old_cost_tab;

Line 8965: fnd_file.put_line

8961: IF old_cost_tab.EXISTS(1)
8962: THEN
8963: IF l_debug_level >= l_debug_level_high
8964: THEN
8965: fnd_file.put_line
8966: (fnd_file.log,'Lot Cost before this transaction is '||to_char(old_cost.unit_cost,'999999999.99'));
8967: END IF;
8968: ELSE
8969: /* Bug 4227784 - This has to be moved up. We can have a case, where we have header

Line 8966: (fnd_file.log,'Lot Cost before this transaction is '||to_char(old_cost.unit_cost,'999999999.99'));

8962: THEN
8963: IF l_debug_level >= l_debug_level_high
8964: THEN
8965: fnd_file.put_line
8966: (fnd_file.log,'Lot Cost before this transaction is '||to_char(old_cost.unit_cost,'999999999.99'));
8967: END IF;
8968: ELSE
8969: /* Bug 4227784 - This has to be moved up. We can have a case, where we have header
8970: but not details. So old_cost_tab can be null, even though old_cost has some record.

Line 8975: fnd_file.put_line(fnd_file.log,'Previous cost was NULL');

8971: In that case, we should not initialize onhand_qty to zero*/
8972: -- old_cost.onhand_qty := 0;
8973: IF l_debug_level >= l_debug_level_high
8974: THEN
8975: fnd_file.put_line(fnd_file.log,'Previous cost was NULL');
8976: END IF;
8977: END IF;
8978:
8979: IF l_debug_level >= l_debug_level_high

Line 8981: fnd_file.put_line(fnd_file.log,' Checking if the Current Lot '||transaction_row.lot_number||' is Costable ?');

8977: END IF;
8978:
8979: IF l_debug_level >= l_debug_level_high
8980: THEN
8981: fnd_file.put_line(fnd_file.log,' Checking if the Current Lot '||transaction_row.lot_number||' is Costable ?');
8982:
8983: END IF;
8984:
8985: /*IF NOT l_uncostable_lots_tab.EXISTS(transaction_row.lot_id)*/

Line 8991: fnd_file.put_line(fnd_file.log,' Yes. Current Lot '||transaction_row.lot_number||' is Costable.');

8987: IF NOT l_uncostable_lots_tab.EXISTS(transaction_row.orgn_id||'-'||transaction_row.inventory_item_id||'-'||transaction_row.lot_number)
8988: THEN
8989: IF l_debug_level >= l_debug_level_high
8990: THEN
8991: fnd_file.put_line(fnd_file.log,' Yes. Current Lot '||transaction_row.lot_number||' is Costable.');
8992: END IF;
8993:
8994: --
8995: -- umoogala: replaced CASE stmt with IF..ELSE..END IF

Line 9013: fnd_file.put_line(fnd_file.log,' 3');

9009:
9010: IF old_cost.onhand_qty < 0
9011: AND l_residual_qty <= 0
9012: THEN
9013: fnd_file.put_line(fnd_file.log,' 3');
9014: IF l_debug_level >= l_debug_level_high
9015: THEN
9016: fnd_file.put_line
9017: (fnd_file.log,'Onhand balance is currently -ve and will remain -ve. Processing txn as an ADJI');

Line 9016: fnd_file.put_line

9012: THEN
9013: fnd_file.put_line(fnd_file.log,' 3');
9014: IF l_debug_level >= l_debug_level_high
9015: THEN
9016: fnd_file.put_line
9017: (fnd_file.log,'Onhand balance is currently -ve and will remain -ve. Processing txn as an ADJI');
9018: END IF;
9019:
9020: process_adjustment;

Line 9017: (fnd_file.log,'Onhand balance is currently -ve and will remain -ve. Processing txn as an ADJI');

9013: fnd_file.put_line(fnd_file.log,' 3');
9014: IF l_debug_level >= l_debug_level_high
9015: THEN
9016: fnd_file.put_line
9017: (fnd_file.log,'Onhand balance is currently -ve and will remain -ve. Processing txn as an ADJI');
9018: END IF;
9019:
9020: process_adjustment;
9021:

Line 9029: fnd_file.put_line

9025: THEN
9026:
9027: IF l_debug_level >= l_debug_level_high
9028: THEN
9029: fnd_file.put_line
9030: (fnd_file.log,'Onhand balance is currently -ve and will go +ve. Clearing old balance to zero');
9031: END IF;
9032:
9033: old_cost.onhand_qty := 0;

Line 9030: (fnd_file.log,'Onhand balance is currently -ve and will go +ve. Clearing old balance to zero');

9026:
9027: IF l_debug_level >= l_debug_level_high
9028: THEN
9029: fnd_file.put_line
9030: (fnd_file.log,'Onhand balance is currently -ve and will go +ve. Clearing old balance to zero');
9031: END IF;
9032:
9033: old_cost.onhand_qty := 0;
9034: ELSE

Line 9037: fnd_file.put_line

9033: old_cost.onhand_qty := 0;
9034: ELSE
9035: IF l_debug_level >= l_debug_level_high
9036: THEN
9037: fnd_file.put_line
9038: (fnd_file.log,'Onhand balance is currently +ve. Processing normally');
9039: END IF;
9040:
9041: l_residual_qty := transaction_row.trans_qty;

Line 9038: (fnd_file.log,'Onhand balance is currently +ve. Processing normally');

9034: ELSE
9035: IF l_debug_level >= l_debug_level_high
9036: THEN
9037: fnd_file.put_line
9038: (fnd_file.log,'Onhand balance is currently +ve. Processing normally');
9039: END IF;
9040:
9041: l_residual_qty := transaction_row.trans_qty;
9042: END IF;

Line 9111: fnd_file.put_line(fnd_file.log,' The Current Batch status is not 3 or 4 ');

9107: process_batch;
9108: ELSE /* The Status as on Final Date is not completed. So copy the previous cost for this record or 0$ */
9109: IF l_debug_level >= l_debug_level_high
9110: THEN
9111: fnd_file.put_line(fnd_file.log,' The Current Batch status is not 3 or 4 ');
9112: END IF;
9113: process_wip_batch;
9114: END IF;
9115:

Line 9243: fnd_file.put_line

9239: -- so we need to adjust the onhand balance in the header to the residual balance
9240:
9241: IF l_debug_level >= l_debug_level_high
9242: THEN
9243: fnd_file.put_line
9244: (fnd_file.log,'Onhand balance has flipped from -ve to +ve. Setting onhand qty to residual qty');
9245: END IF;
9246:
9247: UPDATE gmf_lot_costs

Line 9244: (fnd_file.log,'Onhand balance has flipped from -ve to +ve. Setting onhand qty to residual qty');

9240:
9241: IF l_debug_level >= l_debug_level_high
9242: THEN
9243: fnd_file.put_line
9244: (fnd_file.log,'Onhand balance has flipped from -ve to +ve. Setting onhand qty to residual qty');
9245: END IF;
9246:
9247: UPDATE gmf_lot_costs
9248: SET onhand_qty = l_residual_qty

Line 9301: fnd_file.put_line

9297: -- This is a lot cost adjustment (source is 3)
9298: -- This is a lot cost adjustment (source is 3)
9299: -- PK Bug 6697946 If old_cost.header_id is NULL Use new_cost.header_id
9300: IF l_debug_level >= l_debug_level_high THEN
9301: fnd_file.put_line
9302: (fnd_file.log,'FINAL Mode old '||old_cost.header_id||' new '||new_cost.header_id||' Onhand '||new_cost.onhand_qty||' adj '||transaction_row.doc_id);
9303: END IF;
9304: UPDATE gmf_lot_cost_adjustments
9305: SET applied_ind = 'Y',

Line 9302: (fnd_file.log,'FINAL Mode old '||old_cost.header_id||' new '||new_cost.header_id||' Onhand '||new_cost.onhand_qty||' adj '||transaction_row.doc_id);

9298: -- This is a lot cost adjustment (source is 3)
9299: -- PK Bug 6697946 If old_cost.header_id is NULL Use new_cost.header_id
9300: IF l_debug_level >= l_debug_level_high THEN
9301: fnd_file.put_line
9302: (fnd_file.log,'FINAL Mode old '||old_cost.header_id||' new '||new_cost.header_id||' Onhand '||new_cost.onhand_qty||' adj '||transaction_row.doc_id);
9303: END IF;
9304: UPDATE gmf_lot_cost_adjustments
9305: SET applied_ind = 'Y',
9306: old_cost_header_id = NVL(old_cost.header_id, new_cost.header_id),

Line 9319: fnd_file.put_line

9315: ELSE
9316: IF transaction_row.source = 3 THEN
9317: -- PK Bug 6697946 If old_cost.header_id is NULL Use new_cost.header_id
9318: IF l_debug_level >= l_debug_level_high THEN
9319: fnd_file.put_line
9320: (fnd_file.log,'TEST Mode old '||old_cost.header_id||' new '||new_cost.header_id||' Onhand '||new_cost.onhand_qty||' adj '||transaction_row.doc_id);
9321: END IF;
9322: UPDATE gmf_lot_cost_adjustments
9323: SET old_cost_header_id = NVL(old_cost.header_id, new_cost.header_id),

Line 9320: (fnd_file.log,'TEST Mode old '||old_cost.header_id||' new '||new_cost.header_id||' Onhand '||new_cost.onhand_qty||' adj '||transaction_row.doc_id);

9316: IF transaction_row.source = 3 THEN
9317: -- PK Bug 6697946 If old_cost.header_id is NULL Use new_cost.header_id
9318: IF l_debug_level >= l_debug_level_high THEN
9319: fnd_file.put_line
9320: (fnd_file.log,'TEST Mode old '||old_cost.header_id||' new '||new_cost.header_id||' Onhand '||new_cost.onhand_qty||' adj '||transaction_row.doc_id);
9321: END IF;
9322: UPDATE gmf_lot_cost_adjustments
9323: SET old_cost_header_id = NVL(old_cost.header_id, new_cost.header_id),
9324: new_cost_header_id = new_cost.header_id,

Line 9332: fnd_file.put_line(fnd_file.log,'WARNING: Setting Lot for the orgn/Item/Lot '||transaction_row.orgn_id||'/'||transaction_row.inventory_item_id||'/'||transaction_row.lot_number||' as uncostable');

9328: END IF;
9329: COMMIT;
9330: ELSE
9331: -- Add this lot to the list of lots that can't be costed
9332: fnd_file.put_line(fnd_file.log,'WARNING: Setting Lot for the orgn/Item/Lot '||transaction_row.orgn_id||'/'||transaction_row.inventory_item_id||'/'||transaction_row.lot_number||' as uncostable');
9333: l_uncostable_lots_tab(transaction_row.orgn_id||'-'||transaction_row.inventory_item_id||'-'||transaction_row.lot_number) := transaction_row.inventory_item_id;
9334: l_tmp := FALSE;
9335: l_return_code := 'F';
9336: ROLLBACK TO SAVEPOINT inv_tran;

Line 9342: fnd_file.put_line(fnd_file.log,' Current orgn/Item/Lot '||transaction_row.orgn_id||'/'||transaction_row.inventory_item_id||'/'||transaction_row.lot_number||' is Not Costable');

9338:
9339: ELSE
9340: IF l_debug_level >= l_debug_level_high
9341: THEN
9342: fnd_file.put_line(fnd_file.log,' Current orgn/Item/Lot '||transaction_row.orgn_id||'/'||transaction_row.inventory_item_id||'/'||transaction_row.lot_number||' is Not Costable');
9343: fnd_file.put_line(fnd_file.log,' So skipping the transaction: '||transaction_row.transaction_id);
9344: END IF;
9345: END IF; -- skip this txn
9346: FETCH inv_tran_cursor INTO transaction_row;

Line 9343: fnd_file.put_line(fnd_file.log,' So skipping the transaction: '||transaction_row.transaction_id);

9339: ELSE
9340: IF l_debug_level >= l_debug_level_high
9341: THEN
9342: fnd_file.put_line(fnd_file.log,' Current orgn/Item/Lot '||transaction_row.orgn_id||'/'||transaction_row.inventory_item_id||'/'||transaction_row.lot_number||' is Not Costable');
9343: fnd_file.put_line(fnd_file.log,' So skipping the transaction: '||transaction_row.transaction_id);
9344: END IF;
9345: END IF; -- skip this txn
9346: FETCH inv_tran_cursor INTO transaction_row;
9347: END LOOP;

Line 9359: fnd_file.put_line

9355: ELSE
9356: l_tmp := fnd_concurrent.set_completion_status('NORMAL','Process completed successfully.');
9357: END IF;
9358:
9359: fnd_file.put_line
9360: (fnd_file.log,'Lot Cost Rollup finished at '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));
9361: COMMIT;
9362: EXCEPTION
9363: WHEN OTHERS

Line 9360: (fnd_file.log,'Lot Cost Rollup finished at '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));

9356: l_tmp := fnd_concurrent.set_completion_status('NORMAL','Process completed successfully.');
9357: END IF;
9358:
9359: fnd_file.put_line
9360: (fnd_file.log,'Lot Cost Rollup finished at '||to_char(sysdate,'DD-MON-YYYY HH24:MI:SS'));
9361: COMMIT;
9362: EXCEPTION
9363: WHEN OTHERS
9364: THEN

Line 9365: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);

9361: COMMIT;
9362: EXCEPTION
9363: WHEN OTHERS
9364: THEN
9365: fnd_file.put_line(fnd_file.log,'ERROR: '||substr(sqlerrm,1,100) || ' in ' || procedure_name);
9366: l_tmp := fnd_concurrent.set_completion_status('ERROR',sqlerrm || ' in ' || procedure_name);
9367: ROLLBACK;
9368: END rollup_lot_costs;
9369: END GMF_LOT_COSTING_PUB;