99: WHERE party_id = l_party_id;
100:
101: x_zx_party_tax_profile_bo_tbl := l_ap_supplier_tax_prof_bo_tbl;
102: EXCEPTION
103: WHEN fnd_api.g_exc_error THEN
104:
105: x_return_status := fnd_api.g_ret_sts_error;
106: x_msg_count := 1;
107: x_msg_data := SQLCODE || SQLERRM;
101: x_zx_party_tax_profile_bo_tbl := l_ap_supplier_tax_prof_bo_tbl;
102: EXCEPTION
103: WHEN fnd_api.g_exc_error THEN
104:
105: x_return_status := fnd_api.g_ret_sts_error;
106: x_msg_count := 1;
107: x_msg_data := SQLCODE || SQLERRM;
108: WHEN fnd_api.g_exc_unexpected_error THEN
109:
104:
105: x_return_status := fnd_api.g_ret_sts_error;
106: x_msg_count := 1;
107: x_msg_data := SQLCODE || SQLERRM;
108: WHEN fnd_api.g_exc_unexpected_error THEN
109:
110: x_return_status := fnd_api.g_ret_sts_unexp_error;
111: x_msg_count := 1;
112: x_msg_data := SQLCODE || SQLERRM;
106: x_msg_count := 1;
107: x_msg_data := SQLCODE || SQLERRM;
108: WHEN fnd_api.g_exc_unexpected_error THEN
109:
110: x_return_status := fnd_api.g_ret_sts_unexp_error;
111: x_msg_count := 1;
112: x_msg_data := SQLCODE || SQLERRM;
113: WHEN OTHERS THEN
114:
111: x_msg_count := 1;
112: x_msg_data := SQLCODE || SQLERRM;
113: WHEN OTHERS THEN
114:
115: x_return_status := fnd_api.g_ret_sts_unexp_error;
116:
117: x_msg_count := 1;
118: x_msg_data := SQLCODE || SQLERRM;
119: END get_pos_sup_tax_prof_bo_tbl;
136: l_msg_data VARCHAR2(2000);
137: l_api_name CONSTANT VARCHAR2(50) := 'VALIDATE_VENDOR_PRODS_SERVICES';
138: BEGIN
139: -- Initialize API return status to success
140: x_return_status := fnd_api.g_ret_sts_success;
141: x_tax_prof_valid := 'Y';
142:
143: -- Check if the Tax Profile Id exists
144: BEGIN
170:
171: EXCEPTION
172: WHEN OTHERS THEN
173: x_tax_prof_valid := 'N';
174: x_return_status := fnd_api.g_ret_sts_error;
175: x_msg_data := 'AP_INVALID_ROUNDING_LEVEL';
176:
177: END;
178: END IF;
192:
193: EXCEPTION
194: WHEN OTHERS THEN
195: x_tax_prof_valid := 'N';
196: x_return_status := fnd_api.g_ret_sts_error;
197: x_msg_data := 'AP_INVALID_ROUNDING_RULE';
198:
199: END;
200: END IF;
210: -- Update the Interface table with the country code obtained in the prev SQL since the country code would be saved.
211: EXCEPTION
212: WHEN OTHERS THEN
213: x_tax_prof_valid := 'N';
214: x_return_status := fnd_api.g_ret_sts_error;
215: x_msg_data := 'AP_INVALID_COUNTRY_NAME';
216:
217: END;
218: END IF;
232:
233: EXCEPTION
234: WHEN OTHERS THEN
235: x_tax_prof_valid := 'N';
236: x_return_status := fnd_api.g_ret_sts_error;
237: x_msg_data := 'AP_INVALID_REGISTRATION_TYPE_CODE';
238:
239: END;
240: END IF;
241:
242: EXCEPTION
243: WHEN OTHERS THEN
244: x_tax_prof_valid := 'N';
245: x_return_status := fnd_api.g_ret_sts_error;
246: fnd_msg_pub.count_and_get(p_count => x_msg_count,
247: p_data => x_msg_data);
248: END validate_tax_profile;
249:
282: l_msg_count NUMBER;
283: l_msg_data VARCHAR2(4000);
284: l_party_id NUMBER;
285: BEGIN
286: x_return_status := fnd_api.g_ret_sts_success;
287:
288: IF p_party_id IS NULL OR p_party_id = 0 THEN
289: l_party_id := pos_supplier_bo_dep_pkg.get_party_id(p_orig_system,
290: p_orig_system_reference);
448: END LOOP;
449:
450:
451: EXCEPTION
452: WHEN fnd_api.g_exc_error THEN
453:
454: x_return_status := fnd_api.g_ret_sts_error;
455: x_msg_count := 1;
456: x_msg_data := SQLCODE || SQLERRM;
450:
451: EXCEPTION
452: WHEN fnd_api.g_exc_error THEN
453:
454: x_return_status := fnd_api.g_ret_sts_error;
455: x_msg_count := 1;
456: x_msg_data := SQLCODE || SQLERRM;
457: WHEN fnd_api.g_exc_unexpected_error THEN
458:
453:
454: x_return_status := fnd_api.g_ret_sts_error;
455: x_msg_count := 1;
456: x_msg_data := SQLCODE || SQLERRM;
457: WHEN fnd_api.g_exc_unexpected_error THEN
458:
459: x_return_status := fnd_api.g_ret_sts_unexp_error;
460: x_msg_count := 1;
461: x_msg_data := SQLCODE || SQLERRM;
455: x_msg_count := 1;
456: x_msg_data := SQLCODE || SQLERRM;
457: WHEN fnd_api.g_exc_unexpected_error THEN
458:
459: x_return_status := fnd_api.g_ret_sts_unexp_error;
460: x_msg_count := 1;
461: x_msg_data := SQLCODE || SQLERRM;
462: WHEN OTHERS THEN
463:
460: x_msg_count := 1;
461: x_msg_data := SQLCODE || SQLERRM;
462: WHEN OTHERS THEN
463:
464: x_return_status := fnd_api.g_ret_sts_unexp_error;
465:
466: x_msg_count := 1;
467: x_msg_data := SQLCODE || SQLERRM;
468: END create_supp_tax_profile;
492: l_msg_count NUMBER;
493: l_msg_data VARCHAR2(4000);
494:
495: BEGIN
496: x_return_status := fnd_api.g_ret_sts_success;
497:
498: -- Call Validate_Tax_profile to validate the Tax Profiledata
499: validate_tax_profile(p_tax_profile_rec => p_tax_profile_rec,
500: x_return_status => l_return_status,
564: x_msg_count := l_msg_count;
565: END IF;
566:
567: EXCEPTION
568: WHEN fnd_api.g_exc_error THEN
569:
570: x_return_status := fnd_api.g_ret_sts_error;
571: x_msg_count := 1;
572: x_msg_data := SQLCODE || SQLERRM;
566:
567: EXCEPTION
568: WHEN fnd_api.g_exc_error THEN
569:
570: x_return_status := fnd_api.g_ret_sts_error;
571: x_msg_count := 1;
572: x_msg_data := SQLCODE || SQLERRM;
573: WHEN fnd_api.g_exc_unexpected_error THEN
574:
569:
570: x_return_status := fnd_api.g_ret_sts_error;
571: x_msg_count := 1;
572: x_msg_data := SQLCODE || SQLERRM;
573: WHEN fnd_api.g_exc_unexpected_error THEN
574:
575: x_return_status := fnd_api.g_ret_sts_unexp_error;
576: x_msg_count := 1;
577: x_msg_data := SQLCODE || SQLERRM;
571: x_msg_count := 1;
572: x_msg_data := SQLCODE || SQLERRM;
573: WHEN fnd_api.g_exc_unexpected_error THEN
574:
575: x_return_status := fnd_api.g_ret_sts_unexp_error;
576: x_msg_count := 1;
577: x_msg_data := SQLCODE || SQLERRM;
578: WHEN OTHERS THEN
579:
576: x_msg_count := 1;
577: x_msg_data := SQLCODE || SQLERRM;
578: WHEN OTHERS THEN
579:
580: x_return_status := fnd_api.g_ret_sts_unexp_error;
581:
582: x_msg_count := 1;
583: x_msg_data := SQLCODE || SQLERRM;
584: END update_supp_tax_profile;