34: l_count_num NUMBER;
35: x_ship_org_num NUMBER;
36: BEGIN
37: IF (l_Debug_Level <= 1) THEN
38: cln_debug_pub.Add('------ Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
39: cln_debug_pub.Add('Value of in Variables:');
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
35: x_ship_org_num NUMBER;
36: BEGIN
37: IF (l_Debug_Level <= 1) THEN
38: cln_debug_pub.Add('------ Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
39: cln_debug_pub.Add('Value of in Variables:');
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
36: BEGIN
37: IF (l_Debug_Level <= 1) THEN
38: cln_debug_pub.Add('------ Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
39: cln_debug_pub.Add('Value of in Variables:');
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
37: IF (l_Debug_Level <= 1) THEN
38: cln_debug_pub.Add('------ Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
39: cln_debug_pub.Add('Value of in Variables:');
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
38: cln_debug_pub.Add('------ Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
39: cln_debug_pub.Add('Value of in Variables:');
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
46: cln_debug_pub.Add('p_supplier_item_num:' ||p_supplier_item_num, 1);
39: cln_debug_pub.Add('Value of in Variables:');
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
46: cln_debug_pub.Add('p_supplier_item_num:' ||p_supplier_item_num, 1);
47: cln_debug_pub.Add('p_ship_to_edi_location_code:' ||p_ship_to_edi_location_code, 1);
40: cln_debug_pub.Add('p_document_line_num:' ||p_document_line_num, 1);
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
46: cln_debug_pub.Add('p_supplier_item_num:' ||p_supplier_item_num, 1);
47: cln_debug_pub.Add('p_ship_to_edi_location_code:' ||p_ship_to_edi_location_code, 1);
48: END IF;
41: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
46: cln_debug_pub.Add('p_supplier_item_num:' ||p_supplier_item_num, 1);
47: cln_debug_pub.Add('p_ship_to_edi_location_code:' ||p_ship_to_edi_location_code, 1);
48: END IF;
49: p_error_code := 0;
42: cln_debug_pub.Add('p_release_num:' ||p_release_num, 1);
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
46: cln_debug_pub.Add('p_supplier_item_num:' ||p_supplier_item_num, 1);
47: cln_debug_pub.Add('p_ship_to_edi_location_code:' ||p_ship_to_edi_location_code, 1);
48: END IF;
49: p_error_code := 0;
50: if ((p_release_num is null) OR (p_release_num = 0)) then
43: cln_debug_pub.Add('p_po_number:' ||p_po_number, 1);
44: cln_debug_pub.Add('p_supplier_code:' ||p_supplier_code, 1);
45: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
46: cln_debug_pub.Add('p_supplier_item_num:' ||p_supplier_item_num, 1);
47: cln_debug_pub.Add('p_ship_to_edi_location_code:' ||p_ship_to_edi_location_code, 1);
48: END IF;
49: p_error_code := 0;
50: if ((p_release_num is null) OR (p_release_num = 0)) then
51: SELECT min(poh.ORG_ID)
87: pll.ship_to_organization_id = msi.organization_id AND
88: pol.item_id = msi.inventory_item_id (+);
89: end if;
90: IF (l_Debug_Level <= 1) THEN
91: cln_debug_pub.Add(' p_org_id:' || p_org_id, 1);
92: END IF;
93: select min(po_header_id)
94: into p_po_header_id
95: from po_headers_all
95: from po_headers_all
96: where segment1 = p_po_number
97: and org_id = p_org_id;
98: IF (l_Debug_Level <= 1) THEN
99: cln_debug_pub.Add(' p_po_header_id' || p_po_header_id, 1);
100: END IF;
101: if ((p_release_num is null) OR (p_release_num = 0)) then
102: select
103: min(pll.ship_to_organization_id)
132: pll.PO_RELEASE_ID = prl.PO_RELEASE_ID AND
133: prl.release_num = p_release_num;
134: end if;
135: IF (l_Debug_Level <= 1) THEN
136: cln_debug_pub.Add(' p_ship_to_org_id:' || p_ship_to_org_id, 1);
137: END IF;
138: --- POS_ASN_XML.DERIVE_vendor_ID begins here
139: select
140: poh.vendor_site_id,poh.vendor_id
144: where
145: poh.po_header_id = p_po_header_id and
146: poh.segment1 =p_po_number;
147: IF (l_Debug_Level <= 1) THEN
148: cln_debug_pub.Add(' p_vendor_site_id:' ||p_vendor_site_id, 1);
149: cln_debug_pub.Add(' p_vendor_id:' ||p_vendor_id, 1);
150: END IF;
151: ----ship to organisaction id
152:
145: poh.po_header_id = p_po_header_id and
146: poh.segment1 =p_po_number;
147: IF (l_Debug_Level <= 1) THEN
148: cln_debug_pub.Add(' p_vendor_site_id:' ||p_vendor_site_id, 1);
149: cln_debug_pub.Add(' p_vendor_id:' ||p_vendor_id, 1);
150: END IF;
151: ----ship to organisaction id
152:
153: BEGIN
157: WHERE ECE_TP_LOCATION_CODE = p_ship_to_edi_location_code;
158: EXCEPTION
159: WHEN no_data_found then
160: IF (l_Debug_Level <= 1) THEN
161: cln_debug_pub.Add('No Data Found in the hr_locations table for p_ship_to_edi_location_code :'||p_ship_to_location_id, 1);
162: END IF;
163: END;
164:
165: IF (l_Debug_Level <= 1) THEN
162: END IF;
163: END;
164:
165: IF (l_Debug_Level <= 1) THEN
166: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
167: END IF;
168:
169: IF (l_Debug_Level <= 1) THEN
170: cln_debug_pub.Add('------ Exiting M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
166: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
167: END IF;
168:
169: IF (l_Debug_Level <= 1) THEN
170: cln_debug_pub.Add('------ Exiting M4R_3B2IN_PKG.RCV_TXN_INPROCESS ------');
171: END IF;
172: EXCEPTION
173: WHEN OTHERS THEN
174: p_error_code := 1;
213: l_count NUMBER;
214: x_ship_to_location_id NUMBER;
215: BEGIN
216: IF (l_Debug_Level <= 1) THEN
217: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS2-----');
218: cln_debug_pub.Add('Value of in Variables:');
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
214: x_ship_to_location_id NUMBER;
215: BEGIN
216: IF (l_Debug_Level <= 1) THEN
217: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS2-----');
218: cln_debug_pub.Add('Value of in Variables:');
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
215: BEGIN
216: IF (l_Debug_Level <= 1) THEN
217: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS2-----');
218: cln_debug_pub.Add('Value of in Variables:');
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
223: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
216: IF (l_Debug_Level <= 1) THEN
217: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS2-----');
218: cln_debug_pub.Add('Value of in Variables:');
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
223: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
224: cln_debug_pub.Add('p_uom_code:' ||p_uom_code, 1);
217: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.RCV_TXN_INPROCESS2-----');
218: cln_debug_pub.Add('Value of in Variables:');
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
223: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
224: cln_debug_pub.Add('p_uom_code:' ||p_uom_code, 1);
225: END IF;
218: cln_debug_pub.Add('Value of in Variables:');
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
223: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
224: cln_debug_pub.Add('p_uom_code:' ||p_uom_code, 1);
225: END IF;
226:
219: cln_debug_pub.Add('p_po_header_id:' ||p_po_header_id, 1);
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
223: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
224: cln_debug_pub.Add('p_uom_code:' ||p_uom_code, 1);
225: END IF;
226:
227: p_error_code := 0;
220: cln_debug_pub.Add('p_line_num:' ||p_line_num, 1);
221: cln_debug_pub.Add('p_document_shipment_line_num:' ||p_document_shipment_line_num, 1);
222: cln_debug_pub.Add('p_release_num :' || p_release_num , 1);
223: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
224: cln_debug_pub.Add('p_uom_code:' ||p_uom_code, 1);
225: END IF;
226:
227: p_error_code := 0;
228: /* save the inbound value for ship_to_location_id for matching */
304:
305: end if;
306:
307: IF (l_Debug_Level <= 1) THEN
308: cln_debug_pub.Add('p_item_id:' ||p_item_id, 1);
309: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
305: end if;
306:
307: IF (l_Debug_Level <= 1) THEN
308: cln_debug_pub.Add('p_item_id:' ||p_item_id, 1);
309: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
306:
307: IF (l_Debug_Level <= 1) THEN
308: cln_debug_pub.Add('p_item_id:' ||p_item_id, 1);
309: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
307: IF (l_Debug_Level <= 1) THEN
308: cln_debug_pub.Add('p_item_id:' ||p_item_id, 1);
309: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
315: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
308: cln_debug_pub.Add('p_item_id:' ||p_item_id, 1);
309: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
315: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
316: cln_debug_pub.Add('p_po_release_id:' ||p_po_release_id, 1);
309: cln_debug_pub.Add('p_item_num:' ||p_item_num, 1);
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
315: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
316: cln_debug_pub.Add('p_po_release_id:' ||p_po_release_id, 1);
317: END IF;
310: cln_debug_pub.Add('p_item_revision:' ||p_item_revision, 1);
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
315: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
316: cln_debug_pub.Add('p_po_release_id:' ||p_po_release_id, 1);
317: END IF;
318:
311: cln_debug_pub.Add('p_supplier_item_num :' || p_supplier_item_num, 1);
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
315: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
316: cln_debug_pub.Add('p_po_release_id:' ||p_po_release_id, 1);
317: END IF;
318:
319:
312: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
313: cln_debug_pub.Add('p_po_line_id:' ||p_po_line_id, 1);
314: cln_debug_pub.Add('p_line_location_id :' || p_line_location_id, 1);
315: cln_debug_pub.Add('p_ship_to_location_id:' ||p_ship_to_location_id, 1);
316: cln_debug_pub.Add('p_po_release_id:' ||p_po_release_id, 1);
317: END IF;
318:
319:
320: /* now validate whether the ship_to_location_id derived from derive_location method
358:
359: end if;
360:
361: IF (l_Debug_Level <= 1) THEN
362: cln_debug_pub.Add('----- Exiting M4R_3B2IN_PKG.RCV_TXN_INPROCESS2-----');
363: END IF;
364:
365: EXCEPTION
366: WHEN OTHERS THEN
401: x_ship_org_count NUMBER;
402: BEGIN
403:
404: IF (l_Debug_Level <= 1) THEN
405: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.GET_VALUES_HEADER -----');
406: cln_debug_pub.Add('Value of in Variables:');
407: cln_debug_pub.Add('p_header_interface_id:' ||p_header_interface_id, 1);
408: END IF;
409:
402: BEGIN
403:
404: IF (l_Debug_Level <= 1) THEN
405: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.GET_VALUES_HEADER -----');
406: cln_debug_pub.Add('Value of in Variables:');
407: cln_debug_pub.Add('p_header_interface_id:' ||p_header_interface_id, 1);
408: END IF;
409:
410: select count(*)
403:
404: IF (l_Debug_Level <= 1) THEN
405: cln_debug_pub.Add('----- Entering M4R_3B2IN_PKG.GET_VALUES_HEADER -----');
406: cln_debug_pub.Add('Value of in Variables:');
407: cln_debug_pub.Add('p_header_interface_id:' ||p_header_interface_id, 1);
408: END IF;
409:
410: select count(*)
411: into x_ship_org_count
437: where
438: header_interface_id = p_header_interface_id;
439:
440: IF (l_Debug_Level <= 1) THEN
441: cln_debug_pub.Add('p_ship_to_org_id:' ||p_ship_to_org_id, 1);
442: cln_debug_pub.Add('p_vendor_id:' ||p_vendor_id, 1);
443: cln_debug_pub.Add('p_vendor_site_id:' ||p_vendor_site_id, 1);
444: END IF;
445:
438: header_interface_id = p_header_interface_id;
439:
440: IF (l_Debug_Level <= 1) THEN
441: cln_debug_pub.Add('p_ship_to_org_id:' ||p_ship_to_org_id, 1);
442: cln_debug_pub.Add('p_vendor_id:' ||p_vendor_id, 1);
443: cln_debug_pub.Add('p_vendor_site_id:' ||p_vendor_site_id, 1);
444: END IF;
445:
446: update rcv_headers_interface
439:
440: IF (l_Debug_Level <= 1) THEN
441: cln_debug_pub.Add('p_ship_to_org_id:' ||p_ship_to_org_id, 1);
442: cln_debug_pub.Add('p_vendor_id:' ||p_vendor_id, 1);
443: cln_debug_pub.Add('p_vendor_site_id:' ||p_vendor_site_id, 1);
444: END IF;
445:
446: update rcv_headers_interface
447: set vendor_id = p_vendor_id,
466: p_error_message := 'No matching Ship To Organization found';
467: end if;
468:
469: IF (l_Debug_Level <= 1) THEN
470: cln_debug_pub.Add('----- Exiting M4R_3B2IN_PKG.GET_VALUES_HEADER -----');
471: END IF;
472: EXCEPTION
473: WHEN OTHERS THEN
474: p_error_code := 3;