DBA Data[Home] [Help]

APPS.CN_PROC_BATCHES_PKG dependencies on CN_MESSAGE_PKG

Line 25: 31-AUG-95 P Cook Pass process_audit_id to cn_message_pkg.end_batch

21: 14-AUG-95 P Cook Replace hardcoded trx batch size with system_batch_size
22: 18-AUG-95 P Cook Handle no_data_found in flood routine excep handlers
23: 30-AUG-95 P Cook Replaced 'raise app_exception' with 'raise' in
24: 'when others' to show the actual exception being raised
25: 31-AUG-95 P Cook Pass process_audit_id to cn_message_pkg.end_batch
26: so that it can fill in the completion timestamp.
27: Changed the 'no transactions to process' message from
28: debug to translated.
29: 26-OCT-95 P Cook Bug: 300974. Modified 'main' to give nice message if

Line 402: cn_message_pkg.DEBUG('Invalid process code: ' || x_physical_process);

398: ELSIF x_physical_process = g_post THEN
399: currst := g_post;
400: newst := g_post;
401: ELSE
402: cn_message_pkg.DEBUG('Invalid process code: ' || x_physical_process);
403: fnd_file.put_line(fnd_file.LOG, 'Invalid process code: ' || x_physical_process);
404: RAISE ABORT;
405: END IF;
406:

Line 428: cn_message_pkg.DEBUG(

424: x_physical_process := g_calculation; --g_logical_process;
425: ELSIF x_physical_process = g_calculation THEN
426: x_physical_process := NULL;
427: ELSE
428: cn_message_pkg.DEBUG(
429: 'Invalid process code: '
430: || x_physical_process
431: || ' (logical process: '
432: || g_logical_process

Line 463: cn_message_pkg.DEBUG(

459: newpr := g_classification;
460: ELSIF x_physical_process = g_classification THEN
461: newpr := NULL;
462: ELSE
463: cn_message_pkg.DEBUG(
464: 'Invalid process code: '
465: || x_physical_process
466: || ' (logical process: '
467: || g_logical_process

Line 488: cn_message_pkg.DEBUG(

484: newpr := g_rollup;
485: ELSIF x_physical_process = g_rollup THEN
486: newpr := NULL;
487: ELSE
488: cn_message_pkg.DEBUG(
489: 'Invalid process code: '
490: || x_physical_process
491: || ' (logical process: '
492: || g_logical_process

Line 515: cn_message_pkg.DEBUG(

511: newpr := g_population;
512: ELSIF x_physical_process = g_population THEN
513: newpr := NULL;
514: ELSE
515: cn_message_pkg.DEBUG(
516: 'Invalid process code: '
517: || x_physical_process
518: || ' (logical process: '
519: || g_logical_process

Line 546: cn_message_pkg.DEBUG(

542: newpr := g_calculation;
543: ELSIF x_physical_process = g_calculation THEN
544: newpr := NULL;
545: ELSE
546: cn_message_pkg.DEBUG(
547: 'Invalid process code: '
548: || x_physical_process
549: || ' (logical process: '
550: || g_logical_process

Line 626: cn_message_pkg.DEBUG('Exception occurs in getting the descendants:');

622: , p_org_id => g_org_id
623: );
624:
625: IF l_return_status <> fnd_api.g_ret_sts_success THEN
626: cn_message_pkg.DEBUG('Exception occurs in getting the descendants:');
627:
628: FOR l_counter IN 1 .. l_msg_count LOOP
629: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
630: , p_encoded => fnd_api.g_false));

Line 629: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter

625: IF l_return_status <> fnd_api.g_ret_sts_success THEN
626: cn_message_pkg.DEBUG('Exception occurs in getting the descendants:');
627:
628: FOR l_counter IN 1 .. l_msg_count LOOP
629: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
630: , p_encoded => fnd_api.g_false));
631: END LOOP;
632:
633: RAISE api_call_failed;

Line 702: cn_message_pkg.DEBUG

698: , SQLERRM
699: );
700: END IF;
701:
702: cn_message_pkg.DEBUG
703: ('Exception occurs in including the descendants in the calc process:');
704: cn_message_pkg.DEBUG(SQLERRM);
705: RAISE;
706: END;

Line 704: cn_message_pkg.DEBUG(SQLERRM);

700: END IF;
701:
702: cn_message_pkg.DEBUG
703: ('Exception occurs in including the descendants in the calc process:');
704: cn_message_pkg.DEBUG(SQLERRM);
705: RAISE;
706: END;
707: END LOOP;
708: END IF; -- checking l_descendant_tbl.count > 0

Line 779: cn_message_pkg.FLUSH;

775: , fnd_msg_pub.get(p_msg_index => l_counter, p_encoded => fnd_api.g_false));
776: END LOOP;
777: END IF;
778:
779: cn_message_pkg.FLUSH;
780: WHEN OTHERS THEN
781: fnd_file.put_line(fnd_file.LOG, 'In cn_proc_batches_pkg.populate_calcsub_batch: ' || SQLERRM);
782: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_calcsub_batch:');
783: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

Line 782: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_calcsub_batch:');

778:
779: cn_message_pkg.FLUSH;
780: WHEN OTHERS THEN
781: fnd_file.put_line(fnd_file.LOG, 'In cn_proc_batches_pkg.populate_calcsub_batch: ' || SQLERRM);
782: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_calcsub_batch:');
783: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
784:
785: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
786: fnd_log.STRING(

Line 783: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

779: cn_message_pkg.FLUSH;
780: WHEN OTHERS THEN
781: fnd_file.put_line(fnd_file.LOG, 'In cn_proc_batches_pkg.populate_calcsub_batch: ' || SQLERRM);
782: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_calcsub_batch:');
783: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
784:
785: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
786: fnd_log.STRING(
787: fnd_log.level_unexpected

Line 1556: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_process_batch:');

1552: (
1553: fnd_file.LOG
1554: , 'Exception occurs in cn_proc_batches_pkg.populate_process_batch: No one with complete compensation plan to calculate.'
1555: );
1556: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_process_batch:');
1557: cn_message_pkg.rollback_errormsg_commit
1558: ('No one with complete compensation plan to calculate.');
1559: RAISE;
1560: WHEN OTHERS THEN

Line 1557: cn_message_pkg.rollback_errormsg_commit

1553: fnd_file.LOG
1554: , 'Exception occurs in cn_proc_batches_pkg.populate_process_batch: No one with complete compensation plan to calculate.'
1555: );
1556: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_process_batch:');
1557: cn_message_pkg.rollback_errormsg_commit
1558: ('No one with complete compensation plan to calculate.');
1559: RAISE;
1560: WHEN OTHERS THEN
1561: fnd_file.put_line(fnd_file.LOG, 'In cn_proc_batches_pkg.populate_process_batch:' || SQLERRM);

Line 1571: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_process_batch: ');

1567: , SQLERRM
1568: );
1569: END IF;
1570:
1571: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_process_batch: ');
1572: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
1573: RAISE;
1574: END populate_process_batch;
1575:

Line 1572: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

1568: );
1569: END IF;
1570:
1571: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_process_batch: ');
1572: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
1573: RAISE;
1574: END populate_process_batch;
1575:
1576: -- Procedure Name

Line 1619: cn_message_pkg.begin_batch(

1615: IF l_batch_rec.status = 'COMPLETE' THEN
1616: -- once completed, can not start it again
1617: NULL;
1618: ELSE
1619: cn_message_pkg.begin_batch(
1620: x_process_type => 'CALCULATION'
1621: , x_parent_proc_audit_id => NULL
1622: , x_process_audit_id => x_process_audit_id
1623: , x_request_id => fnd_global.conc_request_id

Line 1679: cn_message_pkg.set_name('CN', 'ALL_PROCESS_DONE_OK');

1675: , x_process_status_code => x_process_status_code
1676: );
1677: ELSE
1678: x_process_status_code := 'SUCCESS';
1679: cn_message_pkg.set_name('CN', 'ALL_PROCESS_DONE_OK');
1680: cn_message_pkg.end_batch(x_process_audit_id);
1681: END IF;
1682: END IF;
1683:

Line 1680: cn_message_pkg.end_batch(x_process_audit_id);

1676: );
1677: ELSE
1678: x_process_status_code := 'SUCCESS';
1679: cn_message_pkg.set_name('CN', 'ALL_PROCESS_DONE_OK');
1680: cn_message_pkg.end_batch(x_process_audit_id);
1681: END IF;
1682: END IF;
1683:
1684: IF (fnd_log.level_procedure >= fnd_log.g_current_runtime_level) THEN

Line 1698: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.calculation_submission');

1694: (
1695: fnd_file.LOG
1696: , 'no_one_with_complete_plan EXCEPTION in cn_proc_batches_pkg.calculation_submission'
1697: );
1698: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.calculation_submission');
1699: cn_message_pkg.rollback_errormsg_commit
1700: ('No resource with complete compensation plan to calculate.');
1701: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
1702: COMMIT;

Line 1699: cn_message_pkg.rollback_errormsg_commit

1695: fnd_file.LOG
1696: , 'no_one_with_complete_plan EXCEPTION in cn_proc_batches_pkg.calculation_submission'
1697: );
1698: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.calculation_submission');
1699: cn_message_pkg.rollback_errormsg_commit
1700: ('No resource with complete compensation plan to calculate.');
1701: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
1702: COMMIT;
1703: app_exception.raise_exception;

Line 1708: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.calculation_submission:');

1704: WHEN OTHERS THEN
1705: x_process_status_code := 'FAIL';
1706: fnd_file.put_line(fnd_file.LOG, 'Error in cn_proc_batches_pkg.calculation_submission.');
1707: fnd_file.put_line(fnd_file.LOG, SQLERRM);
1708: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.calculation_submission:');
1709: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
1710: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
1711: COMMIT;
1712:

Line 1709: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

1705: x_process_status_code := 'FAIL';
1706: fnd_file.put_line(fnd_file.LOG, 'Error in cn_proc_batches_pkg.calculation_submission.');
1707: fnd_file.put_line(fnd_file.LOG, SQLERRM);
1708: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.calculation_submission:');
1709: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
1710: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
1711: COMMIT;
1712:
1713: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN

Line 1958: cn_message_pkg.set_name('CN', 'PROC_NO_TRX_TO_PROCESS');

1954: CLOSE reps;
1955: END IF;
1956:
1957: IF (reps_tbl.COUNT = 0) THEN
1958: cn_message_pkg.set_name('CN', 'PROC_NO_TRX_TO_PROCESS');
1959:
1960: IF (fnd_log.level_exception >= fnd_log.g_current_runtime_level) THEN
1961: fnd_log.STRING(
1962: fnd_log.level_exception

Line 2052: cn_message_pkg.DEBUG('Finish assigning resources to physical batches.');

2048: , 'Finish assigning resources to physical batches.'
2049: );
2050: END IF;
2051:
2052: cn_message_pkg.DEBUG('Finish assigning resources to physical batches.');
2053: cn_message_pkg.FLUSH;
2054: COMMIT;
2055: EXCEPTION
2056: WHEN no_comm_lines THEN

Line 2053: cn_message_pkg.FLUSH;

2049: );
2050: END IF;
2051:
2052: cn_message_pkg.DEBUG('Finish assigning resources to physical batches.');
2053: cn_message_pkg.FLUSH;
2054: COMMIT;
2055: EXCEPTION
2056: WHEN no_comm_lines THEN
2057: fnd_file.put_line(fnd_file.LOG, 'no_comm_lines exception in cn_proc_batches_pkg.assign');

