35: l_date DATE;
36: l_obj_ver NUMBER;
37:
38: BEGIN
39: --IBE_UTIL.enable_debug();
40: -- standard start of API savepoint
41: SAVEPOINT setOptInOutPreference;
42:
43: -- standard call to check for call compatibility
104: p_encoded => FND_API.G_FALSE,
105: p_count => x_msg_count,
106: p_data => x_msg_data
107: );
108: --IBE_UTIL.disable_debug();
109:
110: --standard exception catching for main body
111: EXCEPTION
112: WHEN FND_API.G_EXC_ERROR THEN
109:
110: --standard exception catching for main body
111: EXCEPTION
112: WHEN FND_API.G_EXC_ERROR THEN
113: --IBE_UTIL.enable_debug();
114:
115: ROLLBACK TO setOptInOutPreference;
116: x_return_status := FND_API.G_RET_STS_ERROR;
117: FND_MSG_PUB.count_and_get(
118: p_encoded => FND_API.G_FALSE,
119: p_count => x_msg_count,
120: p_data => x_msg_data
121: );
122: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
123: IBE_UTIL.debug('G_EXC_ERROR exception');
124: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
125: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
119: p_count => x_msg_count,
120: p_data => x_msg_data
121: );
122: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
123: IBE_UTIL.debug('G_EXC_ERROR exception');
124: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
125: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
127: IBE_UTIL.debug('error text : '|| SQLERRM);
120: p_data => x_msg_data
121: );
122: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
123: IBE_UTIL.debug('G_EXC_ERROR exception');
124: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
125: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
127: IBE_UTIL.debug('error text : '|| SQLERRM);
128: END IF;
121: );
122: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
123: IBE_UTIL.debug('G_EXC_ERROR exception');
124: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
125: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
127: IBE_UTIL.debug('error text : '|| SQLERRM);
128: END IF;
129:
122: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
123: IBE_UTIL.debug('G_EXC_ERROR exception');
124: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
125: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
127: IBE_UTIL.debug('error text : '|| SQLERRM);
128: END IF;
129:
130: --IBE_UTIL.disable_debug();
123: IBE_UTIL.debug('G_EXC_ERROR exception');
124: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
125: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
127: IBE_UTIL.debug('error text : '|| SQLERRM);
128: END IF;
129:
130: --IBE_UTIL.disable_debug();
131:
126: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
127: IBE_UTIL.debug('error text : '|| SQLERRM);
128: END IF;
129:
130: --IBE_UTIL.disable_debug();
131:
132: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
133: --IBE_UTIL.enable_debug();
134:
129:
130: --IBE_UTIL.disable_debug();
131:
132: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
133: --IBE_UTIL.enable_debug();
134:
135: ROLLBACK TO setOptInOutPreference;
136: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
137: FND_MSG_PUB.count_and_get(
138: p_encoded => FND_API.G_FALSE,
139: p_count => x_msg_count,
140: p_data => x_msg_data
141: );
142: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
143: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
144: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
145: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
139: p_count => x_msg_count,
140: p_data => x_msg_data
141: );
142: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
143: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
144: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
145: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
147: IBE_UTIL.debug('error text : '|| SQLERRM);
140: p_data => x_msg_data
141: );
142: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
143: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
144: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
145: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
147: IBE_UTIL.debug('error text : '|| SQLERRM);
148: END IF;
141: );
142: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
143: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
144: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
145: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
147: IBE_UTIL.debug('error text : '|| SQLERRM);
148: END IF;
149:
142: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
143: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
144: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
145: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
147: IBE_UTIL.debug('error text : '|| SQLERRM);
148: END IF;
149:
150: --IBE_UTIL.disable_debug();
143: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
144: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
145: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
147: IBE_UTIL.debug('error text : '|| SQLERRM);
148: END IF;
149:
150: --IBE_UTIL.disable_debug();
151:
146: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
147: IBE_UTIL.debug('error text : '|| SQLERRM);
148: END IF;
149:
150: --IBE_UTIL.disable_debug();
151:
152: WHEN OTHERS THEN
153: --IBE_UTIL.enable_debug();
154:
149:
150: --IBE_UTIL.disable_debug();
151:
152: WHEN OTHERS THEN
153: --IBE_UTIL.enable_debug();
154:
155: ROLLBACK TO setOptInOutPreference;
156: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
157: FND_MSG_PUB.count_and_get(
158: p_encoded => FND_API.G_FALSE,
159: p_count => x_msg_count,
160: p_data => x_msg_data
161: );
162: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
163: IBE_UTIL.debug('OTHER exception');
164: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
165: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
159: p_count => x_msg_count,
160: p_data => x_msg_data
161: );
162: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
163: IBE_UTIL.debug('OTHER exception');
164: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
165: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
167: IBE_UTIL.debug('error text : '|| SQLERRM);
160: p_data => x_msg_data
161: );
162: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
163: IBE_UTIL.debug('OTHER exception');
164: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
165: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
167: IBE_UTIL.debug('error text : '|| SQLERRM);
168: END IF;
161: );
162: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
163: IBE_UTIL.debug('OTHER exception');
164: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
165: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
167: IBE_UTIL.debug('error text : '|| SQLERRM);
168: END IF;
169:
162: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
163: IBE_UTIL.debug('OTHER exception');
164: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
165: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
167: IBE_UTIL.debug('error text : '|| SQLERRM);
168: END IF;
169:
170: --IBE_UTIL.disable_debug();
163: IBE_UTIL.debug('OTHER exception');
164: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
165: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
167: IBE_UTIL.debug('error text : '|| SQLERRM);
168: END IF;
169:
170: --IBE_UTIL.disable_debug();
171:
166: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
167: IBE_UTIL.debug('error text : '|| SQLERRM);
168: END IF;
169:
170: --IBE_UTIL.disable_debug();
171:
172: END setOptInOutPreference;
173:
174:
298: l_def_cc_assignment_id NUMBER;
299: l_cc_assignment_id NUMBER;
300: BEGIN
301:
302: --IBE_UTIL.enable_debug();
303:
304: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
305: IBE_UTIL.debug('enter ibe_customer_pvt.get_default_credit_card_info');
306: END IF;
300: BEGIN
301:
302: --IBE_UTIL.enable_debug();
303:
304: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
305: IBE_UTIL.debug('enter ibe_customer_pvt.get_default_credit_card_info');
306: END IF;
307:
308:
301:
302: --IBE_UTIL.enable_debug();
303:
304: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
305: IBE_UTIL.debug('enter ibe_customer_pvt.get_default_credit_card_info');
306: END IF;
307:
308:
309: IF NOT FND_API.compatible_api_call(l_api_version,
322: -- Initialize API return status to success
323: x_return_status := FND_API.G_RET_STS_SUCCESS;
324:
325:
326: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
327: IBE_UTIL.debug('call cursor c_getPrimaryCCInfo()');
328: END IF;
329: -- call cursor c_getPrimaryInfo
330:
323: x_return_status := FND_API.G_RET_STS_SUCCESS;
324:
325:
326: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
327: IBE_UTIL.debug('call cursor c_getPrimaryCCInfo()');
328: END IF;
329: -- call cursor c_getPrimaryInfo
330:
331: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
327: IBE_UTIL.debug('call cursor c_getPrimaryCCInfo()');
328: END IF;
329: -- call cursor c_getPrimaryInfo
330:
331: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
332: IBE_UTIL.debug('cust_acct_id = '||p_cust_account_id||'party_id = '||p_party_id||' minisite_id : '||p_mini_site_id);
333: END IF;
334:
335: OPEN c_getPrimaryCCInfo(p_cust_account_id,p_party_id,p_mini_site_id);
328: END IF;
329: -- call cursor c_getPrimaryInfo
330:
331: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
332: IBE_UTIL.debug('cust_acct_id = '||p_cust_account_id||'party_id = '||p_party_id||' minisite_id : '||p_mini_site_id);
333: END IF;
334:
335: OPEN c_getPrimaryCCInfo(p_cust_account_id,p_party_id,p_mini_site_id);
336:
335: OPEN c_getPrimaryCCInfo(p_cust_account_id,p_party_id,p_mini_site_id);
336:
337: FETCH c_getPrimaryCCInfo INTO l_cc_assignment_id ;
338:
339: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
340: IBE_UTIL.debug('call cursor c_getFirstCCInfo()');
341: END IF;
342: OPEN c_getFirstCCInfo(p_cust_account_id,p_party_id,p_mini_site_id);
343:
336:
337: FETCH c_getPrimaryCCInfo INTO l_cc_assignment_id ;
338:
339: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
340: IBE_UTIL.debug('call cursor c_getFirstCCInfo()');
341: END IF;
342: OPEN c_getFirstCCInfo(p_cust_account_id,p_party_id,p_mini_site_id);
343:
344: FETCH c_getFirstCCInfo INTO l_def_cc_assignment_id;
343:
344: FETCH c_getFirstCCInfo INTO l_def_cc_assignment_id;
345:
346: if c_getPrimaryCCInfo%FOUND then
347: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
348: IBE_UTIL.debug('Primary CC found');
349: END IF;
350:
351: x_cc_assignment_id:= l_cc_assignment_id;
344: FETCH c_getFirstCCInfo INTO l_def_cc_assignment_id;
345:
346: if c_getPrimaryCCInfo%FOUND then
347: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
348: IBE_UTIL.debug('Primary CC found');
349: END IF;
350:
351: x_cc_assignment_id:= l_cc_assignment_id;
352: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
348: IBE_UTIL.debug('Primary CC found');
349: END IF;
350:
351: x_cc_assignment_id:= l_cc_assignment_id;
352: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
353: IBE_UTIL.debug('x_cc_assign_id : '||l_cc_assignment_id);
354: END IF;
355: --else
356: --IBE_UTIL.debug('No Primary Info found');
349: END IF;
350:
351: x_cc_assignment_id:= l_cc_assignment_id;
352: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
353: IBE_UTIL.debug('x_cc_assign_id : '||l_cc_assignment_id);
354: END IF;
355: --else
356: --IBE_UTIL.debug('No Primary Info found');
357: --close c_getPrimaryCCInfo;
352: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
353: IBE_UTIL.debug('x_cc_assign_id : '||l_cc_assignment_id);
354: END IF;
355: --else
356: --IBE_UTIL.debug('No Primary Info found');
357: --close c_getPrimaryCCInfo;
358: --end if;
359: elsif (c_getFirstCCInfo%FOUND) then
360:
357: --close c_getPrimaryCCInfo;
358: --end if;
359: elsif (c_getFirstCCInfo%FOUND) then
360:
361: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
362: IBE_UTIL.debug('Default CC found ');
363: END IF;
364:
365: x_cc_assignment_id := l_def_cc_assignment_id;
358: --end if;
359: elsif (c_getFirstCCInfo%FOUND) then
360:
361: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
362: IBE_UTIL.debug('Default CC found ');
363: END IF;
364:
365: x_cc_assignment_id := l_def_cc_assignment_id;
366: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
362: IBE_UTIL.debug('Default CC found ');
363: END IF;
364:
365: x_cc_assignment_id := l_def_cc_assignment_id;
366: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
367: IBE_UTIL.debug('x_def_cc_assign_id : '||l_def_cc_assignment_id);
368: END IF;
369: else
370:
363: END IF;
364:
365: x_cc_assignment_id := l_def_cc_assignment_id;
366: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
367: IBE_UTIL.debug('x_def_cc_assign_id : '||l_def_cc_assignment_id);
368: END IF;
369: else
370:
371: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
367: IBE_UTIL.debug('x_def_cc_assign_id : '||l_def_cc_assignment_id);
368: END IF;
369: else
370:
371: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
372: IBE_UTIL.debug(' No default Credit card info found ');
373: END IF;
374: close c_getFirstCCInfo;
375: close c_getPrimaryCCInfo;
368: END IF;
369: else
370:
371: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
372: IBE_UTIL.debug(' No default Credit card info found ');
373: END IF;
374: close c_getFirstCCInfo;
375: close c_getPrimaryCCInfo;
376: end if;
375: close c_getPrimaryCCInfo;
376: end if;
377:
378: /* 3/3/05: comment out
379: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
380: IBE_UTIL.debug('x_credit_card_num : '||x_credit_card_num);
381: IBE_UTIL.debug('x_card_holder_name : '||x_card_holder_name);
382: IBE_UTIL.debug('x_credit_card_exp_date : '||x_credit_card_exp_date);
383: IBE_UTIL.debug('x_credit_card_type : '||x_credit_card_type);
376: end if;
377:
378: /* 3/3/05: comment out
379: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
380: IBE_UTIL.debug('x_credit_card_num : '||x_credit_card_num);
381: IBE_UTIL.debug('x_card_holder_name : '||x_card_holder_name);
382: IBE_UTIL.debug('x_credit_card_exp_date : '||x_credit_card_exp_date);
383: IBE_UTIL.debug('x_credit_card_type : '||x_credit_card_type);
384: END IF;
377:
378: /* 3/3/05: comment out
379: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
380: IBE_UTIL.debug('x_credit_card_num : '||x_credit_card_num);
381: IBE_UTIL.debug('x_card_holder_name : '||x_card_holder_name);
382: IBE_UTIL.debug('x_credit_card_exp_date : '||x_credit_card_exp_date);
383: IBE_UTIL.debug('x_credit_card_type : '||x_credit_card_type);
384: END IF;
385: */
378: /* 3/3/05: comment out
379: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
380: IBE_UTIL.debug('x_credit_card_num : '||x_credit_card_num);
381: IBE_UTIL.debug('x_card_holder_name : '||x_card_holder_name);
382: IBE_UTIL.debug('x_credit_card_exp_date : '||x_credit_card_exp_date);
383: IBE_UTIL.debug('x_credit_card_type : '||x_credit_card_type);
384: END IF;
385: */
386:
379: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
380: IBE_UTIL.debug('x_credit_card_num : '||x_credit_card_num);
381: IBE_UTIL.debug('x_card_holder_name : '||x_card_holder_name);
382: IBE_UTIL.debug('x_credit_card_exp_date : '||x_credit_card_exp_date);
383: IBE_UTIL.debug('x_credit_card_type : '||x_credit_card_type);
384: END IF;
385: */
386:
387:
398: p_data => x_msg_data
399: );
400:
401:
402: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
403: IBE_UTIL.debug('exit ibe_customer_pvt.get_default_credit_card_info');
404: END IF;
405:
406: --IBE_UTIL.disable_debug();
399: );
400:
401:
402: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
403: IBE_UTIL.debug('exit ibe_customer_pvt.get_default_credit_card_info');
404: END IF;
405:
406: --IBE_UTIL.disable_debug();
407:
402: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
403: IBE_UTIL.debug('exit ibe_customer_pvt.get_default_credit_card_info');
404: END IF;
405:
406: --IBE_UTIL.disable_debug();
407:
408: EXCEPTION
409:
410: WHEN FND_API.G_EXC_ERROR THEN
407:
408: EXCEPTION
409:
410: WHEN FND_API.G_EXC_ERROR THEN
411: --IBE_UTIL.enable_debug();
412:
413: --ROLLBACK TO create_credit_card;
414:
415: x_return_status := FND_API.G_RET_STS_ERROR;
417: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count,
418: p_data => x_msg_data,
419: p_encoded => 'F');
420:
421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
422: IBE_UTIL.debug('G_EXC_ERROR exception');
423: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
424: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
425: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
418: p_data => x_msg_data,
419: p_encoded => 'F');
420:
421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
422: IBE_UTIL.debug('G_EXC_ERROR exception');
423: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
424: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
425: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
426: IBE_UTIL.debug('error text : '|| SQLERRM);
419: p_encoded => 'F');
420:
421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
422: IBE_UTIL.debug('G_EXC_ERROR exception');
423: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
424: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
425: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
426: IBE_UTIL.debug('error text : '|| SQLERRM);
427: END IF;
420:
421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
422: IBE_UTIL.debug('G_EXC_ERROR exception');
423: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
424: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
425: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
426: IBE_UTIL.debug('error text : '|| SQLERRM);
427: END IF;
428:
421: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
422: IBE_UTIL.debug('G_EXC_ERROR exception');
423: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
424: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
425: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
426: IBE_UTIL.debug('error text : '|| SQLERRM);
427: END IF;
428:
429:
422: IBE_UTIL.debug('G_EXC_ERROR exception');
423: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
424: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
425: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
426: IBE_UTIL.debug('error text : '|| SQLERRM);
427: END IF;
428:
429:
430: --IBE_UTIL.disable_debug();
426: IBE_UTIL.debug('error text : '|| SQLERRM);
427: END IF;
428:
429:
430: --IBE_UTIL.disable_debug();
431:
432:
433:
434:
432:
433:
434:
435: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
436: --IBE_UTIL.enable_debug();
437:
438: --ROLLBACK TO create_credit_card;
439: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
440: FND_MSG_PUB.ADD;
441: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count,
442: p_data => x_msg_data,
443: p_encoded => 'F');
444:
445: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
446: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
447: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
448: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
442: p_data => x_msg_data,
443: p_encoded => 'F');
444:
445: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
446: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
447: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
448: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
450: IBE_UTIL.debug('error text : '|| SQLERRM);
443: p_encoded => 'F');
444:
445: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
446: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
447: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
448: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
450: IBE_UTIL.debug('error text : '|| SQLERRM);
451: END IF;
444:
445: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
446: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
447: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
448: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
450: IBE_UTIL.debug('error text : '|| SQLERRM);
451: END IF;
452:
445: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
446: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
447: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
448: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
450: IBE_UTIL.debug('error text : '|| SQLERRM);
451: END IF;
452:
453: --IBE_UTIL.disable_debug();
446: IBE_UTIL.debug('G_EXC_UNEXPECTED_ERROR exception');
447: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
448: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
450: IBE_UTIL.debug('error text : '|| SQLERRM);
451: END IF;
452:
453: --IBE_UTIL.disable_debug();
454:
449: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
450: IBE_UTIL.debug('error text : '|| SQLERRM);
451: END IF;
452:
453: --IBE_UTIL.disable_debug();
454:
455:
456:
457:
455:
456:
457:
458: WHEN OTHERS THEN
459: --IBE_UTIL.enable_debug();
460:
461: --ROLLBACK TO create_credit_card;
462: FND_MESSAGE.Set_Name('FND', 'SQL_PLSQL_ERROR');
463: FND_MESSAGE.Set_Token('ROUTINE', l_api_name);
470: p_data => x_msg_data,
471: p_encoded => 'F');
472:
473:
474: --IBE_UTIL.debug('OTHER exception');
475: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
476: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
477: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
471: p_encoded => 'F');
472:
473:
474: --IBE_UTIL.debug('OTHER exception');
475: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
476: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
477: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
479: IBE_UTIL.debug('error text : '|| SQLERRM);
472:
473:
474: --IBE_UTIL.debug('OTHER exception');
475: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
476: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
477: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
479: IBE_UTIL.debug('error text : '|| SQLERRM);
480: END IF;
473:
474: --IBE_UTIL.debug('OTHER exception');
475: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
476: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
477: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
479: IBE_UTIL.debug('error text : '|| SQLERRM);
480: END IF;
481:
474: --IBE_UTIL.debug('OTHER exception');
475: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
476: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
477: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
479: IBE_UTIL.debug('error text : '|| SQLERRM);
480: END IF;
481:
482: --IBE_UTIL.disable_debug();
475: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
476: IBE_UTIL.debug('x_msg_count ' || to_char(x_msg_count));
477: IBE_UTIL.debug('x_msg_data ' || x_msg_data);
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
479: IBE_UTIL.debug('error text : '|| SQLERRM);
480: END IF;
481:
482: --IBE_UTIL.disable_debug();
483:
478: IBE_UTIL.debug('error code : '|| to_char(SQLCODE));
479: IBE_UTIL.debug('error text : '|| SQLERRM);
480: END IF;
481:
482: --IBE_UTIL.disable_debug();
483:
484:
485:
486:
516: l_assignment_id NUMBER;
517: l_party_to_use NUMBER;
518:
519: BEGIN
520: --IBE_UTIL.enable_debug();
521:
522: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
523: IBE_UTIL.debug('enter ibe_customer_pvt.get_primary_credit_card_id');
524: END IF;
518:
519: BEGIN
520: --IBE_UTIL.enable_debug();
521:
522: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
523: IBE_UTIL.debug('enter ibe_customer_pvt.get_primary_credit_card_id');
524: END IF;
525:
526: FOR rec_get_party_cust_accnt in C_get_party_cust_accnt(p_username) LOOP
519: BEGIN
520: --IBE_UTIL.enable_debug();
521:
522: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
523: IBE_UTIL.debug('enter ibe_customer_pvt.get_primary_credit_card_id');
524: END IF;
525:
526: FOR rec_get_party_cust_accnt in C_get_party_cust_accnt(p_username) LOOP
527: l_customer_id := rec_get_party_cust_accnt.customer_id;
530: END LOOP;
531:
532: IF (l_customer_id is null) THEN
533: l_party_to_use := l_person_party_id;
534: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
535: IBE_UTIL.debug('customer_id does not have any value, using the person_party_id');
536: END IF;
537: ELSE
538: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
531:
532: IF (l_customer_id is null) THEN
533: l_party_to_use := l_person_party_id;
534: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
535: IBE_UTIL.debug('customer_id does not have any value, using the person_party_id');
536: END IF;
537: ELSE
538: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
539: IBE_UTIL.debug('customer_id has a value,l_party_to_use: '||l_customer_id);
534: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
535: IBE_UTIL.debug('customer_id does not have any value, using the person_party_id');
536: END IF;
537: ELSE
538: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
539: IBE_UTIL.debug('customer_id has a value,l_party_to_use: '||l_customer_id);
540: END IF;
541: l_party_to_use := l_customer_id;
542: END IF;
535: IBE_UTIL.debug('customer_id does not have any value, using the person_party_id');
536: END IF;
537: ELSE
538: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
539: IBE_UTIL.debug('customer_id has a value,l_party_to_use: '||l_customer_id);
540: END IF;
541: l_party_to_use := l_customer_id;
542: END IF;
543:
545: l_assignment_id := rec_get_primary_credit_card.instr_assignment_id;
546: EXIT when c_get_primary_credit_card%NOTFOUND;
547: END LOOP;
548:
549: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
550: IBE_UTIL.debug('primary card asignment id is '||l_assignment_id);
551: END IF;
552: x_credit_card_id := l_assignment_id;
553: END ;
546: EXIT when c_get_primary_credit_card%NOTFOUND;
547: END LOOP;
548:
549: IF (IBE_UTIL.G_DEBUGON = l_true) THEN
550: IBE_UTIL.debug('primary card asignment id is '||l_assignment_id);
551: END IF;
552: x_credit_card_id := l_assignment_id;
553: END ;
554: