1: package body ecx_inbound_trig as
2: -- $Header: ECXINBTB.pls 120.20.12020000.5 2013/04/30 18:17:07 jmaddila ship $
3:
4: l_procedure PLS_INTEGER := ecx_debug.g_procedure;
5: l_statement PLS_INTEGER := ecx_debug.g_statement;
6: l_unexpected PLS_INTEGER := ecx_debug.g_unexpected;
7: l_procedureEnabled boolean := ecx_debug.g_procedureEnabled;
8: l_statementEnabled boolean := ecx_debug.g_statementEnabled;
1: package body ecx_inbound_trig as
2: -- $Header: ECXINBTB.pls 120.20.12020000.5 2013/04/30 18:17:07 jmaddila ship $
3:
4: l_procedure PLS_INTEGER := ecx_debug.g_procedure;
5: l_statement PLS_INTEGER := ecx_debug.g_statement;
6: l_unexpected PLS_INTEGER := ecx_debug.g_unexpected;
7: l_procedureEnabled boolean := ecx_debug.g_procedureEnabled;
8: l_statementEnabled boolean := ecx_debug.g_statementEnabled;
9: l_unexpectedEnabled boolean := ecx_debug.g_unexpectedEnabled;
2: -- $Header: ECXINBTB.pls 120.20.12020000.5 2013/04/30 18:17:07 jmaddila ship $
3:
4: l_procedure PLS_INTEGER := ecx_debug.g_procedure;
5: l_statement PLS_INTEGER := ecx_debug.g_statement;
6: l_unexpected PLS_INTEGER := ecx_debug.g_unexpected;
7: l_procedureEnabled boolean := ecx_debug.g_procedureEnabled;
8: l_statementEnabled boolean := ecx_debug.g_statementEnabled;
9: l_unexpectedEnabled boolean := ecx_debug.g_unexpectedEnabled;
10:
3:
4: l_procedure PLS_INTEGER := ecx_debug.g_procedure;
5: l_statement PLS_INTEGER := ecx_debug.g_statement;
6: l_unexpected PLS_INTEGER := ecx_debug.g_unexpected;
7: l_procedureEnabled boolean := ecx_debug.g_procedureEnabled;
8: l_statementEnabled boolean := ecx_debug.g_statementEnabled;
9: l_unexpectedEnabled boolean := ecx_debug.g_unexpectedEnabled;
10:
11: TYPE attribute_rec is RECORD
4: l_procedure PLS_INTEGER := ecx_debug.g_procedure;
5: l_statement PLS_INTEGER := ecx_debug.g_statement;
6: l_unexpected PLS_INTEGER := ecx_debug.g_unexpected;
7: l_procedureEnabled boolean := ecx_debug.g_procedureEnabled;
8: l_statementEnabled boolean := ecx_debug.g_statementEnabled;
9: l_unexpectedEnabled boolean := ecx_debug.g_unexpectedEnabled;
10:
11: TYPE attribute_rec is RECORD
12: (
5: l_statement PLS_INTEGER := ecx_debug.g_statement;
6: l_unexpected PLS_INTEGER := ecx_debug.g_unexpected;
7: l_procedureEnabled boolean := ecx_debug.g_procedureEnabled;
8: l_statementEnabled boolean := ecx_debug.g_statementEnabled;
9: l_unexpectedEnabled boolean := ecx_debug.g_unexpectedEnabled;
10:
11: TYPE attribute_rec is RECORD
12: (
13: attribute_name varchar2(256),
42: end if;
43:
44: exception
45: when others then
46: ecx_debug.setErrorInfo(2, 30,
47: SQLERRM||' - ECX_INBOUND_TRIG.IS_ROUTING_SUPPORTED');
48: if(l_unexpectedEnabled) then
49: --ecx_debug.log(l_statement, ecx_utils.i_errbuf, i_method_name);
50: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
45: when others then
46: ecx_debug.setErrorInfo(2, 30,
47: SQLERRM||' - ECX_INBOUND_TRIG.IS_ROUTING_SUPPORTED');
48: if(l_unexpectedEnabled) then
49: --ecx_debug.log(l_statement, ecx_utils.i_errbuf, i_method_name);
50: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
51: end if;
52: raise ecx_utils.program_exit;
53: end is_routing_supported;
46: ecx_debug.setErrorInfo(2, 30,
47: SQLERRM||' - ECX_INBOUND_TRIG.IS_ROUTING_SUPPORTED');
48: if(l_unexpectedEnabled) then
49: --ecx_debug.log(l_statement, ecx_utils.i_errbuf, i_method_name);
50: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
51: end if;
52: raise ecx_utils.program_exit;
53: end is_routing_supported;
54:
68: pnode xmlDOM.DOMNode;
69: cnode xmlDOM.DOMNode;
70: begin
71: if (l_procedureEnabled) then
72: ecx_debug.push(i_method_name);
73: end if;
74: if(l_statementEnabled) then
75: ecx_debug.log(l_statement,'i_doc',i_doc.id,i_method_name);
76: ecx_debug.log(l_statement,'i_element',i_element,i_method_name);
71: if (l_procedureEnabled) then
72: ecx_debug.push(i_method_name);
73: end if;
74: if(l_statementEnabled) then
75: ecx_debug.log(l_statement,'i_doc',i_doc.id,i_method_name);
76: ecx_debug.log(l_statement,'i_element',i_element,i_method_name);
77: end if;
78: nl := xmlDOM.getElementsByTagName(i_doc,i_element);
79:
72: ecx_debug.push(i_method_name);
73: end if;
74: if(l_statementEnabled) then
75: ecx_debug.log(l_statement,'i_doc',i_doc.id,i_method_name);
76: ecx_debug.log(l_statement,'i_element',i_element,i_method_name);
77: end if;
78: nl := xmlDOM.getElementsByTagName(i_doc,i_element);
79:
80: if (not xmlDOM.isNull(nl))
90: end if;
91: end if;
92: end if;
93: if(l_statementEnabled) then
94: ecx_debug.log(l_statement,'i_value',i_value,i_method_name);
95: end if;
96: if (l_procedureEnabled) then
97: ecx_debug.pop(i_method_name);
98: end if;
93: if(l_statementEnabled) then
94: ecx_debug.log(l_statement,'i_value',i_value,i_method_name);
95: end if;
96: if (l_procedureEnabled) then
97: ecx_debug.pop(i_method_name);
98: end if;
99: exception
100: when others then
101: ecx_debug.setErrorInfo(2,30,
97: ecx_debug.pop(i_method_name);
98: end if;
99: exception
100: when others then
101: ecx_debug.setErrorInfo(2,30,
102: SQLERRM ||' - ECX_INBOUND_TRIG.GET_ELEMENT_VALUE');
103: if(l_unexpectedEnabled) then
104: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
105: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
100: when others then
101: ecx_debug.setErrorInfo(2,30,
102: SQLERRM ||' - ECX_INBOUND_TRIG.GET_ELEMENT_VALUE');
103: if(l_unexpectedEnabled) then
104: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
105: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
106: end if;
107: raise ecx_utils.program_exit;
108: end get_element_value;
101: ecx_debug.setErrorInfo(2,30,
102: SQLERRM ||' - ECX_INBOUND_TRIG.GET_ELEMENT_VALUE');
103: if(l_unexpectedEnabled) then
104: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
105: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
106: end if;
107: raise ecx_utils.program_exit;
108: end get_element_value;
109:
136:
137: i_single varchar2(3):= '''';
138: begin
139: if (l_procedureEnabled) then
140: ecx_debug.push(i_method_name);
141: end if;
142: if(l_statementEnabled) then
143: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
144: end if;
139: if (l_procedureEnabled) then
140: ecx_debug.push(i_method_name);
141: end if;
142: if(l_statementEnabled) then
143: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
144: end if;
145:
146: if i_standard_code is null
147: then
145:
146: if i_standard_code is null
147: then
148: if (l_procedureEnabled) then
149: ecx_debug.pop(i_method_name);
150: end if;
151: return;
152: end if;
153: /** Initialize the attr table **/
163:
164: /** Search for the attribute in the XML File **/
165: get_element_value(i_doc,c1.element_tag_name,i_attr_rec(i_attr_rec.COUNT).value);
166: if(l_statementEnabled) then
167: ecx_debug.log(l_statement,i_attr_rec(i_attr_rec.COUNT).attribute_name,
168: i_attr_rec(i_attr_rec.COUNT).value,i_method_name);
169: end if;
170: i_string := i_string ||' '||i_attr_rec(i_attr_rec.COUNT).attribute_name || ' = '||
171: i_single||i_attr_rec(i_attr_rec.COUNT).value || i_single||' ,';
178:
179: if i_attr_rec.count > 0
180: then
181: if(l_statementEnabled) then
182: ecx_debug.log(l_statement,'i_string',i_string,i_method_name);
183: end if;
184: execute immediate i_string;
185: end if;
186: if (l_procedureEnabled) then
183: end if;
184: execute immediate i_string;
185: end if;
186: if (l_procedureEnabled) then
187: ecx_debug.pop(i_method_name);
188: end if;
189: exception
190: when others then
191: ecx_debug.setErrorInfo(2,30,SQLERRM ||' - ECX_INBOUND_TRIG.getAttributes');
187: ecx_debug.pop(i_method_name);
188: end if;
189: exception
190: when others then
191: ecx_debug.setErrorInfo(2,30,SQLERRM ||' - ECX_INBOUND_TRIG.getAttributes');
192: if(l_unexpectedEnabled) then
193: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
194: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
195: end if;
189: exception
190: when others then
191: ecx_debug.setErrorInfo(2,30,SQLERRM ||' - ECX_INBOUND_TRIG.getAttributes');
192: if(l_unexpectedEnabled) then
193: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
194: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
195: end if;
196: raise ecx_utils.program_exit;
197: end getAttributes;
190: when others then
191: ecx_debug.setErrorInfo(2,30,SQLERRM ||' - ECX_INBOUND_TRIG.getAttributes');
192: if(l_unexpectedEnabled) then
193: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
194: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
195: end if;
196: raise ecx_utils.program_exit;
197: end getAttributes;
198:
208:
209: i_method_name varchar2(2000) := 'ecx_inbound_trig.parsepayload';
210: begin
211: if (l_procedureEnabled) then
212: ecx_debug.push(i_method_name);
213: end if;
214: xmlparser.parseCLOB(ecx_utils.g_parser,i_payload);
215: if (l_procedureEnabled) then
216: ecx_debug.pop(i_method_name);
212: ecx_debug.push(i_method_name);
213: end if;
214: xmlparser.parseCLOB(ecx_utils.g_parser,i_payload);
215: if (l_procedureEnabled) then
216: ecx_debug.pop(i_method_name);
217: end if;
218: exception
219: -- Put All DOM Parser Exceptions Here.
220: when xmlDOM.INDEX_SIZE_ERR then
217: end if;
218: exception
219: -- Put All DOM Parser Exceptions Here.
220: when xmlDOM.INDEX_SIZE_ERR then
221: ecx_debug.setErrorInfo(1,20,SQLERRM);
222: if(l_unexpectedEnabled) then
223: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
224: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
225: end if;
219: -- Put All DOM Parser Exceptions Here.
220: when xmlDOM.INDEX_SIZE_ERR then
221: ecx_debug.setErrorInfo(1,20,SQLERRM);
222: if(l_unexpectedEnabled) then
223: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
224: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
225: end if;
226: if (l_procedureEnabled) then
227: ecx_debug.pop(i_method_name);
220: when xmlDOM.INDEX_SIZE_ERR then
221: ecx_debug.setErrorInfo(1,20,SQLERRM);
222: if(l_unexpectedEnabled) then
223: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
224: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
225: end if;
226: if (l_procedureEnabled) then
227: ecx_debug.pop(i_method_name);
228: end if;
223: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
224: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
225: end if;
226: if (l_procedureEnabled) then
227: ecx_debug.pop(i_method_name);
228: end if;
229: raise ecx_utils.program_exit;
230: when xmlDOM.DOMSTRING_SIZE_ERR then
231: ecx_debug.setErrorInfo(1,20,SQLERRM);
227: ecx_debug.pop(i_method_name);
228: end if;
229: raise ecx_utils.program_exit;
230: when xmlDOM.DOMSTRING_SIZE_ERR then
231: ecx_debug.setErrorInfo(1,20,SQLERRM);
232: if(l_unexpectedEnabled) then
233: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
234: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
235: end if;
229: raise ecx_utils.program_exit;
230: when xmlDOM.DOMSTRING_SIZE_ERR then
231: ecx_debug.setErrorInfo(1,20,SQLERRM);
232: if(l_unexpectedEnabled) then
233: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
234: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
235: end if;
236: if (l_procedureEnabled) then
237: ecx_debug.pop(i_method_name);
230: when xmlDOM.DOMSTRING_SIZE_ERR then
231: ecx_debug.setErrorInfo(1,20,SQLERRM);
232: if(l_unexpectedEnabled) then
233: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
234: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
235: end if;
236: if (l_procedureEnabled) then
237: ecx_debug.pop(i_method_name);
238: end if;
233: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
234: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
235: end if;
236: if (l_procedureEnabled) then
237: ecx_debug.pop(i_method_name);
238: end if;
239: raise ecx_utils.program_exit;
240: when xmlDOM.HIERARCHY_REQUEST_ERR then
241: ecx_debug.setErrorInfo(1,20,SQLERRM);
237: ecx_debug.pop(i_method_name);
238: end if;
239: raise ecx_utils.program_exit;
240: when xmlDOM.HIERARCHY_REQUEST_ERR then
241: ecx_debug.setErrorInfo(1,20,SQLERRM);
242: if(l_unexpectedEnabled) then
243: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
244: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
245: end if;
239: raise ecx_utils.program_exit;
240: when xmlDOM.HIERARCHY_REQUEST_ERR then
241: ecx_debug.setErrorInfo(1,20,SQLERRM);
242: if(l_unexpectedEnabled) then
243: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
244: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
245: end if;
246: if (l_procedureEnabled) then
247: ecx_debug.pop(i_method_name);
240: when xmlDOM.HIERARCHY_REQUEST_ERR then
241: ecx_debug.setErrorInfo(1,20,SQLERRM);
242: if(l_unexpectedEnabled) then
243: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
244: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
245: end if;
246: if (l_procedureEnabled) then
247: ecx_debug.pop(i_method_name);
248: end if;
243: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
244: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
245: end if;
246: if (l_procedureEnabled) then
247: ecx_debug.pop(i_method_name);
248: end if;
249: raise ecx_utils.program_exit;
250: when xmlDOM.WRONG_DOCUMENT_ERR then
251: ecx_debug.setErrorInfo(1,20,SQLERRM);
247: ecx_debug.pop(i_method_name);
248: end if;
249: raise ecx_utils.program_exit;
250: when xmlDOM.WRONG_DOCUMENT_ERR then
251: ecx_debug.setErrorInfo(1,20,SQLERRM);
252: if(l_unexpectedEnabled) then
253: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
254: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
255: end if;
249: raise ecx_utils.program_exit;
250: when xmlDOM.WRONG_DOCUMENT_ERR then
251: ecx_debug.setErrorInfo(1,20,SQLERRM);
252: if(l_unexpectedEnabled) then
253: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
254: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
255: end if;
256: if (l_procedureEnabled) then
257: ecx_debug.pop(i_method_name);
250: when xmlDOM.WRONG_DOCUMENT_ERR then
251: ecx_debug.setErrorInfo(1,20,SQLERRM);
252: if(l_unexpectedEnabled) then
253: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
254: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
255: end if;
256: if (l_procedureEnabled) then
257: ecx_debug.pop(i_method_name);
258: end if;
253: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
254: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
255: end if;
256: if (l_procedureEnabled) then
257: ecx_debug.pop(i_method_name);
258: end if;
259: raise ecx_utils.program_exit;
260: when xmlDOM.INVALID_CHARACTER_ERR then
261: ecx_debug.setErrorInfo(1,20,SQLERRM);
257: ecx_debug.pop(i_method_name);
258: end if;
259: raise ecx_utils.program_exit;
260: when xmlDOM.INVALID_CHARACTER_ERR then
261: ecx_debug.setErrorInfo(1,20,SQLERRM);
262: if(l_unexpectedEnabled) then
263: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
264: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
265: end if;
259: raise ecx_utils.program_exit;
260: when xmlDOM.INVALID_CHARACTER_ERR then
261: ecx_debug.setErrorInfo(1,20,SQLERRM);
262: if(l_unexpectedEnabled) then
263: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
264: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
265: end if;
266: if (l_procedureEnabled) then
267: ecx_debug.pop(i_method_name);
260: when xmlDOM.INVALID_CHARACTER_ERR then
261: ecx_debug.setErrorInfo(1,20,SQLERRM);
262: if(l_unexpectedEnabled) then
263: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
264: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
265: end if;
266: if (l_procedureEnabled) then
267: ecx_debug.pop(i_method_name);
268: end if;
263: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
264: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
265: end if;
266: if (l_procedureEnabled) then
267: ecx_debug.pop(i_method_name);
268: end if;
269: raise ecx_utils.program_exit;
270: when xmlDOM.NO_DATA_ALLOWED_ERR then
271: ecx_debug.setErrorInfo(1,20,SQLERRM);
267: ecx_debug.pop(i_method_name);
268: end if;
269: raise ecx_utils.program_exit;
270: when xmlDOM.NO_DATA_ALLOWED_ERR then
271: ecx_debug.setErrorInfo(1,20,SQLERRM);
272: if(l_unexpectedEnabled) then
273: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
274: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
275: end if;
269: raise ecx_utils.program_exit;
270: when xmlDOM.NO_DATA_ALLOWED_ERR then
271: ecx_debug.setErrorInfo(1,20,SQLERRM);
272: if(l_unexpectedEnabled) then
273: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
274: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
275: end if;
276: if (l_procedureEnabled) then
277: ecx_debug.pop(i_method_name);
270: when xmlDOM.NO_DATA_ALLOWED_ERR then
271: ecx_debug.setErrorInfo(1,20,SQLERRM);
272: if(l_unexpectedEnabled) then
273: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
274: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
275: end if;
276: if (l_procedureEnabled) then
277: ecx_debug.pop(i_method_name);
278: end if;
273: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
274: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
275: end if;
276: if (l_procedureEnabled) then
277: ecx_debug.pop(i_method_name);
278: end if;
279: raise ecx_utils.program_exit;
280: when xmlDOM.No_MODIFICATION_ALLOWED_ERR then
281: ecx_debug.setErrorInfo(1,20,SQLERRM);
277: ecx_debug.pop(i_method_name);
278: end if;
279: raise ecx_utils.program_exit;
280: when xmlDOM.No_MODIFICATION_ALLOWED_ERR then
281: ecx_debug.setErrorInfo(1,20,SQLERRM);
282: if(l_unexpectedEnabled) then
283: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
284: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
285: end if;
279: raise ecx_utils.program_exit;
280: when xmlDOM.No_MODIFICATION_ALLOWED_ERR then
281: ecx_debug.setErrorInfo(1,20,SQLERRM);
282: if(l_unexpectedEnabled) then
283: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
284: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
285: end if;
286: if (l_procedureEnabled) then
287: ecx_debug.pop(i_method_name);
280: when xmlDOM.No_MODIFICATION_ALLOWED_ERR then
281: ecx_debug.setErrorInfo(1,20,SQLERRM);
282: if(l_unexpectedEnabled) then
283: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
284: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
285: end if;
286: if (l_procedureEnabled) then
287: ecx_debug.pop(i_method_name);
288: end if;
283: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
284: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
285: end if;
286: if (l_procedureEnabled) then
287: ecx_debug.pop(i_method_name);
288: end if;
289: raise ecx_utils.program_exit;
290: when xmlDOM.NOT_FOUND_ERR then
291: ecx_debug.setErrorInfo(1,20,SQLERRM);
287: ecx_debug.pop(i_method_name);
288: end if;
289: raise ecx_utils.program_exit;
290: when xmlDOM.NOT_FOUND_ERR then
291: ecx_debug.setErrorInfo(1,20,SQLERRM);
292: if(l_unexpectedEnabled) then
293: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
294: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
295: end if;
289: raise ecx_utils.program_exit;
290: when xmlDOM.NOT_FOUND_ERR then
291: ecx_debug.setErrorInfo(1,20,SQLERRM);
292: if(l_unexpectedEnabled) then
293: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
294: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
295: end if;
296: if (l_procedureEnabled) then
297: ecx_debug.pop(i_method_name);
290: when xmlDOM.NOT_FOUND_ERR then
291: ecx_debug.setErrorInfo(1,20,SQLERRM);
292: if(l_unexpectedEnabled) then
293: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
294: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
295: end if;
296: if (l_procedureEnabled) then
297: ecx_debug.pop(i_method_name);
298: end if;
293: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
294: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
295: end if;
296: if (l_procedureEnabled) then
297: ecx_debug.pop(i_method_name);
298: end if;
299: raise ecx_utils.program_exit;
300: when xmlDOM.NOT_SUPPORTED_ERR then
301: ecx_debug.setErrorInfo(1,20,SQLERRM);
297: ecx_debug.pop(i_method_name);
298: end if;
299: raise ecx_utils.program_exit;
300: when xmlDOM.NOT_SUPPORTED_ERR then
301: ecx_debug.setErrorInfo(1,20,SQLERRM);
302: if(l_unexpectedEnabled) then
303: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
304: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
305: end if;
299: raise ecx_utils.program_exit;
300: when xmlDOM.NOT_SUPPORTED_ERR then
301: ecx_debug.setErrorInfo(1,20,SQLERRM);
302: if(l_unexpectedEnabled) then
303: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
304: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
305: end if;
306: if (l_procedureEnabled) then
307: ecx_debug.pop(i_method_name);
300: when xmlDOM.NOT_SUPPORTED_ERR then
301: ecx_debug.setErrorInfo(1,20,SQLERRM);
302: if(l_unexpectedEnabled) then
303: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
304: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
305: end if;
306: if (l_procedureEnabled) then
307: ecx_debug.pop(i_method_name);
308: end if;
303: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
304: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
305: end if;
306: if (l_procedureEnabled) then
307: ecx_debug.pop(i_method_name);
308: end if;
309: raise ecx_utils.program_exit;
310: when xmlDOM.INUSE_ATTRIBUTE_ERR then
311: ecx_debug.setErrorInfo(1,20,SQLERRM);
307: ecx_debug.pop(i_method_name);
308: end if;
309: raise ecx_utils.program_exit;
310: when xmlDOM.INUSE_ATTRIBUTE_ERR then
311: ecx_debug.setErrorInfo(1,20,SQLERRM);
312: if(l_unexpectedEnabled) then
313: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
314: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
315: end if;
309: raise ecx_utils.program_exit;
310: when xmlDOM.INUSE_ATTRIBUTE_ERR then
311: ecx_debug.setErrorInfo(1,20,SQLERRM);
312: if(l_unexpectedEnabled) then
313: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
314: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
315: end if;
316: if (l_procedureEnabled) then
317: ecx_debug.pop(i_method_name);
310: when xmlDOM.INUSE_ATTRIBUTE_ERR then
311: ecx_debug.setErrorInfo(1,20,SQLERRM);
312: if(l_unexpectedEnabled) then
313: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
314: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
315: end if;
316: if (l_procedureEnabled) then
317: ecx_debug.pop(i_method_name);
318: end if;
313: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
314: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
315: end if;
316: if (l_procedureEnabled) then
317: ecx_debug.pop(i_method_name);
318: end if;
319: raise ecx_utils.program_exit;
320: when others then
321: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.PARSEPAYLOAD ');
317: ecx_debug.pop(i_method_name);
318: end if;
319: raise ecx_utils.program_exit;
320: when others then
321: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.PARSEPAYLOAD ');
322: if(l_unexpectedEnabled) then
323: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
324: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
325: end if;
319: raise ecx_utils.program_exit;
320: when others then
321: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.PARSEPAYLOAD ');
322: if(l_unexpectedEnabled) then
323: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
324: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
325: end if;
326: if (l_procedureEnabled) then
327: ecx_debug.pop(i_method_name);
320: when others then
321: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.PARSEPAYLOAD ');
322: if(l_unexpectedEnabled) then
323: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
324: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
325: end if;
326: if (l_procedureEnabled) then
327: ecx_debug.pop(i_method_name);
328: end if;
323: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
324: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
325: end if;
326: if (l_procedureEnabled) then
327: ecx_debug.pop(i_method_name);
328: end if;
329: raise ecx_utils.program_exit;
330: end parsepayload;
331:
350:
351: begin
352: g_instlmode := wf_core.translate('WF_INSTALL');
353: if (l_procedureEnabled) then
354: ecx_debug.push(i_method_name);
355: end if;
356: dbms_lob.createtemporary(i_xmldoc, TRUE,DBMS_LOB.SESSION);
357: dbms_lob.trim(i_xmldoc, 0);
358: xmlDOM.writetoCLOB(ecx_utils.g_xmldoc,i_xmldoc);
361: if (l_statementEnabled)
362: then
363: IF g_instlmode = 'EMBEDDED' THEN
364: fnd_message.set_name('ecx', 'XML File for logging');
365: attachment_id := fnd_log.message_with_attachment(fnd_log.level_statement, substr(ecx_debug.g_aflog_module_name,1,length(ecx_debug.g_aflog_module_name)-4)||'.xml', TRUE);
366: if(attachment_id <> -1 AND i_xmldoc is not null) then
367: clength := dbms_lob.getlength(i_xmldoc);
368: while clength >= offset LOOP
369: ctemp := dbms_lob.substr(i_xmldoc,g_varmaxlength,offset);
381: end if;
382:
383:
384: if (l_procedureEnabled) then
385: ecx_debug.pop(i_method_name);
386: end if;
387: end writeXMLToFile;
388:
389:
405: l_parseXML boolean;
406:
407: begin
408: if (l_procedureEnabled) then
409: ecx_debug.push(i_method_name);
410: end if;
411: if(l_statementEnabled) then
412: ecx_debug.log(l_statement,'ecx_utils.g_map_id',ecx_utils.g_map_id,i_method_name);
413: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
408: if (l_procedureEnabled) then
409: ecx_debug.push(i_method_name);
410: end if;
411: if(l_statementEnabled) then
412: ecx_debug.log(l_statement,'ecx_utils.g_map_id',ecx_utils.g_map_id,i_method_name);
413: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
414: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
415: ecx_debug.log(l_statement,'i_rcv_tp_id',i_rcv_tp_id,i_method_name);
416: ecx_debug.log(l_statement,'i_message_standard',i_message_standard,i_method_name);
409: ecx_debug.push(i_method_name);
410: end if;
411: if(l_statementEnabled) then
412: ecx_debug.log(l_statement,'ecx_utils.g_map_id',ecx_utils.g_map_id,i_method_name);
413: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
414: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
415: ecx_debug.log(l_statement,'i_rcv_tp_id',i_rcv_tp_id,i_method_name);
416: ecx_debug.log(l_statement,'i_message_standard',i_message_standard,i_method_name);
417: end if;
410: end if;
411: if(l_statementEnabled) then
412: ecx_debug.log(l_statement,'ecx_utils.g_map_id',ecx_utils.g_map_id,i_method_name);
413: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
414: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
415: ecx_debug.log(l_statement,'i_rcv_tp_id',i_rcv_tp_id,i_method_name);
416: ecx_debug.log(l_statement,'i_message_standard',i_message_standard,i_method_name);
417: end if;
418: -- Set the Transaction direction
411: if(l_statementEnabled) then
412: ecx_debug.log(l_statement,'ecx_utils.g_map_id',ecx_utils.g_map_id,i_method_name);
413: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
414: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
415: ecx_debug.log(l_statement,'i_rcv_tp_id',i_rcv_tp_id,i_method_name);
416: ecx_debug.log(l_statement,'i_message_standard',i_message_standard,i_method_name);
417: end if;
418: -- Set the Transaction direction
419: ecx_utils.g_rec_tp_id := i_rcv_tp_id;
412: ecx_debug.log(l_statement,'ecx_utils.g_map_id',ecx_utils.g_map_id,i_method_name);
413: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
414: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
415: ecx_debug.log(l_statement,'i_rcv_tp_id',i_rcv_tp_id,i_method_name);
416: ecx_debug.log(l_statement,'i_message_standard',i_message_standard,i_method_name);
417: end if;
418: -- Set the Transaction direction
419: ecx_utils.g_rec_tp_id := i_rcv_tp_id;
420: ecx_utils.g_direction := 'IN';
457: end if; */
458:
459: if (ecx_utils.dom_printing or (ecx_utils.structure_printing and l_parseXML)) then
460: if(l_statementEnabled) then
461: ecx_debug.log(l_statement,'XML is validated by the parser.',i_method_name);
462: end if;
463: writeXMLToFile(i_xmldoc);
464:
465: begin
471: null;
472: end;
473: else
474: if(l_statementEnabled) then
475: ecx_debug.log(l_statement,'XML is not validated by the parser.',i_method_name);
476: end if;
477: end if;
478: --for bug 5609625
479: xmlparser.freeparser(ecx_utils.g_parser);
483: end if;
484: ---end of 5609625
485:
486: if (l_procedureEnabled) then
487: ecx_debug.pop(i_method_name);
488: end if;
489:
490: exception
491: when ecx_utils.program_exit then
489:
490: exception
491: when ecx_utils.program_exit then
492: if (l_procedureEnabled) then
493: ecx_debug.pop(i_method_name);
494: end if;
495: if(l_unexpectedEnabled) then
496: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
497: end if;
492: if (l_procedureEnabled) then
493: ecx_debug.pop(i_method_name);
494: end if;
495: if(l_unexpectedEnabled) then
496: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
497: end if;
498: ecx_print_local.last_printed := -1;
499:
500: begin
507: end;
508: raise ecx_utils.program_exit;
509:
510: when others then
511: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.processXMLData ');
512: if(l_unexpectedEnabled) then
513: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
514: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
515: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
509:
510: when others then
511: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.processXMLData ');
512: if(l_unexpectedEnabled) then
513: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
514: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
515: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
516: end if;
517: ecx_print_local.last_printed := -1;
510: when others then
511: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.processXMLData ');
512: if(l_unexpectedEnabled) then
513: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
514: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
515: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
516: end if;
517: ecx_print_local.last_printed := -1;
518: if (l_procedureEnabled) then
511: ecx_debug.setErrorInfo(1,20,SQLERRM||' - ECX_INBOUND_TRIG.processXMLData ');
512: if(l_unexpectedEnabled) then
513: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
514: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
515: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
516: end if;
517: ecx_print_local.last_printed := -1;
518: if (l_procedureEnabled) then
519: ecx_debug.pop(i_method_name);
515: ecx_debug.log(l_unexpected,'Clean-up last_printed',i_method_name);
516: end if;
517: ecx_print_local.last_printed := -1;
518: if (l_procedureEnabled) then
519: ecx_debug.pop(i_method_name);
520: end if;
521:
522: begin
523: if not xmlDOM.isNull(ecx_utils.g_xmldoc) then
626: where tp_detail_id = p_routing_id;
627:
628: begin
629: if (l_procedureEnabled) then
630: ecx_debug.push(i_method_name);
631: end if;
632: if(l_statementEnabled) then
633: ecx_debug.log(l_statement,'m_message_standard',m_message_standard,i_method_name);
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
629: if (l_procedureEnabled) then
630: ecx_debug.push(i_method_name);
631: end if;
632: if(l_statementEnabled) then
633: ecx_debug.log(l_statement,'m_message_standard',m_message_standard,i_method_name);
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
635: ecx_debug.log(l_statement,'m_ext_subtype',m_ext_subtype,i_method_name);
636: ecx_debug.log(l_statement,'m_party_ext_code',m_party_ext_code,i_method_name);
637: ecx_debug.log(l_statement,'m_document_number',m_document_number,i_method_name);
630: ecx_debug.push(i_method_name);
631: end if;
632: if(l_statementEnabled) then
633: ecx_debug.log(l_statement,'m_message_standard',m_message_standard,i_method_name);
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
635: ecx_debug.log(l_statement,'m_ext_subtype',m_ext_subtype,i_method_name);
636: ecx_debug.log(l_statement,'m_party_ext_code',m_party_ext_code,i_method_name);
637: ecx_debug.log(l_statement,'m_document_number',m_document_number,i_method_name);
638: ecx_debug.log(l_statement,'m_routing_ext_code',m_routing_ext_code,i_method_name);
631: end if;
632: if(l_statementEnabled) then
633: ecx_debug.log(l_statement,'m_message_standard',m_message_standard,i_method_name);
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
635: ecx_debug.log(l_statement,'m_ext_subtype',m_ext_subtype,i_method_name);
636: ecx_debug.log(l_statement,'m_party_ext_code',m_party_ext_code,i_method_name);
637: ecx_debug.log(l_statement,'m_document_number',m_document_number,i_method_name);
638: ecx_debug.log(l_statement,'m_routing_ext_code',m_routing_ext_code,i_method_name);
639: end if;
632: if(l_statementEnabled) then
633: ecx_debug.log(l_statement,'m_message_standard',m_message_standard,i_method_name);
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
635: ecx_debug.log(l_statement,'m_ext_subtype',m_ext_subtype,i_method_name);
636: ecx_debug.log(l_statement,'m_party_ext_code',m_party_ext_code,i_method_name);
637: ecx_debug.log(l_statement,'m_document_number',m_document_number,i_method_name);
638: ecx_debug.log(l_statement,'m_routing_ext_code',m_routing_ext_code,i_method_name);
639: end if;
640: ecx_utils.i_ret_code :=0;
633: ecx_debug.log(l_statement,'m_message_standard',m_message_standard,i_method_name);
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
635: ecx_debug.log(l_statement,'m_ext_subtype',m_ext_subtype,i_method_name);
636: ecx_debug.log(l_statement,'m_party_ext_code',m_party_ext_code,i_method_name);
637: ecx_debug.log(l_statement,'m_document_number',m_document_number,i_method_name);
638: ecx_debug.log(l_statement,'m_routing_ext_code',m_routing_ext_code,i_method_name);
639: end if;
640: ecx_utils.i_ret_code :=0;
641: ecx_utils.i_errbuf :=null;
634: ecx_debug.log(l_statement,'m_ext_type',m_ext_type,i_method_name);
635: ecx_debug.log(l_statement,'m_ext_subtype',m_ext_subtype,i_method_name);
636: ecx_debug.log(l_statement,'m_party_ext_code',m_party_ext_code,i_method_name);
637: ecx_debug.log(l_statement,'m_document_number',m_document_number,i_method_name);
638: ecx_debug.log(l_statement,'m_routing_ext_code',m_routing_ext_code,i_method_name);
639: end if;
640: ecx_utils.i_ret_code :=0;
641: ecx_utils.i_errbuf :=null;
642: --MLS
653: i_confirmation;
654:
655: if c_tp_details%NOTFOUND
656: then
657: ecx_debug.setErrorInfo(1,30,'ECX_TRANACTION_NOT_ENABLED',
658: 'p_ext_type',
659: m_ext_type,
660: 'p_ext_subtype',
661: m_ext_subtype,
662: 'p_party_ext_code',
663: m_party_ext_code);
664:
665: if(l_statementEnabled) then
666: ecx_debug.log(l_statement,'ECX','ECX_TRANACTION_NOT_ENABLED',
667: i_method_name,
668: 'p_ext_type',
669: m_ext_type,
670: 'p_ext_subtype',
680: close c_tp_details;
681: -- Set the Sender's tp_id
682: ecx_utils.g_snd_tp_id := i_header_id;
683: if(l_statementEnabled) then
684: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
685: ecx_debug.log(l_statement,'i_routing_id',i_routing_id,i_method_name);
686: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
687: ecx_debug.log(l_statement,'i_confirmation',i_confirmation,i_method_name);
688: end if;
681: -- Set the Sender's tp_id
682: ecx_utils.g_snd_tp_id := i_header_id;
683: if(l_statementEnabled) then
684: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
685: ecx_debug.log(l_statement,'i_routing_id',i_routing_id,i_method_name);
686: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
687: ecx_debug.log(l_statement,'i_confirmation',i_confirmation,i_method_name);
688: end if;
689:
682: ecx_utils.g_snd_tp_id := i_header_id;
683: if(l_statementEnabled) then
684: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
685: ecx_debug.log(l_statement,'i_routing_id',i_routing_id,i_method_name);
686: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
687: ecx_debug.log(l_statement,'i_confirmation',i_confirmation,i_method_name);
688: end if;
689:
690: if (i_routing_id is not null or m_routing_ext_code is not null) then if not (is_routing_supported(i_map_id)) then
683: if(l_statementEnabled) then
684: ecx_debug.log(l_statement,'i_map_id',i_map_id,i_method_name);
685: ecx_debug.log(l_statement,'i_routing_id',i_routing_id,i_method_name);
686: ecx_debug.log(l_statement,'i_header_id',i_header_id,i_method_name);
687: ecx_debug.log(l_statement,'i_confirmation',i_confirmation,i_method_name);
688: end if;
689:
690: if (i_routing_id is not null or m_routing_ext_code is not null) then if not (is_routing_supported(i_map_id)) then
691: ecx_debug.setErrorInfo(2, 25, 'ECX_ROUTING_NOT_SUPPORTED');
687: ecx_debug.log(l_statement,'i_confirmation',i_confirmation,i_method_name);
688: end if;
689:
690: if (i_routing_id is not null or m_routing_ext_code is not null) then if not (is_routing_supported(i_map_id)) then
691: ecx_debug.setErrorInfo(2, 25, 'ECX_ROUTING_NOT_SUPPORTED');
692: raise ecx_utils.program_exit;
693: end if;
694: end if;
695:
702: then
703: if m_routing_ext_code is not null
704: then
705: if(l_statementEnabled) then
706: ecx_debug.log(l_statement,'Dynamic Routing1',m_routing_ext_code,i_method_name);
707: end if;
708: open get_routing_for_extcode ( m_ext_type,m_ext_subtype,m_routing_ext_code,m_message_standard, m_message_type);
709: fetch get_routing_for_extcode
710: into i_rcv_tp_id,i_routing_id;
710: into i_rcv_tp_id,i_routing_id;
711:
712: if get_routing_for_extcode%NOTFOUND
713: then
714: ecx_debug.setErrorInfo(1,30,
715: 'ECX_DYN_ROUTING_NOT_ENABLED',
716: 'p_ext_type',
717: m_ext_type,
718: 'p_ext_subtype',
720: 'p_party_ext_code',
721: m_party_ext_code);
722:
723: if(l_statementEnabled) then
724: ecx_debug.log(l_statement,'ECX',
725: 'ECX_DYN_ROUTING_NOT_ENABLED',
726: i_method_name,
727: 'p_ext_type',
728: m_ext_type,
743: fetch get_receiver_tp_id into i_rcv_tp_id;
744:
745: if get_receiver_tp_id%NOTFOUND
746: then
747: ecx_debug.setErrorInfo(1,30,
748: 'ECX_STATIC_ROUTING_NOT_ENABLED',
749: 'p_ext_type',
750: m_ext_type,
751: 'p_ext_subtype',
753: 'p_party_ext_code',
754: m_party_ext_code);
755:
756: if(l_statementEnabled) then
757: ecx_debug.log(l_statement,'ECX',
758: 'ECX_STATIC_ROUTING_NOT_ENABLED',
759: i_method_name,
760: 'p_ext_type',
761: m_ext_type,
770: raise ecx_utils.program_exit;
771: end if;
772: close get_receiver_tp_id;
773: if(l_statementEnabled) then
774: ecx_debug.log(l_statement,'Static Routing',i_method_name);
775: end if;
776:
777: end if;
778: ecx_utils.g_rec_tp_id := i_rcv_tp_id;
776:
777: end if;
778: ecx_utils.g_rec_tp_id := i_rcv_tp_id;
779: if(l_statementEnabled) then
780: ecx_debug.log(l_statement,'Receiver Tp Id ',i_rcv_tp_id,i_method_name);
781: end if;
782:
783: else
784: --- Check for m_routing_ext_code if not null then use it
785:
786: if m_routing_ext_code is not null
787: then
788: if(l_statementEnabled) then
789: ecx_debug.log(l_statement,'Dynamic Routing2',m_routing_ext_code,i_method_name);
790: end if;
791: open get_routing_for_extcode ( m_ext_type,m_ext_subtype,m_routing_ext_code,m_message_standard, m_message_type);
792: fetch get_routing_for_extcode
793: into i_rcv_tp_id,i_routing_id;
793: into i_rcv_tp_id,i_routing_id;
794:
795: if get_routing_for_extcode%NOTFOUND
796: then
797: ecx_debug.setErrorInfo(1,30,
798: 'ECX_DYN_ROUTING_NOT_ENABLED',
799: 'p_ext_type',
800: m_ext_type,
801: 'p_ext_subtype',
803: 'p_party_ext_code',
804: m_party_ext_code);
805:
806: if(l_statementEnabled) then
807: ecx_debug.log(l_statement,'ECX',
808: 'ECX_DYN_ROUTING_NOT_ENABLED',
809: i_method_name,
810: 'p_ext_type',
811: m_ext_type,
829: -- Only if map is xml to xml or dtd to dtd type
830: -- Give warning message.
831: ecx_utils.g_ret_code := 1;
832: if(l_statementEnabled) then
833: ecx_debug.log(l_statement,'ecx_utils.g_ret_code',' 1',i_method_name);
834: end if;
835: end if;
836: end if;
837: end if;
839: -- need to set the g_routing_id here, so that it would set it
840: -- for both dynamic and static routing.
841: ecx_utils.g_routing_id := i_routing_id;
842: if(l_statementEnabled) then
843: ecx_debug.log(l_statement,'ecx_utils.g_routing_id',ecx_utils.g_routing_id,
844: i_method_name);
845: end if;
846:
847: /**
863: end if;
864:
865:
866: if(l_statementEnabled) then
867: ecx_debug.log(l_statement,'ECX','ECX_START_INBOUND',i_method_name, 'TRANSACTION_TYPE', m_ext_type);
868: end if;
869: /*bug 16442475:If value of profile ECX_IN_JAVA_PROCESSING is Y*/
870: if ECX_UTIL_API.isInJavaProcessEnabled then
871: raiseEvent(
875: i_rcv_tp_id => i_rcv_tp_id,
876: i_payload => m_payload,
877: i_no_routing => i_no_routing);
878: if(l_statementEnabled) then
879: ecx_debug.log(l_statement, 'ECX', 'Raised an event to process an xml at java layer',i_method_name);
880: end if;
881: else
882: processXMLData
883: (
889: o_payload,
890: m_message_type
891: );
892: if(l_statementEnabled) then
893: ecx_debug.log(l_statement, 'ECX', 'ECX_END_INBOUND',i_method_name, 'TRANSACTION_TYPE', m_ext_type);
894: end if;
895:
896: savepoint save_xml_doc;
897:
898: --If it is a pass through transaction , then put the Message on the Outbound Queue
899: if i_routing_id is not null
900: then
901: if(l_statementEnabled) then
902: ecx_debug.log(l_statement,'Routing Enqueued for MSGID : '|| m_msgid,i_method_name);
903: end if;
904: put_on_outbound
905: (
906: o_payload,
910: );
911:
912: else
913: if(l_statementEnabled) then
914: ecx_debug.log(l_statement,'Update doclogs for Msg Id : ' , m_msgid,i_method_name);
915: end if;
916: ecx_errorlog.update_log_document
917: (
918: m_msgid,
928: dbms_lob.freetemporary (o_payload);
929: end if;
930: end if;
931: if (l_procedureEnabled) then
932: ecx_debug.pop(i_method_name);
933: end if;
934: exception
935: when ecx_utils.program_exit then
936: --ecx_utils.g_map_id := -1;
934: exception
935: when ecx_utils.program_exit then
936: --ecx_utils.g_map_id := -1;
937: if (l_procedureEnabled) then
938: ecx_debug.pop(i_method_name);
939: end if;
940:
941: if o_payload is not null
942: then
944: end if;
945: raise ecx_utils.program_exit;
946: when others then
947: --ecx_utils.g_map_id := -1;
948: ecx_debug.setErrorInfo(2,30,SQLERRM||' - ECX_INBOUND_TRIG.VALIDATE_MESSAGE ');
949: if(l_unexpectedEnabled) then
950: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
951: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
952: end if;
946: when others then
947: --ecx_utils.g_map_id := -1;
948: ecx_debug.setErrorInfo(2,30,SQLERRM||' - ECX_INBOUND_TRIG.VALIDATE_MESSAGE ');
949: if(l_unexpectedEnabled) then
950: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
951: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
952: end if;
953:
954: if o_payload is not null
947: --ecx_utils.g_map_id := -1;
948: ecx_debug.setErrorInfo(2,30,SQLERRM||' - ECX_INBOUND_TRIG.VALIDATE_MESSAGE ');
949: if(l_unexpectedEnabled) then
950: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
951: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
952: end if;
953:
954: if o_payload is not null
955: then
955: then
956: dbms_lob.freetemporary (o_payload);
957: end if;
958: if (l_procedureEnabled) then
959: ecx_debug.pop(i_method_name);
960: end if;
961: raise ecx_utils.program_exit;
962: end validate_message;
963:
979: l_retmsg Varchar2(200) := null;
980:
981: begin
982: if (l_procedureEnabled) then
983: ecx_debug.push(i_method_name);
984: end if;
985:
986: if(l_statementEnabled) then
987: ecx_debug.log(l_statement,'i_queue_name',i_queue_name,i_method_name);
983: ecx_debug.push(i_method_name);
984: end if;
985:
986: if(l_statementEnabled) then
987: ecx_debug.log(l_statement,'i_queue_name',i_queue_name,i_method_name);
988: end if;
989:
990: v_dequeueoptions.navigation := dbms_aq.FIRST_MESSAGE;
991: v_dequeueoptions.dequeue_mode := dbms_aq.BROWSE;
1004:
1005: --Retrieve the Message Attributes
1006:
1007: if(l_statementEnabled) then
1008: ecx_debug.log(l_statement,'Message Standard',v_message.message_standard,i_method_name);
1009: ecx_debug.log(l_statement,'Message Type',v_message.message_type,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1005: --Retrieve the Message Attributes
1006:
1007: if(l_statementEnabled) then
1008: ecx_debug.log(l_statement,'Message Standard',v_message.message_standard,i_method_name);
1009: ecx_debug.log(l_statement,'Message Type',v_message.message_type,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1006:
1007: if(l_statementEnabled) then
1008: ecx_debug.log(l_statement,'Message Standard',v_message.message_standard,i_method_name);
1009: ecx_debug.log(l_statement,'Message Type',v_message.message_type,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1007: if(l_statementEnabled) then
1008: ecx_debug.log(l_statement,'Message Standard',v_message.message_standard,i_method_name);
1009: ecx_debug.log(l_statement,'Message Type',v_message.message_type,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1008: ecx_debug.log(l_statement,'Message Standard',v_message.message_standard,i_method_name);
1009: ecx_debug.log(l_statement,'Message Type',v_message.message_type,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1009: ecx_debug.log(l_statement,'Message Type',v_message.message_type,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1017: ecx_debug.log(l_statement,'Username ',v_message.username,i_method_name);
1010: ecx_debug.log(l_statement,'Transaction Type',v_message.transaction_type,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1017: ecx_debug.log(l_statement,'Username ',v_message.username,i_method_name);
1018: ecx_debug.log(l_statement,'Password ',v_message.password,i_method_name);
1011: ecx_debug.log(l_statement,'Transaction Sub Type',v_message.transaction_subtype,i_method_name);
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1017: ecx_debug.log(l_statement,'Username ',v_message.username,i_method_name);
1018: ecx_debug.log(l_statement,'Password ',v_message.password,i_method_name);
1019: end if;
1012: ecx_debug.log(l_statement,'Party Id',v_message.partyid,i_method_name);
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1017: ecx_debug.log(l_statement,'Username ',v_message.username,i_method_name);
1018: ecx_debug.log(l_statement,'Password ',v_message.password,i_method_name);
1019: end if;
1020: begin
1013: ecx_debug.log(l_statement,'party Site Id',v_message.party_site_id,i_method_name);
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1017: ecx_debug.log(l_statement,'Username ',v_message.username,i_method_name);
1018: ecx_debug.log(l_statement,'Password ',v_message.password,i_method_name);
1019: end if;
1020: begin
1021: ecx_errorlog.log_document (
1014: ecx_debug.log(l_statement,'party type',v_message.party_type,i_method_name);
1015: ecx_debug.log(l_statement,'protocol_type ',v_message.protocol_type,i_method_name);
1016: ecx_debug.log(l_statement,'Protocol Address ',v_message.protocol_address,i_method_name);
1017: ecx_debug.log(l_statement,'Username ',v_message.username,i_method_name);
1018: ecx_debug.log(l_statement,'Password ',v_message.password,i_method_name);
1019: end if;
1020: begin
1021: ecx_errorlog.log_document (
1022: l_retcode,
1044: );
1045:
1046: if (l_retcode = 1) then
1047: if(l_unexpectedEnabled) then
1048: ecx_debug.log(l_unexpected, l_retmsg,i_method_name);
1049: end if;
1050: elsif (l_retcode >= 2 ) then
1051: if(l_unexpectedEnabled) then
1052: ecx_debug.log(l_unexpected,l_retmsg,i_method_name);
1048: ecx_debug.log(l_unexpected, l_retmsg,i_method_name);
1049: end if;
1050: elsif (l_retcode >= 2 ) then
1051: if(l_unexpectedEnabled) then
1052: ecx_debug.log(l_unexpected,l_retmsg,i_method_name);
1053: end if;
1054: raise ecx_utils.program_exit;
1055: end if;
1056: end;
1054: raise ecx_utils.program_exit;
1055: end if;
1056: end;
1057: if(l_statementEnabled) then
1058: ecx_debug.log(l_statement,'MessageId', i_msgid,i_method_name);
1059: end if;
1060:
1061: end loop;
1062: if(l_statementEnabled) then
1059: end if;
1060:
1061: end loop;
1062: if(l_statementEnabled) then
1063: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1064: end if;
1065: if (l_procedureEnabled) then
1066: ecx_debug.pop(i_method_name);
1067: end if;
1062: if(l_statementEnabled) then
1063: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1064: end if;
1065: if (l_procedureEnabled) then
1066: ecx_debug.pop(i_method_name);
1067: end if;
1068: exception
1069: when ecx_utils.program_exit then
1070: raise;
1068: exception
1069: when ecx_utils.program_exit then
1070: raise;
1071: when others then
1072: ecx_debug.setErrorInfo(2,30,SQLERRM||' - ECX_INBOUND_TRIG.GETMSG_FROM_QUEUE');
1073: if(l_unexpectedEnabled) then
1074: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
1075: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1076: end if;
1070: raise;
1071: when others then
1072: ecx_debug.setErrorInfo(2,30,SQLERRM||' - ECX_INBOUND_TRIG.GETMSG_FROM_QUEUE');
1073: if(l_unexpectedEnabled) then
1074: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
1075: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1076: end if;
1077: raise ecx_utils.program_exit;
1078: end getmsg_from_queue;
1071: when others then
1072: ecx_debug.setErrorInfo(2,30,SQLERRM||' - ECX_INBOUND_TRIG.GETMSG_FROM_QUEUE');
1073: if(l_unexpectedEnabled) then
1074: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
1075: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1076: end if;
1077: raise ecx_utils.program_exit;
1078: end getmsg_from_queue;
1079:
1115:
1116: begin
1117:
1118: if (l_procedureEnabled) then
1119: ecx_debug.push(i_method_name);
1120: end if;
1121: if(l_statementEnabled) then
1122: ecx_debug.log(l_statement,'i_document_number',i_document_number,i_method_name);
1123: ecx_debug.log(l_statement,'i_tp_detail_id',i_tp_detail_id,i_method_name);
1118: if (l_procedureEnabled) then
1119: ecx_debug.push(i_method_name);
1120: end if;
1121: if(l_statementEnabled) then
1122: ecx_debug.log(l_statement,'i_document_number',i_document_number,i_method_name);
1123: ecx_debug.log(l_statement,'i_tp_detail_id',i_tp_detail_id,i_method_name);
1124: end if;
1125:
1126: begin
1119: ecx_debug.push(i_method_name);
1120: end if;
1121: if(l_statementEnabled) then
1122: ecx_debug.log(l_statement,'i_document_number',i_document_number,i_method_name);
1123: ecx_debug.log(l_statement,'i_tp_detail_id',i_tp_detail_id,i_method_name);
1124: end if;
1125:
1126: begin
1127: select es.standard_type standard_type,
1168: and eep.direction = 'OUT'
1169: and etd.tp_header_id = eth.tp_header_id;
1170: exception
1171: when others then
1172: ecx_debug.setErrorInfo(1,25,'ECX_NO_UNIQUE_TP_SETUP');
1173: raise ecx_utils.program_exit;
1174: end;
1175:
1176: if i_hub_user_id is not null
1191: where eh.hub_id = ehu.hub_id
1192: and ehu.hub_user_id = i_hub_user_id;
1193: exception
1194: when others then
1195: ecx_debug.setErrorInfo(1,25,'ECX_DELIVERY_HUB_NOT_SETUP');
1196: raise ecx_utils.program_exit;
1197: end;
1198: end if;
1199:
1198: end if;
1199:
1200: if i_destination_address is null
1201: then
1202: ecx_debug.setErrorInfo(1,25,'ECX_PROTOCOL_ADDR_NULL',
1203: 'p_tp_location_code', i_source_code,
1204: 'p_transaction_type', i_ext_type,
1205: 'p_transaction_subtype', i_ext_subtype,
1206: 'p_standard', i_standard_code);
1207:
1208: raise ecx_utils.program_exit;
1209: end if;
1210: if (l_statementEnabled) then
1211: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1212: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1208: raise ecx_utils.program_exit;
1209: end if;
1210: if (l_statementEnabled) then
1211: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1212: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1209: end if;
1210: if (l_statementEnabled) then
1211: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1212: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1210: if (l_statementEnabled) then
1211: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1212: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1211: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1212: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1212: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1213: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1214: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1215: ecx_debug.log(l_statement,'i_int_type', i_int_type,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1223: ecx_debug.log(l_statement,'i_party_site_id', i_party_site_id,i_method_name);
1216: ecx_debug.log(l_statement,'i_int_subtype', i_int_subtype,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1223: ecx_debug.log(l_statement,'i_party_site_id', i_party_site_id,i_method_name);
1224: ecx_debug.log(l_statement,'i_party_type', i_party_type,i_method_name);
1217: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1223: ecx_debug.log(l_statement,'i_party_site_id', i_party_site_id,i_method_name);
1224: ecx_debug.log(l_statement,'i_party_type', i_party_type,i_method_name);
1225: end if;
1218: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1223: ecx_debug.log(l_statement,'i_party_site_id', i_party_site_id,i_method_name);
1224: ecx_debug.log(l_statement,'i_party_type', i_party_type,i_method_name);
1225: end if;
1226: -- call ecx_out_wf_qh.enqueue with the correct parameters
1219: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1223: ecx_debug.log(l_statement,'i_party_site_id', i_party_site_id,i_method_name);
1224: ecx_debug.log(l_statement,'i_party_type', i_party_type,i_method_name);
1225: end if;
1226: -- call ecx_out_wf_qh.enqueue with the correct parameters
1227: wf_event_t.initialize(i_event);
1220: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1221: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1222: ecx_debug.log(l_statement,'i_party_id',i_party_id,i_method_name);
1223: ecx_debug.log(l_statement,'i_party_site_id', i_party_site_id,i_method_name);
1224: ecx_debug.log(l_statement,'i_party_type', i_party_type,i_method_name);
1225: end if;
1226: -- call ecx_out_wf_qh.enqueue with the correct parameters
1227: wf_event_t.initialize(i_event);
1228: i_event.addParameterToList('PARTY_TYPE', i_party_type);
1263:
1264: i_event.setFromAgent(i_from_agt);
1265:
1266: if(l_statementEnabled) then
1267: ecx_debug.log(l_statement,'Calling WF_EVENT.Send for Enqueue',i_method_name);
1268: end if;
1269: wf_event.send(i_event);
1270: ecx_errorlog.outbound_log(i_event);
1271:
1277: if (ecx_out_wf_qh.retmsg is not null) then
1278: --ecx_utils.error_type := 30;
1279: --ecx_utils.i_ret_code := ecx_out_wf_qh.retcode;
1280: --ecx_utils.i_errbuf := ecx_out_wf_qh.retmsg;
1281: ecx_debug.setErrorInfo(ecx_out_wf_qh.retcode,30,ecx_out_wf_qh.retmsg);
1282: if(l_statementEnabled) then
1283: ecx_debug.log(l_statement,ecx_debug.getMessage(ecx_utils.i_errbuf,
1284: ecx_utils.i_errparams),i_method_name); -- MLS
1285: end if;
1279: --ecx_utils.i_ret_code := ecx_out_wf_qh.retcode;
1280: --ecx_utils.i_errbuf := ecx_out_wf_qh.retmsg;
1281: ecx_debug.setErrorInfo(ecx_out_wf_qh.retcode,30,ecx_out_wf_qh.retmsg);
1282: if(l_statementEnabled) then
1283: ecx_debug.log(l_statement,ecx_debug.getMessage(ecx_utils.i_errbuf,
1284: ecx_utils.i_errparams),i_method_name); -- MLS
1285: end if;
1286: end if;
1287:
1285: end if;
1286: end if;
1287:
1288: if(l_statementEnabled) then
1289: ecx_debug.log(l_statement,'Routed MsgId',i_out_msgid,i_method_name);
1290: end if;
1291: if (l_procedureEnabled) then
1292: ecx_debug.pop(i_method_name);
1293: end if;
1288: if(l_statementEnabled) then
1289: ecx_debug.log(l_statement,'Routed MsgId',i_out_msgid,i_method_name);
1290: end if;
1291: if (l_procedureEnabled) then
1292: ecx_debug.pop(i_method_name);
1293: end if;
1294: exception
1295: WHEN ECX_UTILS.PROGRAM_EXIT THEN
1296: --dbms_lob.freetemporary(i_xmldoc);
1294: exception
1295: WHEN ECX_UTILS.PROGRAM_EXIT THEN
1296: --dbms_lob.freetemporary(i_xmldoc);
1297: if (l_procedureEnabled) then
1298: ecx_debug.pop(i_method_name);
1299: end if;
1300: raise ecx_utils.program_exit;
1301: when others then
1302: --dbms_lob.freetemporary(i_xmldoc);
1301: when others then
1302: --dbms_lob.freetemporary(i_xmldoc);
1303: if (ecx_out_wf_qh.retmsg is null AND ecx_out_wf_qh.retcode = 0)
1304: then
1305: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.PUT_ON_OUTBOUND');
1306: else
1307: --ecx_utils.i_ret_code := ecx_out_wf_qh.retcode;
1308: --ecx_utils.i_errbuf := ecx_out_wf_qh.retmsg;
1309: ecx_debug.setErrorInfo(ecx_out_wf_qh.retcode,30,ecx_out_wf_qh.retmsg);
1305: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.PUT_ON_OUTBOUND');
1306: else
1307: --ecx_utils.i_ret_code := ecx_out_wf_qh.retcode;
1308: --ecx_utils.i_errbuf := ecx_out_wf_qh.retmsg;
1309: ecx_debug.setErrorInfo(ecx_out_wf_qh.retcode,30,ecx_out_wf_qh.retmsg);
1310: end if;
1311: --ecx_utils.error_type := 30;
1312: if(l_unexpectedEnabled) then
1313: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,
1309: ecx_debug.setErrorInfo(ecx_out_wf_qh.retcode,30,ecx_out_wf_qh.retmsg);
1310: end if;
1311: --ecx_utils.error_type := 30;
1312: if(l_unexpectedEnabled) then
1313: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,
1314: ecx_utils.i_errparams),i_method_name); -- MLS
1315: end if;
1316: raise ecx_utils.program_exit;
1317: end put_on_outbound;
1356: l_retmsg Varchar2(200) := null;
1357:
1358: begin
1359: if (l_procedureEnabled) then
1360: ecx_debug.push(i_method_name);
1361: end if;
1362: if(l_statementEnabled) then
1363: ecx_debug.log(l_statement,'i_document_number',i_document_number,i_method_name);
1364: ecx_debug.log(l_statement,'i_tp_detail_id',i_tp_detail_id,i_method_name);
1359: if (l_procedureEnabled) then
1360: ecx_debug.push(i_method_name);
1361: end if;
1362: if(l_statementEnabled) then
1363: ecx_debug.log(l_statement,'i_document_number',i_document_number,i_method_name);
1364: ecx_debug.log(l_statement,'i_tp_detail_id',i_tp_detail_id,i_method_name);
1365: end if;
1366:
1367: begin
1360: ecx_debug.push(i_method_name);
1361: end if;
1362: if(l_statementEnabled) then
1363: ecx_debug.log(l_statement,'i_document_number',i_document_number,i_method_name);
1364: ecx_debug.log(l_statement,'i_tp_detail_id',i_tp_detail_id,i_method_name);
1365: end if;
1366:
1367: begin
1368: select es.standard_type standard_type,
1395: and eep.ext_process_id = etd.ext_process_id;
1396:
1397: exception
1398: when others then
1399: ecx_debug.setErrorInfo(1,25,'ECX_NO_UNIQUE_TP_SETUP');
1400: raise ecx_utils.program_exit;
1401: end;
1402:
1403: if i_hub_user_id is not null
1419: and ehu.hub_user_id = i_hub_user_id;
1420:
1421: exception
1422: when others then
1423: ecx_debug.setErrorInfo(1,25,'ECX_DELIVERY_HUB_NOT_SETUP');
1424: if(l_unexpectedEnabled) then
1425: ecx_debug.log(l_unexpected,'ERROR', SQLERRM,i_method_name);
1426: end if;
1427: raise ecx_utils.program_exit;
1421: exception
1422: when others then
1423: ecx_debug.setErrorInfo(1,25,'ECX_DELIVERY_HUB_NOT_SETUP');
1424: if(l_unexpectedEnabled) then
1425: ecx_debug.log(l_unexpected,'ERROR', SQLERRM,i_method_name);
1426: end if;
1427: raise ecx_utils.program_exit;
1428: end;
1429: end if;
1430:
1431:
1432: if i_destination_address is null
1433: then
1434: ecx_debug.setErrorInfo(1,25,'ECX_PROTOCOL_ADDR_NULL',
1435: 'p_tp_location_code', i_source_code,
1436: 'p_transaction_type', i_ext_type,
1437: 'p_transaction_subtype', i_ext_subtype,
1438: 'p_standard', i_standard_code);
1452: then
1453: --ecx_utils.i_ret_code := o_retcode;
1454: --ecx_utils.i_errbuf := o_retmsg;
1455: --ecx_utils.error_type := 30;
1456: ecx_debug.setErrorInfo(o_retcode,30,o_retmsg);
1457: raise ecx_utils.program_exit;
1458: end if;
1459: if(l_statementEnabled) then
1460: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1456: ecx_debug.setErrorInfo(o_retcode,30,o_retmsg);
1457: raise ecx_utils.program_exit;
1458: end if;
1459: if(l_statementEnabled) then
1460: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1461: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1457: raise ecx_utils.program_exit;
1458: end if;
1459: if(l_statementEnabled) then
1460: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1461: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1458: end if;
1459: if(l_statementEnabled) then
1460: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1461: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1459: if(l_statementEnabled) then
1460: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1461: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1460: ecx_debug.log(l_statement,'i_standard_type',i_standard_type,i_method_name);
1461: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1468: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1461: ecx_debug.log(l_statement,'i_standard_code',i_standard_code,i_method_name);
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1468: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1469: end if;
1462: ecx_debug.log(l_statement,'i_ext_type',i_ext_type,i_method_name);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1468: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1469: end if;
1470: --ecx_debug.log(3,'i_password',i_password);
1463: ecx_debug.log(l_statement,'i_ext_subtype',i_ext_subtype,i_method_name);
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1468: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1469: end if;
1470: --ecx_debug.log(3,'i_password',i_password);
1471:
1464: ecx_debug.log(l_statement,'i_source_code',i_source_code,i_method_name);
1465: ecx_debug.log(l_statement,'i_destination_code',i_destination_code,i_method_name);
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1468: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1469: end if;
1470: --ecx_debug.log(3,'i_password',i_password);
1471:
1472: v_message:=system.ecxmsg
1466: ecx_debug.log(l_statement,'i_destination_type',i_destination_type,i_method_name);
1467: ecx_debug.log(l_statement,'i_destination_address',i_destination_address,i_method_name);
1468: ecx_debug.log(l_statement,'i_username',i_username,i_method_name);
1469: end if;
1470: --ecx_debug.log(3,'i_password',i_password);
1471:
1472: v_message:=system.ecxmsg
1473: (
1474: i_standard_type,
1499: where eth.tp_header_id = etd.tp_header_id
1500: and etd.tp_detail_id = i_tp_detail_id;
1501: exception
1502: when others then
1503: ecx_debug.setErrorInfo(1,30, SQLERRM);
1504: raise ecx_utils.program_exit;
1505: end;
1506:
1507: v_message.party_type := i_party_type;
1547: );
1548:
1549: if (l_retcode = 1) then
1550: if(l_unexpectedEnabled) then
1551: ecx_debug.log(l_unexpected, l_retmsg,i_method_name);
1552: end if;
1553: elsif (l_retcode >= 2 ) then
1554: if(l_unexpectedEnabled) then
1555: ecx_debug.log(l_unexpected, l_retmsg,i_method_name);
1551: ecx_debug.log(l_unexpected, l_retmsg,i_method_name);
1552: end if;
1553: elsif (l_retcode >= 2 ) then
1554: if(l_unexpectedEnabled) then
1555: ecx_debug.log(l_unexpected, l_retmsg,i_method_name);
1556: end if;
1557: raise ecx_utils.program_exit;
1558: end if;
1559: end;
1561: -- maintain attachment mappings if this is a passthrough case
1562: ecx_attachment.remap_attachments(i_msgid);
1563:
1564: if(l_statementEnabled) then
1565: ecx_debug.log(l_statement,'Routed MsgId',i_msgid,i_method_name);
1566: end if;
1567: if (l_procedureEnabled) then
1568: ecx_debug.pop(i_method_name);
1569: end if;
1564: if(l_statementEnabled) then
1565: ecx_debug.log(l_statement,'Routed MsgId',i_msgid,i_method_name);
1566: end if;
1567: if (l_procedureEnabled) then
1568: ecx_debug.pop(i_method_name);
1569: end if;
1570: exception
1571: WHEN ECX_UTILS.PROGRAM_EXIT THEN
1572: i_hub_user_id := null;
1570: exception
1571: WHEN ECX_UTILS.PROGRAM_EXIT THEN
1572: i_hub_user_id := null;
1573: if (l_procedureEnabled) then
1574: ecx_debug.pop(i_method_name);
1575: end if;
1576: raise ecx_utils.program_exit;
1577: when others then
1578: i_hub_user_id := null;
1575: end if;
1576: raise ecx_utils.program_exit;
1577: when others then
1578: i_hub_user_id := null;
1579: ecx_debug.setErrorInfo(2,30, SQLERRM|| ' - ECX_INBOUND_TRIG.PUT_ON_OUTBOUND');
1580: if(l_unexpectedEnabled) then
1581: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
1582: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1583: end if;
1577: when others then
1578: i_hub_user_id := null;
1579: ecx_debug.setErrorInfo(2,30, SQLERRM|| ' - ECX_INBOUND_TRIG.PUT_ON_OUTBOUND');
1580: if(l_unexpectedEnabled) then
1581: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
1582: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1583: end if;
1584: raise ecx_utils.program_exit;
1585: end put_on_outbound;
1578: i_hub_user_id := null;
1579: ecx_debug.setErrorInfo(2,30, SQLERRM|| ' - ECX_INBOUND_TRIG.PUT_ON_OUTBOUND');
1580: if(l_unexpectedEnabled) then
1581: --ecx_debug.log(l_statement,ecx_utils.i_errbuf,i_method_name);
1582: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1583: end if;
1584: raise ecx_utils.program_exit;
1585: end put_on_outbound;
1586:
1605:
1606: begin
1607: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
1608: fnd_profile.get('AFLOG_MODULE',module);
1609: if ecx_debug.g_v_module_name is null then
1610: ecx_debug.module_enabled;
1611: end if;
1612:
1613: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
1606: begin
1607: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
1608: fnd_profile.get('AFLOG_MODULE',module);
1609: if ecx_debug.g_v_module_name is null then
1610: ecx_debug.module_enabled;
1611: end if;
1612:
1613: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
1614: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
1610: ecx_debug.module_enabled;
1611: end if;
1612:
1613: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
1614: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
1615: OR module='%')
1616: AND FND_LOG.G_CURRENT_RUNTIME_LEVEL <= FND_LOG.LEVEL_UNEXPECTED) then
1617: ecx_logging_enabled := true;
1618: end if;
1619: -- /logging enabled
1620:
1621: IF (ecx_logging_enabled ) THEN
1622: ecx_utils.getLogDirectory;
1623: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir, 'IN'||i_queue_name||'.log', 'in.'||i_queue_name||'.log');
1624: END IF;
1625:
1626: /* Assign local variables with the ecx_debug global variables*/
1627: l_procedure := ecx_debug.g_procedure;
1622: ecx_utils.getLogDirectory;
1623: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir, 'IN'||i_queue_name||'.log', 'in.'||i_queue_name||'.log');
1624: END IF;
1625:
1626: /* Assign local variables with the ecx_debug global variables*/
1627: l_procedure := ecx_debug.g_procedure;
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1623: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir, 'IN'||i_queue_name||'.log', 'in.'||i_queue_name||'.log');
1624: END IF;
1625:
1626: /* Assign local variables with the ecx_debug global variables*/
1627: l_procedure := ecx_debug.g_procedure;
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1624: END IF;
1625:
1626: /* Assign local variables with the ecx_debug global variables*/
1627: l_procedure := ecx_debug.g_procedure;
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1632: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1625:
1626: /* Assign local variables with the ecx_debug global variables*/
1627: l_procedure := ecx_debug.g_procedure;
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1632: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1633:
1626: /* Assign local variables with the ecx_debug global variables*/
1627: l_procedure := ecx_debug.g_procedure;
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1632: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1633:
1634: if (l_procedureEnabled) then
1627: l_procedure := ecx_debug.g_procedure;
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1632: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1633:
1634: if (l_procedureEnabled) then
1635: ecx_debug.push(i_method_name);
1628: l_statement := ecx_debug.g_statement;
1629: l_unexpected := ecx_debug.g_unexpected;
1630: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1632: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1633:
1634: if (l_procedureEnabled) then
1635: ecx_debug.push(i_method_name);
1636: end if;
1631: l_statementEnabled := ecx_debug.g_statementEnabled;
1632: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1633:
1634: if (l_procedureEnabled) then
1635: ecx_debug.push(i_method_name);
1636: end if;
1637:
1638: if(l_statementEnabled) then
1639: ecx_debug.log(l_statement,'i_queue_name',i_queue_name,i_method_name);
1635: ecx_debug.push(i_method_name);
1636: end if;
1637:
1638: if(l_statementEnabled) then
1639: ecx_debug.log(l_statement,'i_queue_name',i_queue_name,i_method_name);
1640: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
1641: end if;
1642:
1643: getmsg_from_queue(i_queue_name,v_msgid);
1636: end if;
1637:
1638: if(l_statementEnabled) then
1639: ecx_debug.log(l_statement,'i_queue_name',i_queue_name,i_method_name);
1640: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
1641: end if;
1642:
1643: getmsg_from_queue(i_queue_name,v_msgid);
1644:
1644:
1645: --validate_message( v_msgid, i_debug_level,i_trigger_id);
1646:
1647: if (l_procedureEnabled) then
1648: ecx_debug.pop(i_method_name);
1649: end if;
1650: IF (ecx_logging_enabled ) THEN
1651: ecx_debug.print_log;
1652: ecx_debug.disable_debug;
1647: if (l_procedureEnabled) then
1648: ecx_debug.pop(i_method_name);
1649: end if;
1650: IF (ecx_logging_enabled ) THEN
1651: ecx_debug.print_log;
1652: ecx_debug.disable_debug;
1653: END IF;
1654:
1655: exception
1648: ecx_debug.pop(i_method_name);
1649: end if;
1650: IF (ecx_logging_enabled ) THEN
1651: ecx_debug.print_log;
1652: ecx_debug.disable_debug;
1653: END IF;
1654:
1655: exception
1656: when ecx_utils.program_exit then
1654:
1655: exception
1656: when ecx_utils.program_exit then
1657: if(l_unexpectedEnabled) then
1658: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1659: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1660: end if;
1661: IF (ecx_logging_enabled ) THEN
1662: ecx_debug.print_log;
1655: exception
1656: when ecx_utils.program_exit then
1657: if(l_unexpectedEnabled) then
1658: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1659: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1660: end if;
1661: IF (ecx_logging_enabled ) THEN
1662: ecx_debug.print_log;
1663: ecx_debug.disable_debug;
1658: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1659: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1660: end if;
1661: IF (ecx_logging_enabled ) THEN
1662: ecx_debug.print_log;
1663: ecx_debug.disable_debug;
1664: END IF;
1665: when others then
1666: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_QUEUE';
1659: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1660: end if;
1661: IF (ecx_logging_enabled ) THEN
1662: ecx_debug.print_log;
1663: ecx_debug.disable_debug;
1664: END IF;
1665: when others then
1666: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_QUEUE';
1667: if(l_unexpectedEnabled) then
1664: END IF;
1665: when others then
1666: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_QUEUE';
1667: if(l_unexpectedEnabled) then
1668: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1669: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1670: end if;
1671: IF (ecx_logging_enabled ) THEN
1672: ecx_debug.print_log;
1665: when others then
1666: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_QUEUE';
1667: if(l_unexpectedEnabled) then
1668: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1669: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1670: end if;
1671: IF (ecx_logging_enabled ) THEN
1672: ecx_debug.print_log;
1673: ecx_debug.disable_debug;
1668: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1669: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1670: end if;
1671: IF (ecx_logging_enabled ) THEN
1672: ecx_debug.print_log;
1673: ecx_debug.disable_debug;
1674: END IF;
1675: end processmsg_from_queue;
1676:
1669: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1670: end if;
1671: IF (ecx_logging_enabled ) THEN
1672: ecx_debug.print_log;
1673: ecx_debug.disable_debug;
1674: END IF;
1675: end processmsg_from_queue;
1676:
1677:
1694: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
1695: fnd_profile.get('AFLOG_MODULE',module);
1696:
1697: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
1698: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
1699: OR module='%')
1700: AND FND_LOG.G_CURRENT_RUNTIME_LEVEL <= FND_LOG.LEVEL_UNEXPECTED) then
1701: ecx_logging_enabled := true;
1702: end if;
1704:
1705: IF (ecx_logging_enabled ) THEN
1706: --get the Log directory from the Profile Option.
1707: ecx_utils.getLogDirectory;
1708: ecx_debug.enable_debug_new(i_debug_level, ecx_utils.g_logdir, 'IN' ||i_msgid||'.log', 'in.'||i_msgid||'.log');
1709: END IF;
1710:
1711: /* Assign local variables with the ecx_debug global variables*/
1712: l_procedure := ecx_debug.g_procedure;
1707: ecx_utils.getLogDirectory;
1708: ecx_debug.enable_debug_new(i_debug_level, ecx_utils.g_logdir, 'IN' ||i_msgid||'.log', 'in.'||i_msgid||'.log');
1709: END IF;
1710:
1711: /* Assign local variables with the ecx_debug global variables*/
1712: l_procedure := ecx_debug.g_procedure;
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1708: ecx_debug.enable_debug_new(i_debug_level, ecx_utils.g_logdir, 'IN' ||i_msgid||'.log', 'in.'||i_msgid||'.log');
1709: END IF;
1710:
1711: /* Assign local variables with the ecx_debug global variables*/
1712: l_procedure := ecx_debug.g_procedure;
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1709: END IF;
1710:
1711: /* Assign local variables with the ecx_debug global variables*/
1712: l_procedure := ecx_debug.g_procedure;
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1717: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1710:
1711: /* Assign local variables with the ecx_debug global variables*/
1712: l_procedure := ecx_debug.g_procedure;
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1717: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1718:
1711: /* Assign local variables with the ecx_debug global variables*/
1712: l_procedure := ecx_debug.g_procedure;
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1717: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1718:
1719: if (l_procedureEnabled) then
1712: l_procedure := ecx_debug.g_procedure;
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1717: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1718:
1719: if (l_procedureEnabled) then
1720: ecx_debug.push(i_method_name);
1713: l_statement := ecx_debug.g_statement;
1714: l_unexpected := ecx_debug.g_unexpected;
1715: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1717: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1718:
1719: if (l_procedureEnabled) then
1720: ecx_debug.push(i_method_name);
1721: end if;
1716: l_statementEnabled := ecx_debug.g_statementEnabled;
1717: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1718:
1719: if (l_procedureEnabled) then
1720: ecx_debug.push(i_method_name);
1721: end if;
1722:
1723: if(l_statementEnabled) then
1724: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1720: ecx_debug.push(i_method_name);
1721: end if;
1722:
1723: if(l_statementEnabled) then
1724: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1725: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
1726: end if;
1727:
1728: --validate_message( i_msgid, i_debug_level,i_trigger_id);
1721: end if;
1722:
1723: if(l_statementEnabled) then
1724: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1725: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
1726: end if;
1727:
1728: --validate_message( i_msgid, i_debug_level,i_trigger_id);
1729:
1727:
1728: --validate_message( i_msgid, i_debug_level,i_trigger_id);
1729:
1730: if (l_procedureEnabled) then
1731: ecx_debug.pop(i_method_name);
1732: end if;
1733:
1734: IF (ecx_logging_enabled ) THEN
1735: ecx_debug.print_log;
1731: ecx_debug.pop(i_method_name);
1732: end if;
1733:
1734: IF (ecx_logging_enabled ) THEN
1735: ecx_debug.print_log;
1736: ecx_debug.disable_debug;
1737: END IF;
1738:
1739: exception
1732: end if;
1733:
1734: IF (ecx_logging_enabled ) THEN
1735: ecx_debug.print_log;
1736: ecx_debug.disable_debug;
1737: END IF;
1738:
1739: exception
1740: when ecx_utils.program_exit then
1738:
1739: exception
1740: when ecx_utils.program_exit then
1741: if(l_unexpectedEnabled) then
1742: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1743: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1744: end if;
1745: IF (ecx_logging_enabled ) THEN
1746: ecx_debug.print_log;
1739: exception
1740: when ecx_utils.program_exit then
1741: if(l_unexpectedEnabled) then
1742: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1743: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1744: end if;
1745: IF (ecx_logging_enabled ) THEN
1746: ecx_debug.print_log;
1747: ecx_debug.disable_debug;
1742: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1743: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1744: end if;
1745: IF (ecx_logging_enabled ) THEN
1746: ecx_debug.print_log;
1747: ecx_debug.disable_debug;
1748: END IF;
1749:
1750: when others then
1743: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1744: end if;
1745: IF (ecx_logging_enabled ) THEN
1746: ecx_debug.print_log;
1747: ecx_debug.disable_debug;
1748: END IF;
1749:
1750: when others then
1751: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_TABLE';
1749:
1750: when others then
1751: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_TABLE';
1752: if(l_unexpectedEnabled) then
1753: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1754: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1755: end if;
1756:
1757: IF (ecx_logging_enabled ) THEN
1750: when others then
1751: ecx_utils.i_errbuf := SQLERRM || ' - ECX_INBOUND_TRIG.PROCESSMSG_FROM_TABLE';
1752: if(l_unexpectedEnabled) then
1753: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1754: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1755: end if;
1756:
1757: IF (ecx_logging_enabled ) THEN
1758: ecx_debug.print_log;
1754: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1755: end if;
1756:
1757: IF (ecx_logging_enabled ) THEN
1758: ecx_debug.print_log;
1759: ecx_debug.disable_debug;
1760: END IF;
1761: end processmsg_from_table;
1762:
1755: end if;
1756:
1757: IF (ecx_logging_enabled ) THEN
1758: ecx_debug.print_log;
1759: ecx_debug.disable_debug;
1760: END IF;
1761: end processmsg_from_table;
1762:
1763: /** New wrap validate message for use with BES
1836:
1837: close get_msg;
1838: ecx_utils.g_direction := 'IN';
1839: ecx_utils.g_logfile :=null;
1840: ecx_debug.g_v_module_name :='ecx.plsql.';
1841: ecx_utils.g_transaction_type := m_transaction_type;
1842: ecx_utils.g_transaction_subtype := m_transaction_subtype;
1843: ecx_utils.g_msgid := i_msgid;
1844: begin
1847: from ecx_standards
1848: where standard_code = m_message_standard
1849: and standard_type = nvl(m_message_type, 'XML');
1850: if(l_statementEnabled) then
1851: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
1852: end if;
1853: exception
1854: when others then
1855: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
1851: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
1852: end if;
1853: exception
1854: when others then
1855: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
1856: raise ecx_utils.program_exit;
1857: end;
1858: ecx_debug.module_enabled;
1859: g_instlmode := wf_core.translate('WF_INSTALL');
1854: when others then
1855: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
1856: raise ecx_utils.program_exit;
1857: end;
1858: ecx_debug.module_enabled;
1859: g_instlmode := wf_core.translate('WF_INSTALL');
1860:
1861: if(g_instlmode = 'EMBEDDED')
1862: THEN
1862: THEN
1863: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
1864: fnd_profile.get('AFLOG_MODULE',module);
1865: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
1866: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
1867: OR module='%')
1868: AND FND_LOG.G_CURRENT_RUNTIME_LEVEL <= FND_LOG.LEVEL_UNEXPECTED) then
1869: ecx_logging_enabled := true;
1870: end if;
1903: p_aflog_module_name := p_aflog_module_name||ecx_utils.g_run_id;
1904: END IF;
1905: p_aflog_module_name := p_aflog_module_name||'.log';
1906:
1907: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, p_aflog_module_name);
1908: END IF;
1909:
1910: /* Assign local variables with the ecx_debug global variables*/
1911: l_procedure := ecx_debug.g_procedure;
1906:
1907: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, p_aflog_module_name);
1908: END IF;
1909:
1910: /* Assign local variables with the ecx_debug global variables*/
1911: l_procedure := ecx_debug.g_procedure;
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1907: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, p_aflog_module_name);
1908: END IF;
1909:
1910: /* Assign local variables with the ecx_debug global variables*/
1911: l_procedure := ecx_debug.g_procedure;
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1908: END IF;
1909:
1910: /* Assign local variables with the ecx_debug global variables*/
1911: l_procedure := ecx_debug.g_procedure;
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1916: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1909:
1910: /* Assign local variables with the ecx_debug global variables*/
1911: l_procedure := ecx_debug.g_procedure;
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1916: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1917:
1910: /* Assign local variables with the ecx_debug global variables*/
1911: l_procedure := ecx_debug.g_procedure;
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1916: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1917:
1918: if (l_procedureEnabled) then
1911: l_procedure := ecx_debug.g_procedure;
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1916: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1917:
1918: if (l_procedureEnabled) then
1919: ecx_debug.push(i_method_name);
1912: l_statement := ecx_debug.g_statement;
1913: l_unexpected := ecx_debug.g_unexpected;
1914: l_procedureEnabled := ecx_debug.g_procedureEnabled;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1916: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1917:
1918: if (l_procedureEnabled) then
1919: ecx_debug.push(i_method_name);
1920: end if;
1915: l_statementEnabled := ecx_debug.g_statementEnabled;
1916: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
1917:
1918: if (l_procedureEnabled) then
1919: ecx_debug.push(i_method_name);
1920: end if;
1921:
1922: if(l_statementEnabled) then
1923: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1919: ecx_debug.push(i_method_name);
1920: end if;
1921:
1922: if(l_statementEnabled) then
1923: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1924: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
1925: end if;
1926: ecx_utils.g_document_id :=m_internal_control_number;
1927:
1920: end if;
1921:
1922: if(l_statementEnabled) then
1923: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
1924: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
1925: end if;
1926: ecx_utils.g_document_id :=m_internal_control_number;
1927:
1928: IF (ecx_logging_enabled and g_instlmode = 'STANDALONE') THEN
1941: from ecx_standards
1942: where standard_code = m_message_standard
1943: and standard_type = nvl(m_message_type, 'XML');
1944: if(l_statementEnabled) then
1945: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
1946: end if;
1947: exception
1948: when others then
1949: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
1945: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
1946: end if;
1947: exception
1948: when others then
1949: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
1950: raise ecx_utils.program_exit;
1951: enid;*/
1952: validate_message
1953: (
1962: m_message_type
1963: );
1964:
1965: if (l_procedureEnabled) then
1966: ecx_debug.pop(i_method_name);
1967: end if;
1968: IF (ecx_logging_enabled ) THEN
1969: ecx_debug.print_log;
1970: ecx_debug.disable_debug;
1965: if (l_procedureEnabled) then
1966: ecx_debug.pop(i_method_name);
1967: end if;
1968: IF (ecx_logging_enabled ) THEN
1969: ecx_debug.print_log;
1970: ecx_debug.disable_debug;
1971: END IF;
1972:
1973: exception
1966: ecx_debug.pop(i_method_name);
1967: end if;
1968: IF (ecx_logging_enabled ) THEN
1969: ecx_debug.print_log;
1970: ecx_debug.disable_debug;
1971: END IF;
1972:
1973: exception
1974: when ecx_utils.program_exit then
1973: exception
1974: when ecx_utils.program_exit then
1975: --ecx_utils.g_map_id := -1;
1976: if(l_unexpectedEnabled) then
1977: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1978: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1979: end if;
1980: if (l_procedureEnabled) then
1981: ecx_debug.pop(i_method_name);
1974: when ecx_utils.program_exit then
1975: --ecx_utils.g_map_id := -1;
1976: if(l_unexpectedEnabled) then
1977: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1978: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1979: end if;
1980: if (l_procedureEnabled) then
1981: ecx_debug.pop(i_method_name);
1982: end if;
1977: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
1978: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
1979: end if;
1980: if (l_procedureEnabled) then
1981: ecx_debug.pop(i_method_name);
1982: end if;
1983:
1984: IF (ecx_logging_enabled ) THEN
1985: ecx_debug.print_log;
1981: ecx_debug.pop(i_method_name);
1982: end if;
1983:
1984: IF (ecx_logging_enabled ) THEN
1985: ecx_debug.print_log;
1986: ecx_debug.disable_debug;
1987: END IF;
1988:
1989: raise;
1982: end if;
1983:
1984: IF (ecx_logging_enabled ) THEN
1985: ecx_debug.print_log;
1986: ecx_debug.disable_debug;
1987: END IF;
1988:
1989: raise;
1990: when msg_not_found then
1988:
1989: raise;
1990: when msg_not_found then
1991: --ecx_utils.g_map_id := -1;
1992: ecx_debug.setErrorInfo(1,30,'ECX_MSGID_NOT_FOUND',
1993: 'p_msgid',
1994: i_msgid);
1995: close get_msg;
1996: raise;
1995: close get_msg;
1996: raise;
1997: when others then
1998: --ecx_utils.g_map_id := -1;
1999: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2000: if(l_unexpectedEnabled) then
2001: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2002: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2003: end if;
1997: when others then
1998: --ecx_utils.g_map_id := -1;
1999: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2000: if(l_unexpectedEnabled) then
2001: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2002: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2003: end if;
2004: if (l_procedureEnabled) then
2005: ecx_debug.pop(i_method_name);
1998: --ecx_utils.g_map_id := -1;
1999: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2000: if(l_unexpectedEnabled) then
2001: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2002: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2003: end if;
2004: if (l_procedureEnabled) then
2005: ecx_debug.pop(i_method_name);
2006: end if;
2001: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2002: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2003: end if;
2004: if (l_procedureEnabled) then
2005: ecx_debug.pop(i_method_name);
2006: end if;
2007:
2008: IF (ecx_logging_enabled ) THEN
2009: ecx_debug.print_log;
2005: ecx_debug.pop(i_method_name);
2006: end if;
2007:
2008: IF (ecx_logging_enabled ) THEN
2009: ecx_debug.print_log;
2010: ecx_debug.disable_debug;
2011: END IF;
2012:
2013: raise;
2006: end if;
2007:
2008: IF (ecx_logging_enabled ) THEN
2009: ecx_debug.print_log;
2010: ecx_debug.disable_debug;
2011: END IF;
2012:
2013: raise;
2014: end wrap_validate_message;
2071: module varchar2(2000);
2072:
2073: begin
2074: ecx_utils.g_logfile :=null;
2075: ecx_debug.g_v_module_name :='ecx.plsql.';
2076: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
2077: fnd_profile.get('AFLOG_MODULE',module);
2078: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
2079: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
2075: ecx_debug.g_v_module_name :='ecx.plsql.';
2076: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
2077: fnd_profile.get('AFLOG_MODULE',module);
2078: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
2079: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
2080: OR module='%')
2081: AND FND_LOG.G_CURRENT_RUNTIME_LEVEL <= FND_LOG.LEVEL_UNEXPECTED) then
2082: ecx_logging_enabled := true;
2083: end if;
2132: p_aflog_module_name := p_aflog_module_name||ecx_utils.g_run_id;
2133: END IF;
2134: p_aflog_module_name := p_aflog_module_name||'.log';
2135:
2136: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, p_aflog_module_name);
2137: END IF;
2138:
2139: /* Assign local variables with the ecx_debug global variables*/
2140: l_procedure := ecx_debug.g_procedure;
2135:
2136: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, p_aflog_module_name);
2137: END IF;
2138:
2139: /* Assign local variables with the ecx_debug global variables*/
2140: l_procedure := ecx_debug.g_procedure;
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2136: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, p_aflog_module_name);
2137: END IF;
2138:
2139: /* Assign local variables with the ecx_debug global variables*/
2140: l_procedure := ecx_debug.g_procedure;
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2137: END IF;
2138:
2139: /* Assign local variables with the ecx_debug global variables*/
2140: l_procedure := ecx_debug.g_procedure;
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2145: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2138:
2139: /* Assign local variables with the ecx_debug global variables*/
2140: l_procedure := ecx_debug.g_procedure;
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2145: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2146:
2139: /* Assign local variables with the ecx_debug global variables*/
2140: l_procedure := ecx_debug.g_procedure;
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2145: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2146:
2147: if (l_procedureEnabled) then
2140: l_procedure := ecx_debug.g_procedure;
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2145: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2146:
2147: if (l_procedureEnabled) then
2148: ecx_debug.push(i_method_name);
2141: l_statement := ecx_debug.g_statement;
2142: l_unexpected := ecx_debug.g_unexpected;
2143: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2145: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2146:
2147: if (l_procedureEnabled) then
2148: ecx_debug.push(i_method_name);
2149: end if;
2144: l_statementEnabled := ecx_debug.g_statementEnabled;
2145: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2146:
2147: if (l_procedureEnabled) then
2148: ecx_debug.push(i_method_name);
2149: end if;
2150:
2151: if(l_statementEnabled) then
2152: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
2148: ecx_debug.push(i_method_name);
2149: end if;
2150:
2151: if(l_statementEnabled) then
2152: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
2153: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
2154: end if;
2155: ecx_utils.g_document_id :=m_internal_control_number;
2156:
2149: end if;
2150:
2151: if(l_statementEnabled) then
2152: ecx_debug.log(l_statement,'i_msgid',i_msgid,i_method_name);
2153: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
2154: end if;
2155: ecx_utils.g_document_id :=m_internal_control_number;
2156:
2157: IF (ecx_logging_enabled ) THEN
2170: from ecx_standards
2171: where standard_code = m_message_standard
2172: and standard_type = nvl(m_message_type, 'XML');
2173: if(l_statementEnabled) then
2174: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
2175: end if;
2176: exception
2177: when others then
2178: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
2174: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
2175: end if;
2176: exception
2177: when others then
2178: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
2179: raise ecx_utils.program_exit;
2180: end;
2181:
2182: validate_message
2192: m_message_type
2193: );
2194:
2195: if (l_procedureEnabled) then
2196: ecx_debug.pop(i_method_name);
2197: end if;
2198: IF (ecx_logging_enabled ) THEN
2199: ecx_debug.print_log;
2200: ecx_debug.disable_debug;
2195: if (l_procedureEnabled) then
2196: ecx_debug.pop(i_method_name);
2197: end if;
2198: IF (ecx_logging_enabled ) THEN
2199: ecx_debug.print_log;
2200: ecx_debug.disable_debug;
2201: END IF;
2202:
2203: commit;
2196: ecx_debug.pop(i_method_name);
2197: end if;
2198: IF (ecx_logging_enabled ) THEN
2199: ecx_debug.print_log;
2200: ecx_debug.disable_debug;
2201: END IF;
2202:
2203: commit;
2204: exception
2204: exception
2205: when ecx_utils.program_exit then
2206: --ecx_utils.g_map_id := -1;
2207: if(l_unexpectedEnabled) then
2208: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2209: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2210: end if;
2211: IF (ecx_logging_enabled ) THEN
2212: ecx_debug.print_log;
2205: when ecx_utils.program_exit then
2206: --ecx_utils.g_map_id := -1;
2207: if(l_unexpectedEnabled) then
2208: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2209: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2210: end if;
2211: IF (ecx_logging_enabled ) THEN
2212: ecx_debug.print_log;
2213: ecx_debug.disable_debug;
2208: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2209: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2210: end if;
2211: IF (ecx_logging_enabled ) THEN
2212: ecx_debug.print_log;
2213: ecx_debug.disable_debug;
2214: END IF;
2215: rollback;
2216: when msg_not_found then
2209: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2210: end if;
2211: IF (ecx_logging_enabled ) THEN
2212: ecx_debug.print_log;
2213: ecx_debug.disable_debug;
2214: END IF;
2215: rollback;
2216: when msg_not_found then
2217: --ecx_utils.g_map_id := -1;
2214: END IF;
2215: rollback;
2216: when msg_not_found then
2217: --ecx_utils.g_map_id := -1;
2218: ecx_debug.setErrorInfo(1,30,'ECX_MSGID_NOT_FOUND',
2219: 'p_msgid',
2220: i_msgid);
2221: close get_msg;
2222: rollback;
2221: close get_msg;
2222: rollback;
2223: when others then
2224: --ecx_utils.g_map_id := -1;
2225: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2226: if(l_unexpectedEnabled) then
2227: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2228: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2229: end if;
2223: when others then
2224: --ecx_utils.g_map_id := -1;
2225: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2226: if(l_unexpectedEnabled) then
2227: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2228: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2229: end if;
2230: IF (ecx_logging_enabled ) THEN
2231: ecx_debug.print_log;
2224: --ecx_utils.g_map_id := -1;
2225: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2226: if(l_unexpectedEnabled) then
2227: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2228: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2229: end if;
2230: IF (ecx_logging_enabled ) THEN
2231: ecx_debug.print_log;
2232: ecx_debug.disable_debug;
2227: --ecx_debug.log(l_unexpected,ecx_utils.i_errbuf,i_method_name);
2228: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2229: end if;
2230: IF (ecx_logging_enabled ) THEN
2231: ecx_debug.print_log;
2232: ecx_debug.disable_debug;
2233: END IF;
2234:
2235: rollback;
2228: ecx_debug.log(l_unexpected,ecx_debug.getMessage(ecx_utils.i_errbuf,ecx_utils.i_errparams),i_method_name);
2229: end if;
2230: IF (ecx_logging_enabled ) THEN
2231: ecx_debug.print_log;
2232: ecx_debug.disable_debug;
2233: END IF;
2234:
2235: rollback;
2236: end wrap_validate_message;
2270: THEN
2271: fnd_profile.get('AFLOG_ENABLED',logging_enabled);
2272: fnd_profile.get('AFLOG_MODULE',module);
2273: if(logging_enabled = 'Y' AND ((lower(module) like 'ecx%'
2274: AND instr(lower(ecx_debug.g_v_module_name),rtrim(lower(module),'%'))> 0)
2275: OR module='%')
2276: AND FND_LOG.G_CURRENT_RUNTIME_LEVEL <= FND_LOG.LEVEL_UNEXPECTED) then
2277: ecx_logging_enabled := true;
2278: end if;
2298: END IF;
2299:
2300: IF g_instlmode = 'EMBEDDED' THEN
2301: IF (ecx_logging_enabled ) THEN
2302: i_log_file := ecx_debug.g_sqlprefix || 'in.'||ecx_utils.g_run_id||'.log';
2303: ELSE
2304: i_log_file := 'Please ensure that FND-Logging is enabled for module '||ecx_debug.g_sqlprefix||'%';
2305: END IF;
2306: ELSE
2300: IF g_instlmode = 'EMBEDDED' THEN
2301: IF (ecx_logging_enabled ) THEN
2302: i_log_file := ecx_debug.g_sqlprefix || 'in.'||ecx_utils.g_run_id||'.log';
2303: ELSE
2304: i_log_file := 'Please ensure that FND-Logging is enabled for module '||ecx_debug.g_sqlprefix||'%';
2305: END IF;
2306: ELSE
2307: IF (ecx_logging_enabled ) THEN
2308: i_log_file := ecx_utils.g_logdir||'/'||i_logfile;
2311: END IF;
2312: END IF;
2313:
2314: IF (ecx_logging_enabled ) THEN
2315: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, 'in.'||ecx_utils.g_run_id||'.log');
2316: END IF;
2317:
2318: /* Assign local variables with the ecx_debug global variables*/
2319: l_procedure := ecx_debug.g_procedure;
2314: IF (ecx_logging_enabled ) THEN
2315: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, 'in.'||ecx_utils.g_run_id||'.log');
2316: END IF;
2317:
2318: /* Assign local variables with the ecx_debug global variables*/
2319: l_procedure := ecx_debug.g_procedure;
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2315: ecx_debug.enable_debug_new(i_debug_level,ecx_utils.g_logdir,i_logfile, 'in.'||ecx_utils.g_run_id||'.log');
2316: END IF;
2317:
2318: /* Assign local variables with the ecx_debug global variables*/
2319: l_procedure := ecx_debug.g_procedure;
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2316: END IF;
2317:
2318: /* Assign local variables with the ecx_debug global variables*/
2319: l_procedure := ecx_debug.g_procedure;
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2324: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2317:
2318: /* Assign local variables with the ecx_debug global variables*/
2319: l_procedure := ecx_debug.g_procedure;
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2324: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2325:
2318: /* Assign local variables with the ecx_debug global variables*/
2319: l_procedure := ecx_debug.g_procedure;
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2324: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2325:
2326: if (l_procedureEnabled) then
2319: l_procedure := ecx_debug.g_procedure;
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2324: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2325:
2326: if (l_procedureEnabled) then
2327: ecx_debug.push(i_method_name);
2320: l_statement := ecx_debug.g_statement;
2321: l_unexpected := ecx_debug.g_unexpected;
2322: l_procedureEnabled := ecx_debug.g_procedureEnabled;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2324: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2325:
2326: if (l_procedureEnabled) then
2327: ecx_debug.push(i_method_name);
2328: end if;
2323: l_statementEnabled := ecx_debug.g_statementEnabled;
2324: l_unexpectedEnabled := ecx_debug.g_unexpectedEnabled;
2325:
2326: if (l_procedureEnabled) then
2327: ecx_debug.push(i_method_name);
2328: end if;
2329:
2330: if(l_statementEnabled) then
2331: ecx_debug.log(l_statement,'i_map_code',i_map_code,i_method_name);
2327: ecx_debug.push(i_method_name);
2328: end if;
2329:
2330: if(l_statementEnabled) then
2331: ecx_debug.log(l_statement,'i_map_code',i_map_code,i_method_name);
2332: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
2333: end if;
2334:
2335: IF (ecx_logging_enabled ) THEN
2328: end if;
2329:
2330: if(l_statementEnabled) then
2331: ecx_debug.log(l_statement,'i_map_code',i_map_code,i_method_name);
2332: ecx_debug.log(l_statement,'i_debug_level',i_debug_level,i_method_name);
2333: end if;
2334:
2335: IF (ecx_logging_enabled ) THEN
2336: ecx_utils.g_logfile :=i_logfile;
2343: from ecx_mappings
2344: where map_code = i_map_code;
2345: exception
2346: when others then
2347: ecx_debug.setErrorInfo(2,30,'ECX_MAP_NOT_FOUND',
2348: 'MAP_CODE',
2349: i_map_code);
2350: raise ecx_utils.program_exit;
2351: end;
2356: from ecx_standards
2357: where standard_code = i_message_standard
2358: and standard_type = nvl(i_message_type, 'XML');
2359: if(l_statementEnabled) then
2360: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
2361: end if;
2362: exception
2363: when others then
2364: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
2360: ecx_debug.log(l_statement,'Standard id',ecx_utils.g_standard_id,i_method_name);
2361: end if;
2362: exception
2363: when others then
2364: ecx_debug.setErrorInfo(1,30,'ECX_UNSUPPORTED_STANDARD');
2365: raise ecx_utils.program_exit;
2366: end;
2367:
2368: /*bug16442475 return status to notified and will set to complete from java*/
2375: i_payload => i_payload,
2376: i_no_routing => 'N'
2377: );
2378: if(l_statementEnabled) then
2379: ecx_debug.log(l_statement, 'ECX', 'Raised an event to process an xml at java layer',i_method_name);
2380: end if;
2381: /*set status to 0, other wise wffunction(caller of this function) will throw wf error for non zero error code */
2382: if(ecx_utils.i_ret_code = 10) then
2383: ecx_utils.i_ret_code := 0;
2382: if(ecx_utils.i_ret_code = 10) then
2383: ecx_utils.i_ret_code := 0;
2384: end if;
2385: else
2386: ecx_debug.log(l_statement,'==>i_map_id',i_map_id,i_method_name);
2387: processXMLData
2388: (
2389: i_map_id,
2390: i_payload,
2395: i_message_type
2396: );
2397: --ecx_utils.i_ret_code :=0;
2398: --ecx_utils.i_errbuf := 'XML Document Successfully processed';
2399: ecx_debug.setErrorInfo(0,10,'ECX_DOCUMENT_PROCESSED');
2400: end if;
2401:
2402: --ecx_utils.i_ret_code :=0;
2403: --ecx_utils.i_errbuf := 'XML Document Successfully processed';
2400: end if;
2401:
2402: --ecx_utils.i_ret_code :=0;
2403: --ecx_utils.i_errbuf := 'XML Document Successfully processed';
2404: ecx_debug.setErrorInfo(0,10,'ECX_DOCUMENT_PROCESSED');
2405:
2406: if(ecx_utils.i_ret_code = 0 ) then
2407: if(l_statementEnabled) then
2408: ecx_debug.log(l_statement, 'Ret Code',ecx_utils.i_ret_code,i_method_name);
2404: ecx_debug.setErrorInfo(0,10,'ECX_DOCUMENT_PROCESSED');
2405:
2406: if(ecx_utils.i_ret_code = 0 ) then
2407: if(l_statementEnabled) then
2408: ecx_debug.log(l_statement, 'Ret Code',ecx_utils.i_ret_code,i_method_name);
2409: ecx_debug.log(l_statement, 'Ret Msg ',ecx_utils.i_errbuf,i_method_name);
2410: end if;
2411: else
2412: if(l_unexpectedEnabled) then
2405:
2406: if(ecx_utils.i_ret_code = 0 ) then
2407: if(l_statementEnabled) then
2408: ecx_debug.log(l_statement, 'Ret Code',ecx_utils.i_ret_code,i_method_name);
2409: ecx_debug.log(l_statement, 'Ret Msg ',ecx_utils.i_errbuf,i_method_name);
2410: end if;
2411: else
2412: if(l_unexpectedEnabled) then
2413: ecx_debug.log(l_unexpected, 'Ret Code',ecx_utils.i_ret_code,i_method_name);
2409: ecx_debug.log(l_statement, 'Ret Msg ',ecx_utils.i_errbuf,i_method_name);
2410: end if;
2411: else
2412: if(l_unexpectedEnabled) then
2413: ecx_debug.log(l_unexpected, 'Ret Code',ecx_utils.i_ret_code,i_method_name);
2414: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_utils.i_errbuf,i_method_name);
2415: end if;
2416: end if;
2417:
2410: end if;
2411: else
2412: if(l_unexpectedEnabled) then
2413: ecx_debug.log(l_unexpected, 'Ret Code',ecx_utils.i_ret_code,i_method_name);
2414: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_utils.i_errbuf,i_method_name);
2415: end if;
2416: end if;
2417:
2418: if (l_procedureEnabled) then
2415: end if;
2416: end if;
2417:
2418: if (l_procedureEnabled) then
2419: ecx_debug.pop(i_method_name);
2420: end if;
2421:
2422: IF (ecx_logging_enabled ) THEN
2423: ecx_debug.print_log;
2419: ecx_debug.pop(i_method_name);
2420: end if;
2421:
2422: IF (ecx_logging_enabled ) THEN
2423: ecx_debug.print_log;
2424: ecx_debug.disable_debug;
2425: END IF;
2426:
2427: i_ret_code := ecx_utils.i_ret_code;
2420: end if;
2421:
2422: IF (ecx_logging_enabled ) THEN
2423: ecx_debug.print_log;
2424: ecx_debug.disable_debug;
2425: END IF;
2426:
2427: i_ret_code := ecx_utils.i_ret_code;
2428: i_errbuf := ecx_utils.i_errbuf;
2431: when ecx_utils.program_exit then
2432: --dbms_lob.freetemporary(o_payload);
2433: --ecx_utils.g_map_id := -1;
2434: if(l_unexpectedEnabled) then
2435: ecx_debug.log(l_unexpected,'Ret Code',ecx_utils.i_ret_code,i_method_name);
2436: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2437: ecx_utils.i_errparams),i_method_name);
2438: end if;
2439: if (l_procedureEnabled) then
2432: --dbms_lob.freetemporary(o_payload);
2433: --ecx_utils.g_map_id := -1;
2434: if(l_unexpectedEnabled) then
2435: ecx_debug.log(l_unexpected,'Ret Code',ecx_utils.i_ret_code,i_method_name);
2436: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2437: ecx_utils.i_errparams),i_method_name);
2438: end if;
2439: if (l_procedureEnabled) then
2440: ecx_debug.pop(i_method_name);
2436: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2437: ecx_utils.i_errparams),i_method_name);
2438: end if;
2439: if (l_procedureEnabled) then
2440: ecx_debug.pop(i_method_name);
2441: end if;
2442: IF (ecx_logging_enabled ) THEN
2443: ecx_debug.print_log;
2444: ecx_debug.disable_debug;
2439: if (l_procedureEnabled) then
2440: ecx_debug.pop(i_method_name);
2441: end if;
2442: IF (ecx_logging_enabled ) THEN
2443: ecx_debug.print_log;
2444: ecx_debug.disable_debug;
2445: END IF;
2446: i_ret_code := ecx_utils.i_ret_code;
2447: i_errbuf := ecx_utils.i_errbuf;
2440: ecx_debug.pop(i_method_name);
2441: end if;
2442: IF (ecx_logging_enabled ) THEN
2443: ecx_debug.print_log;
2444: ecx_debug.disable_debug;
2445: END IF;
2446: i_ret_code := ecx_utils.i_ret_code;
2447: i_errbuf := ecx_utils.i_errbuf;
2448:
2448:
2449: when others then
2450: --dbms_lob.freetemporary(o_payload);
2451: --ecx_utils.g_map_id := -1;
2452: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2453: if(l_unexpectedEnabled) then
2454: ecx_debug.log(l_unexpected,'Ret Code',ecx_utils.i_ret_code,i_method_name);
2455: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2456: ecx_utils.i_errparams),i_method_name);
2450: --dbms_lob.freetemporary(o_payload);
2451: --ecx_utils.g_map_id := -1;
2452: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2453: if(l_unexpectedEnabled) then
2454: ecx_debug.log(l_unexpected,'Ret Code',ecx_utils.i_ret_code,i_method_name);
2455: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2456: ecx_utils.i_errparams),i_method_name);
2457: end if;
2458: if (l_procedureEnabled) then
2451: --ecx_utils.g_map_id := -1;
2452: ecx_debug.setErrorInfo(2,30,SQLERRM || ' - ECX_INBOUND_TRIG.WRAP_VALIDATE_MESSAGE');
2453: if(l_unexpectedEnabled) then
2454: ecx_debug.log(l_unexpected,'Ret Code',ecx_utils.i_ret_code,i_method_name);
2455: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2456: ecx_utils.i_errparams),i_method_name);
2457: end if;
2458: if (l_procedureEnabled) then
2459: ecx_debug.pop(i_method_name);
2455: ecx_debug.log(l_unexpected, 'Ret Msg ',ecx_debug.getMessage(ecx_utils.i_errbuf,
2456: ecx_utils.i_errparams),i_method_name);
2457: end if;
2458: if (l_procedureEnabled) then
2459: ecx_debug.pop(i_method_name);
2460: end if;
2461: IF (ecx_logging_enabled ) THEN
2462: ecx_debug.print_log;
2463: ecx_debug.disable_debug;
2458: if (l_procedureEnabled) then
2459: ecx_debug.pop(i_method_name);
2460: end if;
2461: IF (ecx_logging_enabled ) THEN
2462: ecx_debug.print_log;
2463: ecx_debug.disable_debug;
2464: END IF;
2465: i_ret_code := ecx_utils.i_ret_code;
2466: i_errbuf := ecx_utils.i_errbuf;
2459: ecx_debug.pop(i_method_name);
2460: end if;
2461: IF (ecx_logging_enabled ) THEN
2462: ecx_debug.print_log;
2463: ecx_debug.disable_debug;
2464: END IF;
2465: i_ret_code := ecx_utils.i_ret_code;
2466: i_errbuf := ecx_utils.i_errbuf;
2467: end processXML;
2485: begin
2486: /* open c_ecx_trigger_id;
2487: fetch c_ecx_trigger_id into i_trigger_id;
2488: close c_ecx_trigger_id;*/
2489: ecx_debug.setErrorInfo(10,10,'ECX_REPROCESSING_MESSAGE');
2490: /* ecx_errorlog.inbound_trigger
2491: (
2492: i_trigger_id,
2493: i_msgid,
2504: i_msgid,
2505: i_debug_level
2506: );
2507:
2508: ecx_debug.setErrorInfo(0,10,'ECX_MESSAGE_REPROCESSED');
2509: select process_id into i_process_id from ecx_inbound_logs where msgid=i_msgid;
2510: if(i_process_id is null) -- means TP setup wrong. Message never got into transaction queue.
2511: then
2512: return;
2524: ecx_utils.g_logfile := null;
2525: end;
2526:
2527: --Changed for MLS
2528: ecx_debug.setErrorInfo(0,10,'ECX_MESSAGE_REPROCESSED');
2529: i_retcode := ecx_utils.i_ret_code;
2530: i_errbuf := ecx_utils.i_errbuf;
2531: exception
2532: when others then
2559: l_event_key := TO_CHAR(sysdate,'ddmmhhmiss');
2560: end if;
2561:
2562: if(l_statementEnabled) then
2563: ecx_debug.log(l_statement, 'ECX', 'Raising an event to processing an xml at middle tier',l_method_name);
2564: ecx_debug.log(l_statement, 'Event Name',l_event_name,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2560: end if;
2561:
2562: if(l_statementEnabled) then
2563: ecx_debug.log(l_statement, 'ECX', 'Raising an event to processing an xml at middle tier',l_method_name);
2564: ecx_debug.log(l_statement, 'Event Name',l_event_name,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2561:
2562: if(l_statementEnabled) then
2563: ecx_debug.log(l_statement, 'ECX', 'Raising an event to processing an xml at middle tier',l_method_name);
2564: ecx_debug.log(l_statement, 'Event Name',l_event_name,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2562: if(l_statementEnabled) then
2563: ecx_debug.log(l_statement, 'ECX', 'Raising an event to processing an xml at middle tier',l_method_name);
2564: ecx_debug.log(l_statement, 'Event Name',l_event_name,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2563: ecx_debug.log(l_statement, 'ECX', 'Raising an event to processing an xml at middle tier',l_method_name);
2564: ecx_debug.log(l_statement, 'Event Name',l_event_name,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2564: ecx_debug.log(l_statement, 'Event Name',l_event_name,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2565: ecx_debug.log(l_statement, 'Event Key',l_event_key,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2573: ecx_debug.log(l_statement, 'MSGID', i_msgid,l_method_name);
2566: ecx_debug.log(l_statement, 'LOGFILE', ecx_utils.g_logfile,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2573: ecx_debug.log(l_statement, 'MSGID', i_msgid,l_method_name);
2574: ecx_debug.log(l_statement, 'i_no_routing', i_no_routing,l_method_name);
2567: ecx_debug.log(l_statement, 'ecx_utils.g_item_type',ecx_utils.g_item_type,l_method_name);
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2573: ecx_debug.log(l_statement, 'MSGID', i_msgid,l_method_name);
2574: ecx_debug.log(l_statement, 'i_no_routing', i_no_routing,l_method_name);
2575: end if;
2568: ecx_debug.log(l_statement, 'ITEM_TYPE', ecx_utils.g_item_type,l_method_name);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2573: ecx_debug.log(l_statement, 'MSGID', i_msgid,l_method_name);
2574: ecx_debug.log(l_statement, 'i_no_routing', i_no_routing,l_method_name);
2575: end if;
2576: wf_event_t.initialize(l_event);
2569: ecx_debug.log(l_statement, 'ITEM_KEY', ecx_utils.g_item_key,l_method_name);
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2573: ecx_debug.log(l_statement, 'MSGID', i_msgid,l_method_name);
2574: ecx_debug.log(l_statement, 'i_no_routing', i_no_routing,l_method_name);
2575: end if;
2576: wf_event_t.initialize(l_event);
2577: if (l_msg_id_null = 'N') then
2570: ecx_debug.log(l_statement, 'ACTIVITY_ID', ecx_utils.g_activity_id,l_method_name);
2571: ecx_debug.log(l_statement, 'DOCUMENT_ID', i_document_number,l_method_name);
2572: ecx_debug.log(l_statement, 'PROCESS_ID', l_process_id,l_method_name);
2573: ecx_debug.log(l_statement, 'MSGID', i_msgid,l_method_name);
2574: ecx_debug.log(l_statement, 'i_no_routing', i_no_routing,l_method_name);
2575: end if;
2576: wf_event_t.initialize(l_event);
2577: if (l_msg_id_null = 'N') then
2578: select process_id into l_process_id from ecx_inbound_logs where msgid=i_msgid;
2580: l_event.addParameterToList('ROUTING_ID', ecx_utils.g_routing_id);
2581: if(l_statementEnabled) then
2582: l_event.addParameterToList('STAMENT_LEVEL_ENABLED', 'Y');
2583: end if;
2584: ecx_debug.log(l_statement, 'ecx_utils.g_org_id',ecx_utils.g_org_id,l_method_name);
2585: l_event.addParameterToList('MSGID', i_msgid);
2586: l_event.addParameterToList('DOCUMENT_ID', i_document_number);
2587: l_event.addParameterToList('PROCESS_ID', l_process_id);
2588: l_event.addParameterToList('MAP_CODE', i_map_id);
2596: l_event.addParameterToList('ITEM_KEY', ecx_utils.g_item_key);
2597: l_event.addParameterToList('ACTIVITY_ID', ecx_utils.g_activity_id);
2598: l_event.addParameterToList('NO_ROUTING', i_no_routing);
2599: wf_event.raise( P_EVENT_NAME=>l_event_name , P_EVENT_KEY => l_event_key, p_event_data =>i_payload ,p_parameters => l_event.getparameterlist());
2600: ecx_debug.setErrorInfo(10, 10, 'Event(key:'||l_event_key ||') has been raised for messgae processing at java layer');
2601: end raiseEvent;
2602: /**
2603: * This api is to set the notified WF process function to error with name
2604: * and stack trace
2614: i_errorstack IN varchar2
2615: )as
2616: begin
2617: wf_core.clear;
2618: wf_core.token('ECX_ERRMSG',ecx_debug.getMessage(i_errmsg,i_errparams));
2619: wf_core.token('ECX_LOGFILE',i_logfile);
2620: begin
2621: if i_errcode = '1' then
2622: wf_core.raise('ECX_PROCESS_XMLERROR');