Line 2058: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.assign:');

2054: COMMIT;
2055: EXCEPTION
2056: WHEN no_comm_lines THEN
2057: fnd_file.put_line(fnd_file.LOG, 'no_comm_lines exception in cn_proc_batches_pkg.assign');
2058: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.assign:');
2059: cn_message_pkg.DEBUG('No transactions to process.');
2060: RAISE;
2061: WHEN OTHERS THEN
2062: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN

Line 2059: cn_message_pkg.DEBUG('No transactions to process.');

2055: EXCEPTION
2056: WHEN no_comm_lines THEN
2057: fnd_file.put_line(fnd_file.LOG, 'no_comm_lines exception in cn_proc_batches_pkg.assign');
2058: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.assign:');
2059: cn_message_pkg.DEBUG('No transactions to process.');
2060: RAISE;
2061: WHEN OTHERS THEN
2062: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
2063: fnd_log.STRING(fnd_log.level_unexpected, 'cn.plsql.cn_proc_batches_pkg.assign.exception'

Line 2068: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.assign:');

2064: , SQLERRM);
2065: END IF;
2066:
2067: fnd_file.put_line(fnd_file.LOG, 'In cn_proc_batches.assign: ' || SQLERRM);
2068: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.assign:');
2069: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
2070: RAISE;
2071: END assign;
2072:

Line 2069: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

2065: END IF;
2066:
2067: fnd_file.put_line(fnd_file.LOG, 'In cn_proc_batches.assign: ' || SQLERRM);
2068: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.assign:');
2069: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
2070: RAISE;
2071: END assign;
2072:
2073: PROCEDURE update_error(x_physical_batch_id NUMBER) IS

Line 2128: cn_message_pkg.DEBUG('Failed to submit concurrent request (batch ID=' || x_physical_batch_id

2124: );
2125: END IF;
2126:
2127: fnd_file.put_line(fnd_file.LOG, 'Submission failure for batch' || x_physical_batch_id);
2128: cn_message_pkg.DEBUG('Failed to submit concurrent request (batch ID=' || x_physical_batch_id
2129: || ')');
2130: cn_message_pkg.DEBUG(fnd_message.get);
2131: -- raise conc_fail;
2132: ELSE

