DBA Data[Home] [Help]

APPS.RCV_ROI_PREPROCESSOR dependencies on RCV_ROI_PREPROCESSOR

Line 1: PACKAGE BODY rcv_roi_preprocessor AS

1: PACKAGE BODY rcv_roi_preprocessor AS
2: /* $Header: RCVPREPB.pls 120.37 2012/01/19 10:09:23 sadibhat ship $*/
3: -- Read the profile option that enables/disables the debug log
4: g_asn_debug VARCHAR2(1) := asn_debug.is_debug_on; -- Bug 9152790
5: x_interface_type VARCHAR2(25) := 'RCV-856';

Line 80: ( x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,

76: END get_header_record;
77: */
78: -- Bug 10227549 : Start
79: PROCEDURE derive_destination_info
80: ( x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,
81: n IN OUT NOCOPY BINARY_INTEGER) IS
82:
83: l_destination_type VARCHAR2(10);
84: BEGIN

Line 186: x_error_record rcv_roi_preprocessor.error_rec_type;

182: PROCEDURE preprocessor(
183: x_request_id NUMBER,
184: x_group_id NUMBER
185: ) IS
186: x_error_record rcv_roi_preprocessor.error_rec_type;
187: x_header_record rcv_roi_preprocessor.header_rec_type;
188: x_cascaded_table rcv_roi_preprocessor.cascaded_trans_tab_type;
189: x_progress VARCHAR2(3) := '000';
190: x_fail_all_lines VARCHAR2(1) := 'N';

Line 187: x_header_record rcv_roi_preprocessor.header_rec_type;

183: x_request_id NUMBER,
184: x_group_id NUMBER
185: ) IS
186: x_error_record rcv_roi_preprocessor.error_rec_type;
187: x_header_record rcv_roi_preprocessor.header_rec_type;
188: x_cascaded_table rcv_roi_preprocessor.cascaded_trans_tab_type;
189: x_progress VARCHAR2(3) := '000';
190: x_fail_all_lines VARCHAR2(1) := 'N';
191: x_fail_if_one_line_fails BOOLEAN := FALSE;

Line 188: x_cascaded_table rcv_roi_preprocessor.cascaded_trans_tab_type;

184: x_group_id NUMBER
185: ) IS
186: x_error_record rcv_roi_preprocessor.error_rec_type;
187: x_header_record rcv_roi_preprocessor.header_rec_type;
188: x_cascaded_table rcv_roi_preprocessor.cascaded_trans_tab_type;
189: x_progress VARCHAR2(3) := '000';
190: x_fail_all_lines VARCHAR2(1) := 'N';
191: x_fail_if_one_line_fails BOOLEAN := FALSE;
192: n BINARY_INTEGER := 0;

Line 193: x_empty_header_record rcv_roi_preprocessor.header_rec_type;

189: x_progress VARCHAR2(3) := '000';
190: x_fail_all_lines VARCHAR2(1) := 'N';
191: x_fail_if_one_line_fails BOOLEAN := FALSE;
192: n BINARY_INTEGER := 0;
193: x_empty_header_record rcv_roi_preprocessor.header_rec_type;
194: --added for lpn support
195: l_lpn_grp_id rcv_transactions_interface.lpn_group_id%TYPE;
196: l_proc_status_code rcv_transactions_interface.processing_status_code%TYPE;
197: l_group_id rcv_transactions_interface.GROUP_ID%TYPE; -- used in local query

Line 228: x_empty_error_record rcv_roi_preprocessor.error_rec_type;

