36026: begin
36027: --Initializing global variable
36028:
36029: -- Print the input parameter values
36030: fnd_file.put_line(1, '');
36031: fnd_file.put_line(1, '***********************************************');
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36027: --Initializing global variable
36028:
36029: -- Print the input parameter values
36030: fnd_file.put_line(1, '');
36031: fnd_file.put_line(1, '***********************************************');
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36028:
36029: -- Print the input parameter values
36030: fnd_file.put_line(1, '');
36031: fnd_file.put_line(1, '***********************************************');
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36029: -- Print the input parameter values
36030: fnd_file.put_line(1, '');
36031: fnd_file.put_line(1, '***********************************************');
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36030: fnd_file.put_line(1, '');
36031: fnd_file.put_line(1, '***********************************************');
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36031: fnd_file.put_line(1, '***********************************************');
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36032: fnd_file.put_line(1, '* Process Structure Update Concurrent Program *');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36033: fnd_file.put_line(1, '***********************************************');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36034: fnd_file.put_line(1, '');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36035: fnd_file.put_line(1,'Parameters List ');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36036: fnd_file.put_line(1,'------------------------------------------------');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36044: fnd_file.put_line(1, 'Project Number Structure Name Status');
36037: fnd_file.put_line(1,'Operating Unit : '||p_operating_unit);
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36044: fnd_file.put_line(1, 'Project Number Structure Name Status');
36045: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36038: fnd_file.put_line(1,'From Project Number : '||p_project_num_from);
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36044: fnd_file.put_line(1, 'Project Number Structure Name Status');
36045: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36046:
36039: fnd_file.put_line(1,'To Project Number : '||p_project_num_to);
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36044: fnd_file.put_line(1, 'Project Number Structure Name Status');
36045: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36046:
36047: For i in cur_get_structures loop
36040: fnd_file.put_line(1, '');
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36044: fnd_file.put_line(1, 'Project Number Structure Name Status');
36045: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36046:
36047: For i in cur_get_structures loop
36048: l_return_status := 'S';
36041: fnd_file.put_line(1, '');
36042: fnd_file.put_line(1, 'List of Projects and Structures processed by the concurrent request and their Status');
36043: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36044: fnd_file.put_line(1, 'Project Number Structure Name Status');
36045: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36046:
36047: For i in cur_get_structures loop
36048: l_return_status := 'S';
36049: l_msg_count := 0;
36081: ELSIF (l_return_status = FND_API.G_RET_STS_SUCCESS) THEN
36082: COMMIT;
36083: END IF;
36084:
36085: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||l_return_status);
36086: Else
36087: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||'A process is already running for this structure');
36088: End If;
36089:
36083: END IF;
36084:
36085: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||l_return_status);
36086: Else
36087: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||'A process is already running for this structure');
36088: End If;
36089:
36090: EXCEPTION
36091: WHEN FND_API.G_EXC_ERROR THEN
36099: ,p_msg_data => l_msg_data
36100: ,p_data => l_data
36101: ,p_msg_index_out => l_msg_index_out);
36102: errbuf := l_data;
36103: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||l_return_status||' - '||errbuf);
36104: END IF;
36105: ROLLBACK;
36106:
36107: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
36115: ,p_msg_data => l_msg_data
36116: ,p_data => l_data
36117: ,p_msg_index_out => l_msg_index_out);
36118: errbuf := l_data;
36119: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||l_return_status||' - '||errbuf);
36120: END IF;
36121: ROLLBACK;
36122:
36123: WHEN OTHERS THEN
36122:
36123: WHEN OTHERS THEN
36124: l_retcode := '1';
36125: errbuf := SQLERRM;
36126: fnd_file.put_line(1, rpad(i.project_number,30,' ')||rpad(substrb(i.structure_name,1,60),65,' ')||l_return_status||' - '||errbuf);
36127: ROLLBACK;
36128:
36129: end;
36130: end loop;
36127: ROLLBACK;
36128:
36129: end;
36130: end loop;
36131: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36132: fnd_file.put_line(1, '');
36133: fnd_file.put_line(1, '');
36134:
36135: if l_retcode = 1 then
36128:
36129: end;
36130: end loop;
36131: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36132: fnd_file.put_line(1, '');
36133: fnd_file.put_line(1, '');
36134:
36135: if l_retcode = 1 then
36136: retcode := '1';
36129: end;
36130: end loop;
36131: fnd_file.put_line(1, '-----------------------------------------------------------------------------------------------------');
36132: fnd_file.put_line(1, '');
36133: fnd_file.put_line(1, '');
36134:
36135: if l_retcode = 1 then
36136: retcode := '1';
36137: else