Line 2130: cn_message_pkg.DEBUG(fnd_message.get);

2126:
2127: fnd_file.put_line(fnd_file.LOG, 'Submission failure for batch' || x_physical_batch_id);
2128: cn_message_pkg.DEBUG('Failed to submit concurrent request (batch ID=' || x_physical_batch_id
2129: || ')');
2130: cn_message_pkg.DEBUG(fnd_message.get);
2131: -- raise conc_fail;
2132: ELSE
2133: cn_message_pkg.FLUSH;
2134: COMMIT;

Line 2133: cn_message_pkg.FLUSH;

2129: || ')');
2130: cn_message_pkg.DEBUG(fnd_message.get);
2131: -- raise conc_fail;
2132: ELSE
2133: cn_message_pkg.FLUSH;
2134: COMMIT;
2135: END IF;
2136: END conc_submit;
2137:

Line 2208: cn_message_pkg.FLUSH;

2204:
2205: -- Flood procedure calls
2206: -- flood_salesreps;
2207: flood_rev_classes;
2208: cn_message_pkg.FLUSH;
2209: COMMIT;
2210:
2211: SELECT intelligent_flag, start_date, end_date
2212: INTO l_intelligent_flag, l_start_date, l_end_date

Line 2247: cn_message_pkg.debug(

2243: l_primary_batch_stack(x_batch_total) := physical_rec.physical_batch_id;
2244: l_primary_request_stack(x_batch_total) := l_temp_id;
2245: l_current_phase_stack(x_batch_total) := l_curr_process;
2246:
2247: cn_message_pkg.debug(
2248: 'Submitted request for Physical Batch ' || physical_rec.physical_batch_id ||
2249: ' for process ' || l_curr_process || ' : Request = ' || l_temp_id
2250: );
2251:

Line 2303: cn_message_pkg.debug(

2299: DBMS_LOCK.sleep(l_sleep_time);
2300: END IF;
2301: */
2302:
2303: cn_message_pkg.debug(
2304: 'Check whether we can sleep for sometime to get the requests completed...'
2305: || ' Batch Total = ' || x_batch_total
2306: || ' : Reverted = ' || l_completed_revert_count
2307: || ' : Classified = ' || l_completed_classify_count

Line 2314: cn_message_pkg.debug('A new request has been submitted.. Lets check once more whether any other request has completed.');

2310: || ' : Calculated = ' || l_completed_calculate_count
2311: );
2312:
2313: IF l_new_request_submitted THEN
2314: cn_message_pkg.debug('A new request has been submitted.. Lets check once more whether any other request has completed.');
2315: l_new_request_submitted := FALSE;
2316: ELSE
2317: cn_message_pkg.debug('There is no change evident in this iteration. Therefore sleep for ' || l_sleep_time);
2318: DBMS_LOCK.sleep(l_sleep_time);

Line 2317: cn_message_pkg.debug('There is no change evident in this iteration. Therefore sleep for ' || l_sleep_time);

2313: IF l_new_request_submitted THEN
2314: cn_message_pkg.debug('A new request has been submitted.. Lets check once more whether any other request has completed.');
2315: l_new_request_submitted := FALSE;
2316: ELSE
2317: cn_message_pkg.debug('There is no change evident in this iteration. Therefore sleep for ' || l_sleep_time);
2318: DBMS_LOCK.sleep(l_sleep_time);
2319: END IF;
2320:
2321: FOR i IN 1 .. x_batch_total LOOP

Line 2347: cn_message_pkg.DEBUG('Concurrent Request#' || l_failed_request_id || ' for Physical Batch#' || l_temp_phys_batch_id || ' completed with error');

2343: , 'Request ' || l_failed_request_id || ' failed (batch_id = ' || l_temp_phys_batch_id
2344: );
2345: END IF;
2346:
2347: cn_message_pkg.DEBUG('Concurrent Request#' || l_failed_request_id || ' for Physical Batch#' || l_temp_phys_batch_id || ' completed with error');
2348: fnd_file.put_line(fnd_file.LOG, 'Conc_dispatch: Request completed with error for ' || l_failed_request_id);
2349: fnd_file.put_line(fnd_file.LOG, 'Conc_dispatch: Request failed for physical batch' || l_temp_phys_batch_id);
2350: RAISE conc_fail;
2351: END IF;

Line 2390: cn_message_pkg.DEBUG('Concurrent Request#' || l_failed_request_id || ' for Physical Batch#' || l_temp_phys_batch_id || ' completed with error');

2386: || l_temp_phys_batch_id
2387: );
2388: END IF;
2389:
2390: cn_message_pkg.DEBUG('Concurrent Request#' || l_failed_request_id || ' for Physical Batch#' || l_temp_phys_batch_id || ' completed with error');
2391: fnd_file.put_line(fnd_file.LOG, 'Conc_dispatch: Request completed with error for ' || l_failed_request_id);
2392: fnd_file.put_line(fnd_file.LOG, 'Conc_dispatch: Request failed for physical_batch' || l_temp_phys_batch_id);
2393: RAISE conc_fail;
2394: END IF; -- If error

Line 2449: cn_message_pkg.DEBUG('All concurrent requests complete phase ' || g_logical_process);

2445: next_process(x_physical_process => l_curr_process);
2446: END IF;
2447: ELSIF(l_current_phase_stack(primary_ptr) = g_calculation) THEN
2448: IF (l_completed_calculate_count = x_batch_total) THEN
2449: cn_message_pkg.DEBUG('All concurrent requests complete phase ' || g_logical_process);
2450: unfinished := FALSE;
2451: END IF;
2452: END IF;
2453:

Line 2468: cn_message_pkg.debug(

2464: l_primary_request_stack(primary_ptr) := l_temp_id;
2465: l_current_phase_stack(primary_ptr) := l_curr_process;
2466: l_new_request_submitted := TRUE;
2467:
2468: cn_message_pkg.debug(
2469: 'Moving Physical Batch#' || l_primary_batch_stack(primary_ptr) ||
2470: ' to next process ' || l_curr_process || ' Request = ' || l_temp_id
2471: );
2472:

Line 2508: cn_message_pkg.DEBUG('Cancelling request (ID=' || l_primary_request_stack(i)

2504: );
2505: END IF;
2506:
2507: l_call_status := fnd_concurrent.cancel_request(l_primary_request_stack(i), l_dummy);
2508: cn_message_pkg.DEBUG('Cancelling request (ID=' || l_primary_request_stack(i)
2509: || ' Status=' || l_dummy || ')');
2510: END IF;
2511: END LOOP;
2512: END IF;

Line 2514: cn_message_pkg.end_batch(x_parent_proc_audit_id);

2510: END IF;
2511: END LOOP;
2512: END IF;
2513:
2514: cn_message_pkg.end_batch(x_parent_proc_audit_id);
2515: WHEN OTHERS THEN
2516: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
2517: fnd_log.STRING(fnd_log.level_unexpected
2518: , 'cn.plsql.cn_proc_batches_pkg.conc_dispatch.exception', SQLERRM);

Line 2522: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.conc_dispatch:');

2518: , 'cn.plsql.cn_proc_batches_pkg.conc_dispatch.exception', SQLERRM);
2519: END IF;
2520:
2521: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.conc_dispatch');
2522: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.conc_dispatch:');
2523: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
2524: RAISE;
2525: END conc_dispatch;
2526:

Line 2523: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

2519: END IF;
2520:
2521: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.conc_dispatch');
2522: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.conc_dispatch:');
2523: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
2524: RAISE;
2525: END conc_dispatch;
2526:
2527: PROCEDURE conc_dispatch2(x_parent_proc_audit_id NUMBER) IS

Line 2620: cn_message_pkg.FLUSH;

2616: , 'Beginning of conc_dispatch2...'
2617: );
2618: END IF;
2619:
2620: cn_message_pkg.FLUSH;
2621: COMMIT;
2622:
2623: SELECT intelligent_flag, start_date, end_date
2624: INTO l_intelligent_flag, l_start_date, l_end_date

Line 2735: cn_message_pkg.DEBUG('Concurrent request completed with error (request ID='

2731: , 'Request ' || l_failed_request_id || ' failed (batch_id = ' || l_temp_phys_batch_id
2732: );
2733: END IF;
2734:
2735: cn_message_pkg.DEBUG('Concurrent request completed with error (request ID='
2736: || l_failed_request_id || ')');
2737: cn_message_pkg.DEBUG('(physical batch ID=' || l_temp_phys_batch_id || ')');
2738: fnd_file.put_line(
2739: fnd_file.LOG

Line 2737: cn_message_pkg.DEBUG('(physical batch ID=' || l_temp_phys_batch_id || ')');

2733: END IF;
2734:
2735: cn_message_pkg.DEBUG('Concurrent request completed with error (request ID='
2736: || l_failed_request_id || ')');
2737: cn_message_pkg.DEBUG('(physical batch ID=' || l_temp_phys_batch_id || ')');
2738: fnd_file.put_line(
2739: fnd_file.LOG
2740: , 'Conc_dispatch2: Request completed with error for ' || l_failed_request_id
2741: );

Line 2786: cn_message_pkg.DEBUG('Concurrent request completed with error (request ID='

2782: || l_temp_phys_batch_id
2783: );
2784: END IF;
2785:
2786: cn_message_pkg.DEBUG('Concurrent request completed with error (request ID='
2787: || l_failed_request_id || ')');
2788: cn_message_pkg.DEBUG('(physical batch ID=' || l_temp_phys_batch_id || ')');
2789: fnd_file.put_line(
2790: fnd_file.LOG

Line 2788: cn_message_pkg.DEBUG('(physical batch ID=' || l_temp_phys_batch_id || ')');

2784: END IF;
2785:
2786: cn_message_pkg.DEBUG('Concurrent request completed with error (request ID='
2787: || l_failed_request_id || ')');
2788: cn_message_pkg.DEBUG('(physical batch ID=' || l_temp_phys_batch_id || ')');
2789: fnd_file.put_line(
2790: fnd_file.LOG
2791: , 'Conc_dispatch2: Request completed with error for ' || l_failed_request_id
2792: );

Line 2853: cn_message_pkg.DEBUG('All requests complete phase ' || g_logical_process);

2849: next_process(x_physical_process => l_curr_process);
2850: END IF;
2851: ELSIF(l_current_phase_stack(primary_ptr) = g_calculation) THEN
2852: IF (l_completed_calculate_count = g_batch_total) THEN
2853: cn_message_pkg.DEBUG('All requests complete phase ' || g_logical_process);
2854: unfinished := FALSE;
2855: END IF;
2856: END IF;
2857:

Line 2872: cn_message_pkg.debug(

2868: l_primary_request_stack(primary_ptr) := l_temp_id;
2869: l_current_phase_stack(primary_ptr) := l_curr_process;
2870: l_new_request_submitted := TRUE;
2871:
2872: cn_message_pkg.debug(
2873: 'Moving Physical Batch#' || l_primary_batch_stack(primary_ptr) ||
2874: ' to next process ' || l_curr_process || ' Request = ' || l_temp_id
2875: );
2876:

Line 2904: cn_message_pkg.debug(

2900: DBMS_LOCK.sleep(l_sleep_time);
2901: END IF;
2902: */
2903:
2904: cn_message_pkg.debug(
2905: 'Check whether we can sleep for sometime to get the requests completed...'
2906: || ' Batch Total = ' || g_batch_total
2907: || ' : Reverted = ' || l_completed_revert_count
2908: || ' : Classified = ' || l_completed_classify_count

Line 2915: cn_message_pkg.debug('A new request has been submitted.. Lets check once more whether any other request has completed.');

2911: || ' : Calculated = ' || l_completed_calculate_count
2912: );
2913:
2914: IF l_new_request_submitted THEN
2915: cn_message_pkg.debug('A new request has been submitted.. Lets check once more whether any other request has completed.');
2916: l_new_request_submitted := FALSE;
2917: ELSE
2918: cn_message_pkg.debug('There is no change evident in this iteration. Therefore sleep for ' || l_sleep_time);
2919: DBMS_LOCK.sleep(l_sleep_time);

Line 2918: cn_message_pkg.debug('There is no change evident in this iteration. Therefore sleep for ' || l_sleep_time);

2914: IF l_new_request_submitted THEN
2915: cn_message_pkg.debug('A new request has been submitted.. Lets check once more whether any other request has completed.');
2916: l_new_request_submitted := FALSE;
2917: ELSE
2918: cn_message_pkg.debug('There is no change evident in this iteration. Therefore sleep for ' || l_sleep_time);
2919: DBMS_LOCK.sleep(l_sleep_time);
2920: END IF;
2921:
2922: END LOOP;

Line 2949: cn_message_pkg.DEBUG(

2945: );
2946: END IF;
2947:
2948: l_call_status := fnd_concurrent.cancel_request(l_primary_request_stack(i), l_dummy1);
2949: cn_message_pkg.DEBUG(
2950: 'Cancelling request (ID=' || l_primary_request_stack(i) || ' Status=' || l_dummy1
2951: || ')'
2952: );
2953: END IF;

Line 2957: cn_message_pkg.DEBUG('Concurrent request failed (physical batch ID=' || l_temp_phys_batch_id

2953: END IF;
2954: END LOOP;
2955: END IF;
2956:
2957: cn_message_pkg.DEBUG('Concurrent request failed (physical batch ID=' || l_temp_phys_batch_id
2958: || ')');
2959: cn_message_pkg.end_batch(x_parent_proc_audit_id);
2960: WHEN OTHERS THEN
2961: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN

Line 2959: cn_message_pkg.end_batch(x_parent_proc_audit_id);

2955: END IF;
2956:
2957: cn_message_pkg.DEBUG('Concurrent request failed (physical batch ID=' || l_temp_phys_batch_id
2958: || ')');
2959: cn_message_pkg.end_batch(x_parent_proc_audit_id);
2960: WHEN OTHERS THEN
2961: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
2962: fnd_log.STRING(
2963: fnd_log.level_unexpected

Line 2970: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.conc_dispatch2:');

2966: );
2967: END IF;
2968:
2969: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.conc_dispatch');
2970: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.conc_dispatch2:');
2971: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
2972: RAISE;
2973: END conc_dispatch2;
2974:

Line 2971: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

2967: END IF;
2968:
2969: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.conc_dispatch');
2970: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.conc_dispatch2:');
2971: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
2972: RAISE;
2973: END conc_dispatch2;
2974:
2975: -- Procedure Name

Line 3012: cn_message_pkg.FLUSH;

3008: FETCH bc INTO g_batch_total;
3009: CLOSE bc;
3010:
3011: flood_rev_classes;
3012: cn_message_pkg.FLUSH;
3013: COMMIT;
3014:
3015: WHILE NOT finished LOOP
3016: IF g_calc_type = 'BONUS' THEN

Line 3069: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches.seq_dispatch:');

3065: fnd_log.STRING(fnd_log.level_unexpected
3066: , 'cn.plsql.cn_proc_batches_pkg.seq_dispatch.exception', SQLERRM);
3067: END IF;
3068:
3069: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches.seq_dispatch:');
3070: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
3071: RAISE;
3072: END seq_dispatch;
3073:

Line 3070: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

3066: , 'cn.plsql.cn_proc_batches_pkg.seq_dispatch.exception', SQLERRM);
3067: END IF;
3068:
3069: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches.seq_dispatch:');
3070: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
3071: RAISE;
3072: END seq_dispatch;
3073:
3074: /* ----------------------------------------------------------------------------

Line 3103: cn_message_pkg.begin_batch(

3099: INTO l_org_id
3100: FROM cn_calc_submission_batches
3101: WHERE calc_sub_batch_id = p_calc_sub_batch_id;
3102:
3103: cn_message_pkg.begin_batch(
3104: x_process_type => 'CALCULATION'
3105: , x_parent_proc_audit_id => l_process_audit_id
3106: , x_process_audit_id => l_process_audit_id
3107: , x_request_id => fnd_global.conc_request_id

Line 3111: cn_message_pkg.DEBUG('Beginning of calculate_batch...');

3107: , x_request_id => fnd_global.conc_request_id
3108: , p_org_id => l_org_id
3109: );
3110: fnd_file.put_line(fnd_file.LOG, 'Beginning of calculate_batch...');
3111: cn_message_pkg.DEBUG('Beginning of calculate_batch...');
3112:
3113: UPDATE cn_calc_submission_batches_all
3114: SET process_audit_id = l_process_audit_id
3115: WHERE calc_sub_batch_id = p_calc_sub_batch_id;

Line 3132: cn_message_pkg.DEBUG(l_msg_data);

3128: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3129: FOR l_counter IN 1 .. l_msg_count LOOP
3130: l_msg_data := fnd_msg_pub.get(p_msg_index => l_counter, p_encoded => fnd_api.g_false);
3131: fnd_file.put_line(fnd_file.LOG, l_msg_data);
3132: cn_message_pkg.DEBUG(l_msg_data);
3133: END LOOP;
3134:
3135: retcode := 2;
3136: errbuf := l_msg_data;

Line 3148: cn_message_pkg.DEBUG('End of the calculation process.');

3144: );
3145: END IF;
3146:
3147: fnd_file.put_line(fnd_file.LOG, 'End of the calculation process.');
3148: cn_message_pkg.DEBUG('End of the calculation process.');
3149: cn_message_pkg.end_batch(l_process_audit_id);
3150: EXCEPTION
3151: WHEN OTHERS THEN
3152: retcode := 2;

Line 3149: cn_message_pkg.end_batch(l_process_audit_id);

3145: END IF;
3146:
3147: fnd_file.put_line(fnd_file.LOG, 'End of the calculation process.');
3148: cn_message_pkg.DEBUG('End of the calculation process.');
3149: cn_message_pkg.end_batch(l_process_audit_id);
3150: EXCEPTION
3151: WHEN OTHERS THEN
3152: retcode := 2;
3153: errbuf := SQLERRM;

Line 3163: cn_message_pkg.end_batch(l_process_audit_id);

3159: , SQLERRM
3160: );
3161: END IF;
3162:
3163: cn_message_pkg.end_batch(l_process_audit_id);
3164: END calculate_batch;
3165:
3166: PROCEDURE calc(
3167: errbuf OUT NOCOPY VARCHAR2

Line 3509: cn_message_pkg.begin_batch(

3505:
3506: l_request_id := fnd_global.conc_request_id;
3507:
3508: IF l_request_id <> -1 THEN
3509: cn_message_pkg.begin_batch(
3510: x_process_type => 'CALCULATION'
3511: , x_parent_proc_audit_id => p_parent_proc_audit_id
3512: , x_process_audit_id => l_process_audit_id
3513: , x_request_id => fnd_global.conc_request_id

Line 3518: cn_message_pkg.DEBUG(

3514: , p_org_id => l_org_id
3515: );
3516: END IF;
3517:
3518: cn_message_pkg.DEBUG(
3519: 'Start batch runner (phase=' || p_physical_process || ', batch ID=' || p_physical_batch_id
3520: || ')'
3521: );
3522: cn_proc_batches_pkg.process_status(

Line 3564: cn_message_pkg.DEBUG('Exception occurs in classification process:');

3560: , p_physical_batch_id => p_physical_batch_id
3561: );
3562:
3563: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3564: cn_message_pkg.DEBUG('Exception occurs in classification process:');
3565:
3566: FOR l_counter IN 1 .. l_msg_count LOOP
3567: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
3568: , p_encoded => fnd_api.g_false));

Line 3567: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter

3563: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3564: cn_message_pkg.DEBUG('Exception occurs in classification process:');
3565:
3566: FOR l_counter IN 1 .. l_msg_count LOOP
3567: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
3568: , p_encoded => fnd_api.g_false));
3569: END LOOP;
3570:
3571: RAISE api_call_failed;

Line 3585: cn_message_pkg.DEBUG('Exception occurs in rollup phase:');

3581: , p_physical_batch_id => p_physical_batch_id
3582: );
3583:
3584: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3585: cn_message_pkg.DEBUG('Exception occurs in rollup phase:');
3586:
3587: FOR l_counter IN 1 .. l_msg_count LOOP
3588: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
3589: , p_encoded => fnd_api.g_false));

Line 3588: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter

3584: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3585: cn_message_pkg.DEBUG('Exception occurs in rollup phase:');
3586:
3587: FOR l_counter IN 1 .. l_msg_count LOOP
3588: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
3589: , p_encoded => fnd_api.g_false));
3590: END LOOP;
3591:
3592: RAISE api_call_failed;

Line 3606: cn_message_pkg.DEBUG('Exception occurs in population phase:');

3602: , p_physical_batch_id => p_physical_batch_id
3603: );
3604:
3605: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3606: cn_message_pkg.DEBUG('Exception occurs in population phase:');
3607:
3608: FOR l_counter IN 1 .. l_msg_count LOOP
3609: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
3610: , p_encoded => fnd_api.g_false));

Line 3609: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter

3605: IF l_return_status <> fnd_api.g_ret_sts_success THEN
3606: cn_message_pkg.DEBUG('Exception occurs in population phase:');
3607:
3608: FOR l_counter IN 1 .. l_msg_count LOOP
3609: cn_message_pkg.DEBUG(fnd_msg_pub.get(p_msg_index => l_counter
3610: , p_encoded => fnd_api.g_false));
3611: END LOOP;
3612:
3613: RAISE api_call_failed;

Line 3620: cn_message_pkg.DEBUG(

3616: cn_global_var.initialize_instance_info(l_org_id);
3617: cn_formula_common_pkg.calculate_batch(p_physical_batch_id);
3618: END IF;
3619:
3620: cn_message_pkg.DEBUG(
3621: 'Complete batch runner (phase='
3622: || p_physical_process
3623: || ', batch ID='
3624: || p_physical_batch_id

Line 3669: cn_message_pkg.FLUSH;

3665: AND per.period_set_id = l_period_set_id
3666: AND per.period_type_id = l_period_type_id);
3667: END IF;
3668:
3669: cn_message_pkg.FLUSH;
3670: COMMIT;
3671:
3672: -- If run as a conc program it will have its own process audit id
3673: -- and request id therefore we need to give info on the process

Line 3675: cn_message_pkg.end_batch(l_process_audit_id);

3671:
3672: -- If run as a conc program it will have its own process audit id
3673: -- and request id therefore we need to give info on the process
3674: IF l_request_id <> -1 THEN
3675: cn_message_pkg.end_batch(l_process_audit_id);
3676: END IF;
3677:
3678: retcode := 0;
3679: errbuf := 'Batch runner completes successfully.';

Line 3692: cn_message_pkg.DEBUG('Time is ' || TO_CHAR(SYSDATE, 'DD-MON-YY HH24:MI:SS'));

3688: || TO_CHAR(SYSDATE, 'DD-MON-YY HH24:MI:SS')
3689: );
3690: END IF;
3691:
3692: cn_message_pkg.DEBUG('Time is ' || TO_CHAR(SYSDATE, 'DD-MON-YY HH24:MI:SS'));
3693: fnd_file.put_line(fnd_file.LOG, 'Time is ' || TO_CHAR(SYSDATE, 'DD-MON-YY HH24:MI:SS'));
3694: EXCEPTION
3695: WHEN api_call_failed THEN
3696: retcode := 2;

Line 3706: cn_message_pkg.rollback_errormsg_commit('Exception occurs in batch runner (ID='

3702: , fnd_msg_pub.get(p_msg_index => l_counter, p_encoded => fnd_api.g_false));
3703: END LOOP;
3704: END IF;
3705:
3706: cn_message_pkg.rollback_errormsg_commit('Exception occurs in batch runner (ID='
3707: || p_physical_batch_id || ')');
3708: update_error(p_physical_batch_id);
3709:
3710: -- if concurrent program, commit and close log file

Line 3713: cn_message_pkg.end_batch(l_process_audit_id);

3709:
3710: -- if concurrent program, commit and close log file
3711: -- if sequential calcualtion, commit and leave log file open
3712: IF l_request_id <> -1 THEN
3713: cn_message_pkg.end_batch(l_process_audit_id);
3714: ELSE
3715: COMMIT;
3716: END IF;
3717: WHEN OTHERS THEN

Line 3723: cn_message_pkg.DEBUG('Exception occurs in batch runner (ID=' || p_physical_batch_id || ')');

3719: retcode := 2;
3720: errbuf := SQLERRM;
3721: -- to make sure we record the updates made by update_error
3722: -- we roll back first
3723: cn_message_pkg.DEBUG('Exception occurs in batch runner (ID=' || p_physical_batch_id || ')');
3724: cn_message_pkg.rollback_errormsg_commit(errbuf);
3725: update_error(p_physical_batch_id);
3726:
3727: -- if concurrent program, commit and close log file

Line 3724: cn_message_pkg.rollback_errormsg_commit(errbuf);

3720: errbuf := SQLERRM;
3721: -- to make sure we record the updates made by update_error
3722: -- we roll back first
3723: cn_message_pkg.DEBUG('Exception occurs in batch runner (ID=' || p_physical_batch_id || ')');
3724: cn_message_pkg.rollback_errormsg_commit(errbuf);
3725: update_error(p_physical_batch_id);
3726:
3727: -- if concurrent program, commit and close log file
3728: -- if sequential calcualtion, commit and leave log file open

Line 3730: cn_message_pkg.end_batch(l_process_audit_id);

3726:
3727: -- if concurrent program, commit and close log file
3728: -- if sequential calcualtion, commit and leave log file open
3729: IF l_request_id <> -1 THEN
3730: cn_message_pkg.end_batch(l_process_audit_id);
3731: ELSE
3732: COMMIT;
3733: END IF;
3734:

Line 3780: cn_message_pkg.DEBUG(

3776: END IF;
3777: END LOOP;
3778:
3779: IF x_covered = FALSE THEN
3780: cn_message_pkg.DEBUG(
3781: 'No classification ruleset is defined for the period from '
3782: || p_start_date
3783: || ' to '
3784: || p_end_date

Line 3832: cn_message_pkg.DEBUG('Please synchronize ruleset (Name=' || l_set.NAME || ')');

3828: END IF;
3829:
3830: FOR l_set IN l_rulesets_csr LOOP
3831: IF l_set.ruleset_status IN('UNSYNC', 'INSTINPG', 'INSTFAIL', 'CONCFAIL') THEN
3832: cn_message_pkg.DEBUG('Please synchronize ruleset (Name=' || l_set.NAME || ')');
3833: l_error_ctr := 1;
3834: ELSE
3835: l_cls_pkg_name := 'cn_clsfn_' || TO_CHAR(ABS(l_set.ruleset_id)) || cached_org_append;
3836:

Line 3842: cn_message_pkg.DEBUG('Please synchronize ruleset (name=' || l_set.NAME || ')');

3838: FETCH l_chk_rule_package_csr INTO l_counter;
3839: CLOSE l_chk_rule_package_csr;
3840:
3841: IF l_counter = 0 THEN
3842: cn_message_pkg.DEBUG('Please synchronize ruleset (name=' || l_set.NAME || ')');
3843: cn_message_pkg.DEBUG('Classification package is missing (name=' || l_cls_pkg_name || ')');
3844: l_error_ctr := 1;
3845: END IF;
3846: END IF;

Line 3843: cn_message_pkg.DEBUG('Classification package is missing (name=' || l_cls_pkg_name || ')');

3839: CLOSE l_chk_rule_package_csr;
3840:
3841: IF l_counter = 0 THEN
3842: cn_message_pkg.DEBUG('Please synchronize ruleset (name=' || l_set.NAME || ')');
3843: cn_message_pkg.DEBUG('Classification package is missing (name=' || l_cls_pkg_name || ')');
3844: l_error_ctr := 1;
3845: END IF;
3846: END IF;
3847: END LOOP;

Line 3924: cn_message_pkg.begin_batch(

3920: -- calc submission form.
3921: -- If it is a conc request and was submitted from the form then
3922: -- we will already have the process audit id
3923: IF l_request_id <> -1 THEN
3924: cn_message_pkg.begin_batch(
3925: x_process_type => 'CALCULATION'
3926: , x_parent_proc_audit_id => p_parent_proc_audit_id
3927: , x_process_audit_id => l_process_audit_id
3928: , x_request_id => fnd_global.conc_request_id

Line 4000: cn_message_pkg.end_batch(l_paid);

3996: void_batches(NULL);
3997: END IF;
3998:
3999: <>
4000: cn_message_pkg.end_batch(l_paid);
4001: EXCEPTION
4002: WHEN OTHERS THEN
4003: retcode := 2;
4004: errbuf := SQLERRM;

Line 4007: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.processor:');

4003: retcode := 2;
4004: errbuf := SQLERRM;
4005: fnd_file.put_line(fnd_file.LOG, 'Unexpected exception in cn_proc_batches_pkg.processor');
4006: fnd_file.put_line(fnd_file.LOG, SQLERRM);
4007: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.processor:');
4008: cn_message_pkg.rollback_errormsg_commit(errbuf);
4009: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4010: cn_message_pkg.end_batch(l_paid);
4011:

Line 4008: cn_message_pkg.rollback_errormsg_commit(errbuf);

4004: errbuf := SQLERRM;
4005: fnd_file.put_line(fnd_file.LOG, 'Unexpected exception in cn_proc_batches_pkg.processor');
4006: fnd_file.put_line(fnd_file.LOG, SQLERRM);
4007: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.processor:');
4008: cn_message_pkg.rollback_errormsg_commit(errbuf);
4009: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4010: cn_message_pkg.end_batch(l_paid);
4011:
4012: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN

Line 4010: cn_message_pkg.end_batch(l_paid);

4006: fnd_file.put_line(fnd_file.LOG, SQLERRM);
4007: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.processor:');
4008: cn_message_pkg.rollback_errormsg_commit(errbuf);
4009: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4010: cn_message_pkg.end_batch(l_paid);
4011:
4012: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
4013: fnd_log.STRING(fnd_log.level_unexpected
4014: , 'cn.plsql.cn_proc_batches_pkg.processor.exception', SQLERRM);

Line 4078: cn_message_pkg.begin_batch(

4074: COMMIT;
4075:
4076: -- The process audit_id is passed in when called from the trx form.
4077: IF x_process_audit_id IS NULL THEN
4078: cn_message_pkg.begin_batch(
4079: x_process_type => 'CALCULATION'
4080: , x_parent_proc_audit_id => NULL
4081: , x_process_audit_id => x_process_audit_id
4082: , x_request_id => fnd_global.conc_request_id

Line 4104: cn_message_pkg.DEBUG('Invalid process code (' || p_process_name || ')');

4100: END IF;
4101: ELSE
4102: fnd_file.put_line(fnd_file.LOG
4103: , 'cn_proc_batches_pkg.main: bad process name: ' || p_process_name);
4104: cn_message_pkg.DEBUG('Invalid process code (' || p_process_name || ')');
4105: RAISE ABORT;
4106: END IF;
4107:
4108: IF NVL(cn_global_var.g_system_batch_size, 0) = 0 THEN

Line 4109: cn_message_pkg.set_name('CN', 'PROC_BAD_BATCH_SIZE');

4105: RAISE ABORT;
4106: END IF;
4107:
4108: IF NVL(cn_global_var.g_system_batch_size, 0) = 0 THEN
4109: cn_message_pkg.set_name('CN', 'PROC_BAD_BATCH_SIZE');
4110: fnd_file.put_line(fnd_file.LOG, fnd_message.get);
4111: RAISE ABORT;
4112: END IF;
4113:

Line 4123: cn_message_pkg.DEBUG('Start processing transactions (non concurrent calculation)');

4119: );
4120: END IF;
4121:
4122: IF (p_concurrent_flag = 'N' OR(p_concurrent_flag = 'Y' AND fnd_global.conc_program_id <> -1)) THEN
4123: cn_message_pkg.DEBUG('Start processing transactions (non concurrent calculation)');
4124: cn_proc_batches_pkg.processor(
4125: l_dummy
4126: , l_temp
4127: , x_process_audit_id

Line 4136: cn_message_pkg.DEBUG('End processing transactions (non concurrent calculation)');

4132: , p_end_date
4133: , p_salesrep_id
4134: , p_comp_plan_id
4135: );
4136: cn_message_pkg.DEBUG('End processing transactions (non concurrent calculation)');
4137:
4138: IF (l_temp = 2) THEN
4139: x_process_status_code := 'FAIL';
4140: ELSE

Line 4151: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_OK');

4147: WHERE logical_batch_id = p_logical_batch_id AND status_code = 'ERROR');
4148:
4149: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'COMPLETE');
4150: x_process_status_code := 'SUCCESS';
4151: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_OK');
4152: cn_message_pkg.end_batch(x_process_audit_id);
4153: EXCEPTION
4154: WHEN NO_DATA_FOUND THEN
4155: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');

Line 4152: cn_message_pkg.end_batch(x_process_audit_id);

4148:
4149: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'COMPLETE');
4150: x_process_status_code := 'SUCCESS';
4151: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_OK');
4152: cn_message_pkg.end_batch(x_process_audit_id);
4153: EXCEPTION
4154: WHEN NO_DATA_FOUND THEN
4155: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4156: x_process_status_code := 'FAIL';

Line 4157: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');

4153: EXCEPTION
4154: WHEN NO_DATA_FOUND THEN
4155: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4156: x_process_status_code := 'FAIL';
4157: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');
4158: cn_message_pkg.end_batch(x_process_audit_id);
4159: END;
4160:
4161: COMMIT;

Line 4158: cn_message_pkg.end_batch(x_process_audit_id);

4154: WHEN NO_DATA_FOUND THEN
4155: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4156: x_process_status_code := 'FAIL';
4157: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');
4158: cn_message_pkg.end_batch(x_process_audit_id);
4159: END;
4160:
4161: COMMIT;
4162: END IF;

Line 4188: cn_message_pkg.DEBUG('Failed to submit concurrent request (Batch Processor)');

4184:
4185: IF l_request_id = 0 THEN
4186: fnd_file.put_line(fnd_file.LOG
4187: , 'cn_proc_batches_pkg.main: unable to submit batch_processor');
4188: cn_message_pkg.DEBUG('Failed to submit concurrent request (Batch Processor)');
4189: cn_message_pkg.DEBUG(fnd_message.get);
4190: x_process_status_code := 'FAIL';
4191:
4192: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN

Line 4189: cn_message_pkg.DEBUG(fnd_message.get);

4185: IF l_request_id = 0 THEN
4186: fnd_file.put_line(fnd_file.LOG
4187: , 'cn_proc_batches_pkg.main: unable to submit batch_processor');
4188: cn_message_pkg.DEBUG('Failed to submit concurrent request (Batch Processor)');
4189: cn_message_pkg.DEBUG(fnd_message.get);
4190: x_process_status_code := 'FAIL';
4191:
4192: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
4193: fnd_log.STRING(

Line 4205: cn_message_pkg.end_batch(x_process_audit_id);

4201: ELSE
4202: x_process_status_code := 'SUCCESS';
4203: -- a separate process is being called so we need to wrap up this
4204: -- batch of messages
4205: cn_message_pkg.end_batch(x_process_audit_id);
4206: -- for concurrent request, it makes more sense to return request_id.
4207: -- It is better to use another parameter to return request_id.
4208: x_process_audit_id := l_request_id;
4209: cn_message_pkg.FLUSH;

Line 4209: cn_message_pkg.FLUSH;

4205: cn_message_pkg.end_batch(x_process_audit_id);
4206: -- for concurrent request, it makes more sense to return request_id.
4207: -- It is better to use another parameter to return request_id.
4208: x_process_audit_id := l_request_id;
4209: cn_message_pkg.FLUSH;
4210: COMMIT;
4211: END IF;
4212: END IF;
4213:

Line 4231: cn_message_pkg.rollback_errormsg_commit('Exception occurs in cn_proc_batches_pkg.main.');

4227: );
4228: END IF;
4229: EXCEPTION
4230: WHEN ABORT THEN
4231: cn_message_pkg.rollback_errormsg_commit('Exception occurs in cn_proc_batches_pkg.main.');
4232: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4233: COMMIT;
4234: x_process_status_code := 'FAIL';
4235: fnd_file.put_line(fnd_file.LOG, fnd_message.get);

Line 4236: cn_message_pkg.end_batch(x_process_audit_id);

4232: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4233: COMMIT;
4234: x_process_status_code := 'FAIL';
4235: fnd_file.put_line(fnd_file.LOG, fnd_message.get);
4236: cn_message_pkg.end_batch(x_process_audit_id);
4237: WHEN OTHERS THEN
4238: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.main');
4239: fnd_file.put_line(fnd_file.LOG, SQLERRM);
4240: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.main: ');

Line 4240: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.main: ');

4236: cn_message_pkg.end_batch(x_process_audit_id);
4237: WHEN OTHERS THEN
4238: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.main');
4239: fnd_file.put_line(fnd_file.LOG, SQLERRM);
4240: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.main: ');
4241: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
4242: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4243: COMMIT;
4244: x_process_status_code := 'FAIL';

Line 4241: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

4237: WHEN OTHERS THEN
4238: fnd_file.put_line(fnd_file.LOG, 'unexpected exception in cn_proc_batches_pkg.main');
4239: fnd_file.put_line(fnd_file.LOG, SQLERRM);
4240: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.main: ');
4241: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
4242: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4243: COMMIT;
4244: x_process_status_code := 'FAIL';
4245: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');

Line 4245: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');

4241: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
4242: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4243: COMMIT;
4244: x_process_status_code := 'FAIL';
4245: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');
4246: cn_message_pkg.end_batch(x_process_audit_id);
4247:
4248: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
4249: fnd_log.STRING(fnd_log.level_unexpected, 'cn.plsql.cn_proc_batches_pkg.main.exception'

Line 4246: cn_message_pkg.end_batch(x_process_audit_id);

4242: cn_calc_sub_batches_pkg.update_calc_sub_batch(g_logical_batch_id, 'FAILED');
4243: COMMIT;
4244: x_process_status_code := 'FAIL';
4245: --cn_message_pkg.set_name('CN','ALL_PROCESS_DONE_FAIL');
4246: cn_message_pkg.end_batch(x_process_audit_id);
4247:
4248: IF (fnd_log.level_unexpected >= fnd_log.g_current_runtime_level) THEN
4249: fnd_log.STRING(fnd_log.level_unexpected, 'cn.plsql.cn_proc_batches_pkg.main.exception'
4250: , SQLERRM);

Line 4886: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_bonus_process_batch:');

4882: );
4883: END IF;
4884: EXCEPTION
4885: WHEN no_comm_lines THEN
4886: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_bonus_process_batch:');
4887: cn_message_pkg.rollback_errormsg_commit
4888: (
4889: 'No one with complete compensation plan to calculate or the period specified is not at the end of the plan element interval'
4890: );

Line 4887: cn_message_pkg.rollback_errormsg_commit

4883: END IF;
4884: EXCEPTION
4885: WHEN no_comm_lines THEN
4886: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_bonus_process_batch:');
4887: cn_message_pkg.rollback_errormsg_commit
4888: (
4889: 'No one with complete compensation plan to calculate or the period specified is not at the end of the plan element interval'
4890: );
4891: fnd_file.put_line

Line 4907: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_bonus_process_batch: ');

4903: , SQLERRM
4904: );
4905: END IF;
4906:
4907: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_bonus_process_batch: ');
4908: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
4909: fnd_file.put_line(fnd_file.LOG
4910: , 'Exception in cn_proc_batches_pkg.populate_bonus_process_batch: ' || SQLERRM);
4911: RAISE;

Line 4908: cn_message_pkg.rollback_errormsg_commit(SQLERRM);

4904: );
4905: END IF;
4906:
4907: cn_message_pkg.DEBUG('Exception occurs in cn_proc_batches_pkg.populate_bonus_process_batch: ');
4908: cn_message_pkg.rollback_errormsg_commit(SQLERRM);
4909: fnd_file.put_line(fnd_file.LOG
4910: , 'Exception in cn_proc_batches_pkg.populate_bonus_process_batch: ' || SQLERRM);
4911: RAISE;
4912: END populate_bonus_process_batch;