224:
225: l_exception_group_id group_id_pool;
226: l_return_status VARCHAR2(1);
227: l_check_dcp NUMBER;
228: x_empty_error_record rcv_roi_preprocessor.error_rec_type;
229:
230: /* TYPE header_record_cache IS TABLE OF rcv_roi_preprocessor.header_rec_type
231: INDEX BY BINARY_INTEGER;
232:

Line 230: /* TYPE header_record_cache IS TABLE OF rcv_roi_preprocessor.header_rec_type

226: l_return_status VARCHAR2(1);
227: l_check_dcp NUMBER;
228: x_empty_error_record rcv_roi_preprocessor.error_rec_type;
229:
230: /* TYPE header_record_cache IS TABLE OF rcv_roi_preprocessor.header_rec_type
231: INDEX BY BINARY_INTEGER;
232:
233: l_header_record_cache header_record_cache;
234: */

Line 303: x_asn_rhi_record rcv_roi_preprocessor.header_rec_type;

299: FROM rcv_transactions_interface rti
300: WHERE rti.header_interface_id = rhi.header_interface_id
301: AND rti.processing_status_code = 'ERROR'));
302:
303: x_asn_rhi_record rcv_roi_preprocessor.header_rec_type;
304:
305: BEGIN
306: <>
307: g_asn_debug := asn_debug.is_debug_on; -- Bug 9152790

Line 438: OPEN rcv_roi_preprocessor.txns_cur(p_request_id, p_group_id);

434: NULL;
435: END;
436: END LOOP;
437:
438: OPEN rcv_roi_preprocessor.txns_cur(p_request_id, p_group_id);
439:
440: IF (g_asn_debug = 'Y') THEN
441: asn_debug.put_line('Opened transactions cursor.');
442: END IF;

Line 452: FETCH rcv_roi_preprocessor.txns_cur INTO x_cascaded_table(n);

448: -- Loop through the entries in rcv_transactions_interface.
449: LOOP --{
450: asn_debug.put_line('enter loop');
451: n := n + 1;
452: FETCH rcv_roi_preprocessor.txns_cur INTO x_cascaded_table(n);
453: EXIT WHEN rcv_roi_preprocessor.txns_cur%NOTFOUND;
454: x_cascaded_table(n).error_status := 'S';
455: x_cascaded_table(n).error_message := NULL;
456: x_cascaded_table(n).derive := 'N';

Line 453: EXIT WHEN rcv_roi_preprocessor.txns_cur%NOTFOUND;

449: LOOP --{
450: asn_debug.put_line('enter loop');
451: n := n + 1;
452: FETCH rcv_roi_preprocessor.txns_cur INTO x_cascaded_table(n);
453: EXIT WHEN rcv_roi_preprocessor.txns_cur%NOTFOUND;
454: x_cascaded_table(n).error_status := 'S';
455: x_cascaded_table(n).error_message := NULL;
456: x_cascaded_table(n).derive := 'N';
457: x_cascaded_table(n).matching_basis := 'QUANTITY';

Line 607: OPEN rcv_roi_preprocessor.headers_cur(p_request_id,

603: x_header_record := x_empty_header_record;
604: -- initialize error_record
605: x_header_record.error_record := x_error_record;
606:
607: OPEN rcv_roi_preprocessor.headers_cur(p_request_id,
608: p_group_id,
609: x_cascaded_table(n).header_interface_id
610: );
611: IF (g_asn_debug = 'Y') THEN

Line 615: FETCH rcv_roi_preprocessor.headers_cur INTO x_header_record.header_record;

611: IF (g_asn_debug = 'Y') THEN
612: asn_debug.put_line('Before processing header');
613: END IF;
614:
615: FETCH rcv_roi_preprocessor.headers_cur INTO x_header_record.header_record;
616: -- there should be 1 header record for this transaction
617: asn_debug.put_line('Processing header for interface txn id =' ||
618: TO_CHAR(x_cascaded_table(n).interface_transaction_id));
619: -- header cursor found, header is not processed yet : process the header

Line 620: IF RCV_ROI_PREPROCESSOR.headers_cur%FOUND THEN --{

616: -- there should be 1 header record for this transaction
617: asn_debug.put_line('Processing header for interface txn id =' ||
618: TO_CHAR(x_cascaded_table(n).interface_transaction_id));
619: -- header cursor found, header is not processed yet : process the header
620: IF RCV_ROI_PREPROCESSOR.headers_cur%FOUND THEN --{
621: IF x_header_record.header_record.processing_status_code = 'RUNNING' THEN --{
622: IF (x_cascaded_table(n).transaction_type IN ('SHIP', 'RECEIVE')) THEN --{
623:
624: IF x_header_record.header_record.transaction_type = 'NEW' THEN --{

Line 689: CLOSE rcv_roi_preprocessor.headers_cur;

685: rcv_error_pkg.log_interface_error('HEADER_INTERFACE_ID', FALSE);
686: END IF; --} this is the check for whether header is processed
687:
688: asn_debug.put_line('closing the header cursor for txn = ' || TO_CHAR(x_cascaded_table(n).interface_transaction_id));
689: CLOSE rcv_roi_preprocessor.headers_cur;
690: END IF; --} matches excluding shared header.
691:
692: -- after processing header update rhi/rti
693: -- IF (x_header_record.error_record.error_status = 'E') THEN -- Bugfix 5592848

Line 756: OPEN rcv_roi_preprocessor.headers_cur(p_request_id,

752: to_char(x_cascaded_table(n).interface_transaction_id));
753: END IF;
754: x_header_record := x_empty_header_record;
755: x_header_record.error_record := x_error_record;
756: OPEN rcv_roi_preprocessor.headers_cur(p_request_id,
757: p_group_id,
758: x_cascaded_table(n).header_interface_id
759: );
760: FETCH rcv_roi_preprocessor.headers_cur INTO x_header_record.header_record;

Line 760: FETCH rcv_roi_preprocessor.headers_cur INTO x_header_record.header_record;

756: OPEN rcv_roi_preprocessor.headers_cur(p_request_id,
757: p_group_id,
758: x_cascaded_table(n).header_interface_id
759: );
760: FETCH rcv_roi_preprocessor.headers_cur INTO x_header_record.header_record;
761: IF RCV_ROI_PREPROCESSOR.headers_cur%NOTFOUND THEN --{
762: -- header record is missing. need to error out this trxn.
763: IF (g_asn_debug = 'Y') THEN
764: asn_debug.put_line('Header missing for trxn '||

Line 761: IF RCV_ROI_PREPROCESSOR.headers_cur%NOTFOUND THEN --{

757: p_group_id,
758: x_cascaded_table(n).header_interface_id
759: );
760: FETCH rcv_roi_preprocessor.headers_cur INTO x_header_record.header_record;
761: IF RCV_ROI_PREPROCESSOR.headers_cur%NOTFOUND THEN --{
762: -- header record is missing. need to error out this trxn.
763: IF (g_asn_debug = 'Y') THEN
764: asn_debug.put_line('Header missing for trxn '||
765: to_char(x_cascaded_table(n).interface_transaction_id) ||', set error_status to E');

Line 775: CLOSE rcv_roi_preprocessor.headers_cur;

771: rcv_error_pkg.log_interface_error('HEADER_INTERFACE_ID', FALSE);
772:
773: END IF;
774: asn_debug.put_line('closing the header cursor for txn = ' || TO_CHAR(x_cascaded_table(n).interface_transaction_id));
775: CLOSE rcv_roi_preprocessor.headers_cur;
776:
777: END IF;
778: /**End Bug 8717477 **/
779: END IF; --} matches with x_error_record.error_record <> E

Line 1199: CLOSE rcv_roi_preprocessor.txns_cur;

1195:
1196: /* End 4355172 */
1197:
1198:
1199: CLOSE rcv_roi_preprocessor.txns_cur;
1200: asn_debug.put_line('after loop');
1201:
1202: /* Bug 8831292
1203: * Need to call 824 Interface to insert records into ECE_ADVO_HEADERS

Line 1266: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode');

1262: asn_debug.put_line('Exit preprocessor');
1263: END IF;
1264: EXCEPTION
1265: WHEN NO_DATA_FOUND THEN
1266: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode');
1267: rcv_error_pkg.log_interface_error('PARENT_SOURCE_TRANSACTION_NUM', FALSE);
1268:
1269: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN
1270: CLOSE rcv_roi_preprocessor.txns_cur;

Line 1269: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN

1265: WHEN NO_DATA_FOUND THEN
1266: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode');
1267: rcv_error_pkg.log_interface_error('PARENT_SOURCE_TRANSACTION_NUM', FALSE);
1268:
1269: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN
1270: CLOSE rcv_roi_preprocessor.txns_cur;
1271: END IF;
1272:
1273: --pjiang, close header cursor explicitly

Line 1270: CLOSE rcv_roi_preprocessor.txns_cur;

1266: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode');
1267: rcv_error_pkg.log_interface_error('PARENT_SOURCE_TRANSACTION_NUM', FALSE);
1268:
1269: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN
1270: CLOSE rcv_roi_preprocessor.txns_cur;
1271: END IF;
1272:
1273: --pjiang, close header cursor explicitly
1274: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN

Line 1274: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN

1270: CLOSE rcv_roi_preprocessor.txns_cur;
1271: END IF;
1272:
1273: --pjiang, close header cursor explicitly
1274: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN
1275: CLOSE rcv_roi_preprocessor.headers_cur;
1276: END IF;
1277: WHEN rcv_error_pkg.e_fatal_error THEN --we didn't catch an error that we should have caught
1278: asn_debug.put_line('uncaught e_fatal_error in rcv_roi_preprocess.preprocessor - abnormal execution');

Line 1275: CLOSE rcv_roi_preprocessor.headers_cur;

1271: END IF;
1272:
1273: --pjiang, close header cursor explicitly
1274: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN
1275: CLOSE rcv_roi_preprocessor.headers_cur;
1276: END IF;
1277: WHEN rcv_error_pkg.e_fatal_error THEN --we didn't catch an error that we should have caught
1278: asn_debug.put_line('uncaught e_fatal_error in rcv_roi_preprocess.preprocessor - abnormal execution');
1279: asn_debug.put_line('last error message = ' || rcv_error_pkg.get_last_message);

Line 1281: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode'); -- Bug 13093917

1277: WHEN rcv_error_pkg.e_fatal_error THEN --we didn't catch an error that we should have caught
1278: asn_debug.put_line('uncaught e_fatal_error in rcv_roi_preprocess.preprocessor - abnormal execution');
1279: asn_debug.put_line('last error message = ' || rcv_error_pkg.get_last_message);
1280:
1281: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode'); -- Bug 13093917
1282: rcv_error_pkg.log_interface_error('INTERFACE_TRANSACTION_ID', FALSE); -- Bug 13093917
1283:
1284: WHEN OTHERS THEN
1285: IF (g_asn_debug = 'Y') THEN

Line 1293: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode'); -- Bug 13093917

1289: asn_debug.put_line('l_msg_data: ' || l_msg_data);
1290: asn_debug.put_line('Set rti rows to error for this and call txn complete');
1291: END IF;
1292:
1293: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode'); -- Bug 13093917
1294: rcv_error_pkg.log_interface_error('INTERFACE_TRANSACTION_ID', FALSE); -- Bug 13093917
1295:
1296: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN
1297: CLOSE rcv_roi_preprocessor.txns_cur;

Line 1296: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN

1292:
1293: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode'); -- Bug 13093917
1294: rcv_error_pkg.log_interface_error('INTERFACE_TRANSACTION_ID', FALSE); -- Bug 13093917
1295:
1296: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN
1297: CLOSE rcv_roi_preprocessor.txns_cur;
1298: END IF;
1299:
1300: --pjiang, close header cursor explicitly

Line 1297: CLOSE rcv_roi_preprocessor.txns_cur;

1293: rcv_error_pkg.set_sql_error_message('RCV_ROI_PREPROCESSOR.preprocessor','sqlcode'); -- Bug 13093917
1294: rcv_error_pkg.log_interface_error('INTERFACE_TRANSACTION_ID', FALSE); -- Bug 13093917
1295:
1296: IF rcv_roi_preprocessor.txns_cur%ISOPEN THEN
1297: CLOSE rcv_roi_preprocessor.txns_cur;
1298: END IF;
1299:
1300: --pjiang, close header cursor explicitly
1301: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN

Line 1301: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN

1297: CLOSE rcv_roi_preprocessor.txns_cur;
1298: END IF;
1299:
1300: --pjiang, close header cursor explicitly
1301: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN
1302: CLOSE rcv_roi_preprocessor.headers_cur;
1303: END IF;
1304:
1305: /*We default p_group_id to 0 */

Line 1302: CLOSE rcv_roi_preprocessor.headers_cur;

1298: END IF;
1299:
1300: --pjiang, close header cursor explicitly
1301: IF rcv_roi_preprocessor.headers_cur%ISOPEN THEN
1302: CLOSE rcv_roi_preprocessor.headers_cur;
1303: END IF;
1304:
1305: /*We default p_group_id to 0 */
1306: IF ( p_group_id IS NOT NULL

Line 1342: x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,

1338: END IF;
1339: END preprocessor;
1340:
1341: PROCEDURE default_from_parent_trx(
1342: x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,
1343: n IN OUT NOCOPY BINARY_INTEGER
1344: ) IS
1345: CURSOR get_parent_row_from_rt(
1346: p_transaction_id rcv_transactions.transaction_id%TYPE

Line 1715: x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,

1711: x_cascaded_table(n).error_message := rcv_error_pkg.get_last_message;
1712: END default_from_parent_trx;
1713:
1714: PROCEDURE process_line(
1715: x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,
1716: n IN OUT NOCOPY BINARY_INTEGER,
1717: x_header_id IN rcv_headers_interface.header_interface_id%TYPE,
1718: x_asn_type IN rcv_headers_interface.asn_type%TYPE,
1719: v_header_record IN OUT NOCOPY rcv_roi_preprocessor.header_rec_type

Line 1719: v_header_record IN OUT NOCOPY rcv_roi_preprocessor.header_rec_type

1715: x_cascaded_table IN OUT NOCOPY rcv_roi_preprocessor.cascaded_trans_tab_type,
1716: n IN OUT NOCOPY BINARY_INTEGER,
1717: x_header_id IN rcv_headers_interface.header_interface_id%TYPE,
1718: x_asn_type IN rcv_headers_interface.asn_type%TYPE,
1719: v_header_record IN OUT NOCOPY rcv_roi_preprocessor.header_rec_type
1720: ) IS
1721: x_parent_id NUMBER;
1722: x_progress VARCHAR2(3);
1723: x_error_record rcv_shipment_object_sv.errorrectype;

Line 1726: used_for_cascaded_rows rcv_roi_preprocessor.cascaded_trans_tab_type;

1722: x_progress VARCHAR2(3);
1723: x_error_record rcv_shipment_object_sv.errorrectype;
1724: x_start_indice BINARY_INTEGER := NULL;
1725: i BINARY_INTEGER := NULL;
1726: used_for_cascaded_rows rcv_roi_preprocessor.cascaded_trans_tab_type;
1727: /* Bug 3434460 */
1728: l_return_status VARCHAR2(1);
1729: l_msg_count NUMBER;
1730: l_msg_data fnd_new_messages.MESSAGE_TEXT%TYPE;

Line 2323: END rcv_roi_preprocessor;

2319: IF (g_asn_debug = 'Y') THEN
2320: asn_debug.put_line('Exception in update_rti_error');
2321: END IF;
2322: END update_rti_error;
2323: END rcv_roi_preprocessor;