DBA Data[Home] [Help]

APPS.CN_CALC_SQL_EXPS_PVT dependencies on FND_API

Line 59: RAISE fnd_api.g_exc_error;

55: fnd_message.set_name('CN', 'CN_EXP_TOO_LONG');
56: fnd_msg_pub.ADD;
57: END IF;
58:
59: RAISE fnd_api.g_exc_error;
60: END IF;
61:
62: DECLARE
63: l_sql_statement VARCHAR2(4100);

Line 102: , p_encoded => fnd_api.g_false);

98: fnd_msg_pub.ADD;
99: END IF;
100:
101: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
102: , p_encoded => fnd_api.g_false);
103: END;
104:
105: IF (p_piped_sql_select IS NULL OR p_piped_sql_from IS NULL) THEN
106: RETURN;

Line 283: -- Default = FND_API.G_FALSE

279: -- Pre-reqs : None.
280: -- Parameters :
281: -- IN : p_api_version IN NUMBER Required
282: -- p_init_msg_list IN VARCHAR2 Optional
283: -- Default = FND_API.G_FALSE
284: -- p_commit IN VARCHAR2 Optional
285: -- Default = FND_API.G_FALSE
286: -- p_validation_level IN NUMBER Optional
287: -- Default = FND_API.G_VALID_LEVEL_FULL

Line 285: -- Default = FND_API.G_FALSE

281: -- IN : p_api_version IN NUMBER Required
282: -- p_init_msg_list IN VARCHAR2 Optional
283: -- Default = FND_API.G_FALSE
284: -- p_commit IN VARCHAR2 Optional
285: -- Default = FND_API.G_FALSE
286: -- p_validation_level IN NUMBER Optional
287: -- Default = FND_API.G_VALID_LEVEL_FULL
288: -- p_name IN VARCHAR2 Required
289: -- p_description IN VARCHAR2 Optional

Line 287: -- Default = FND_API.G_VALID_LEVEL_FULL

283: -- Default = FND_API.G_FALSE
284: -- p_commit IN VARCHAR2 Optional
285: -- Default = FND_API.G_FALSE
286: -- p_validation_level IN NUMBER Optional
287: -- Default = FND_API.G_VALID_LEVEL_FULL
288: -- p_name IN VARCHAR2 Required
289: -- p_description IN VARCHAR2 Optional
290: -- Default = null
291: -- p_expression_disp IN VARCHAR2 Optional

Line 320: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

316: --
317: -- End of comments
318: PROCEDURE create_expression(
319: p_api_version IN NUMBER
320: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
321: , p_commit IN VARCHAR2 := fnd_api.g_false
322: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
323: , p_org_id IN cn_calc_sql_exps.org_id%TYPE
324: , p_name IN cn_calc_sql_exps.NAME%TYPE

Line 321: , p_commit IN VARCHAR2 := fnd_api.g_false

317: -- End of comments
318: PROCEDURE create_expression(
319: p_api_version IN NUMBER
320: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
321: , p_commit IN VARCHAR2 := fnd_api.g_false
322: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
323: , p_org_id IN cn_calc_sql_exps.org_id%TYPE
324: , p_name IN cn_calc_sql_exps.NAME%TYPE
325: , p_description IN cn_calc_sql_exps.description%TYPE := NULL

Line 322: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

318: PROCEDURE create_expression(
319: p_api_version IN NUMBER
320: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
321: , p_commit IN VARCHAR2 := fnd_api.g_false
322: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
323: , p_org_id IN cn_calc_sql_exps.org_id%TYPE
324: , p_name IN cn_calc_sql_exps.NAME%TYPE
325: , p_description IN cn_calc_sql_exps.description%TYPE := NULL
326: , p_expression_disp IN VARCHAR2 := NULL

Line 361: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

357: -- Standard Start of API savepoint
358: SAVEPOINT create_expression;
359:
360: -- Standard call to check for call compatibility.
361: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
362: RAISE fnd_api.g_exc_unexpected_error;
363: END IF;
364:
365: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 362: RAISE fnd_api.g_exc_unexpected_error;

358: SAVEPOINT create_expression;
359:
360: -- Standard call to check for call compatibility.
361: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
362: RAISE fnd_api.g_exc_unexpected_error;
363: END IF;
364:
365: -- Initialize message list if p_init_msg_list is set to TRUE.
366: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 366: IF fnd_api.to_boolean(p_init_msg_list) THEN

362: RAISE fnd_api.g_exc_unexpected_error;
363: END IF;
364:
365: -- Initialize message list if p_init_msg_list is set to TRUE.
366: IF fnd_api.to_boolean(p_init_msg_list) THEN
367: fnd_msg_pub.initialize;
368: END IF;
369:
370: -- Initialize API return status to success

Line 371: x_return_status := fnd_api.g_ret_sts_success;

367: fnd_msg_pub.initialize;
368: END IF;
369:
370: -- Initialize API return status to success
371: x_return_status := fnd_api.g_ret_sts_success;
372:
373: -- API body
374: IF (p_name IS NULL) THEN
375: IF (fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_error)) THEN

Line 382: RAISE fnd_api.g_exc_error;

378: fnd_message.set_token('OBJ_NAME', l_prompt);
379: fnd_msg_pub.ADD;
380: END IF;
381:
382: RAISE fnd_api.g_exc_error;
383: END IF;
384:
385: OPEN exp_exists;
386: FETCH exp_exists INTO l_dummy;

Line 395: RAISE fnd_api.g_exc_error;

391: fnd_message.set_name('CN', 'CN_NAME_NOT_UNIQUE');
392: fnd_msg_pub.ADD;
393: END IF;
394:
395: RAISE fnd_api.g_exc_error;
396: END IF;
397:
398: -- make sure name isn't too long
399: IF LENGTH(p_name) > 30 THEN

Line 406: RAISE fnd_api.g_exc_error;

402: fnd_message.set_token('LENGTH', 30);
403: fnd_msg_pub.ADD;
404: END IF;
405:
406: RAISE fnd_api.g_exc_error;
407: END IF;
408:
409: -- parse the expression and classify it into sub types
410: classify_expression(

Line 524: IF fnd_api.to_boolean(p_commit) THEN

520:
521: -- End of API body.
522:
523: -- Standard check of p_commit.
524: IF fnd_api.to_boolean(p_commit) THEN
525: COMMIT WORK;
526: END IF;
527:
528: -- Standard call to get message count and if count is 1, get message info.

Line 530: , p_encoded => fnd_api.g_false);

526: END IF;
527:
528: -- Standard call to get message count and if count is 1, get message info.
529: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
530: , p_encoded => fnd_api.g_false);
531: EXCEPTION
532: WHEN fnd_api.g_exc_error THEN
533: ROLLBACK TO create_expression;
534: x_return_status := fnd_api.g_ret_sts_error;

Line 532: WHEN fnd_api.g_exc_error THEN

528: -- Standard call to get message count and if count is 1, get message info.
529: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
530: , p_encoded => fnd_api.g_false);
531: EXCEPTION
532: WHEN fnd_api.g_exc_error THEN
533: ROLLBACK TO create_expression;
534: x_return_status := fnd_api.g_ret_sts_error;
535: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
536: , p_encoded => fnd_api.g_false);

Line 534: x_return_status := fnd_api.g_ret_sts_error;

530: , p_encoded => fnd_api.g_false);
531: EXCEPTION
532: WHEN fnd_api.g_exc_error THEN
533: ROLLBACK TO create_expression;
534: x_return_status := fnd_api.g_ret_sts_error;
535: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
536: , p_encoded => fnd_api.g_false);
537: WHEN fnd_api.g_exc_unexpected_error THEN
538: ROLLBACK TO create_expression;

Line 536: , p_encoded => fnd_api.g_false);

532: WHEN fnd_api.g_exc_error THEN
533: ROLLBACK TO create_expression;
534: x_return_status := fnd_api.g_ret_sts_error;
535: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
536: , p_encoded => fnd_api.g_false);
537: WHEN fnd_api.g_exc_unexpected_error THEN
538: ROLLBACK TO create_expression;
539: x_return_status := fnd_api.g_ret_sts_unexp_error;
540: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 537: WHEN fnd_api.g_exc_unexpected_error THEN

533: ROLLBACK TO create_expression;
534: x_return_status := fnd_api.g_ret_sts_error;
535: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
536: , p_encoded => fnd_api.g_false);
537: WHEN fnd_api.g_exc_unexpected_error THEN
538: ROLLBACK TO create_expression;
539: x_return_status := fnd_api.g_ret_sts_unexp_error;
540: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
541: , p_encoded => fnd_api.g_false);

Line 539: x_return_status := fnd_api.g_ret_sts_unexp_error;

535: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
536: , p_encoded => fnd_api.g_false);
537: WHEN fnd_api.g_exc_unexpected_error THEN
538: ROLLBACK TO create_expression;
539: x_return_status := fnd_api.g_ret_sts_unexp_error;
540: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
541: , p_encoded => fnd_api.g_false);
542: WHEN OTHERS THEN
543: ROLLBACK TO create_expression;

Line 541: , p_encoded => fnd_api.g_false);

537: WHEN fnd_api.g_exc_unexpected_error THEN
538: ROLLBACK TO create_expression;
539: x_return_status := fnd_api.g_ret_sts_unexp_error;
540: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
541: , p_encoded => fnd_api.g_false);
542: WHEN OTHERS THEN
543: ROLLBACK TO create_expression;
544: x_return_status := fnd_api.g_ret_sts_unexp_error;
545:

Line 544: x_return_status := fnd_api.g_ret_sts_unexp_error;

540: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
541: , p_encoded => fnd_api.g_false);
542: WHEN OTHERS THEN
543: ROLLBACK TO create_expression;
544: x_return_status := fnd_api.g_ret_sts_unexp_error;
545:
546: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
547: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
548: END IF;

Line 551: , p_encoded => fnd_api.g_false);

547: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
548: END IF;
549:
550: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
551: , p_encoded => fnd_api.g_false);
552: END create_expression;
553:
554: -- Start of comments
555: -- API name : Update_Expressions

Line 562: -- Default = FND_API.G_FALSE

558: -- Pre-reqs : None.
559: -- Parameters :
560: -- IN : p_api_version IN NUMBER Required
561: -- p_init_msg_list IN VARCHAR2 Optional
562: -- Default = FND_API.G_FALSE
563: -- p_commit IN VARCHAR2 Optional
564: -- Default = FND_API.G_FALSE
565: -- p_validation_level IN NUMBER Optional
566: -- Default = FND_API.G_VALID_LEVEL_FULL

Line 564: -- Default = FND_API.G_FALSE

560: -- IN : p_api_version IN NUMBER Required
561: -- p_init_msg_list IN VARCHAR2 Optional
562: -- Default = FND_API.G_FALSE
563: -- p_commit IN VARCHAR2 Optional
564: -- Default = FND_API.G_FALSE
565: -- p_validation_level IN NUMBER Optional
566: -- Default = FND_API.G_VALID_LEVEL_FULL
567: -- p_update_parent_also IN VARCHAR2 Optional
568: -- Default = FND_API.G_FALSE

Line 566: -- Default = FND_API.G_VALID_LEVEL_FULL

562: -- Default = FND_API.G_FALSE
563: -- p_commit IN VARCHAR2 Optional
564: -- Default = FND_API.G_FALSE
565: -- p_validation_level IN NUMBER Optional
566: -- Default = FND_API.G_VALID_LEVEL_FULL
567: -- p_update_parent_also IN VARCHAR2 Optional
568: -- Default = FND_API.G_FALSE
569: -- p_calc_sql_exp_id IN NUMBER Required
570: -- p_name IN VARCHAR2 Required

Line 568: -- Default = FND_API.G_FALSE

564: -- Default = FND_API.G_FALSE
565: -- p_validation_level IN NUMBER Optional
566: -- Default = FND_API.G_VALID_LEVEL_FULL
567: -- p_update_parent_also IN VARCHAR2 Optional
568: -- Default = FND_API.G_FALSE
569: -- p_calc_sql_exp_id IN NUMBER Required
570: -- p_name IN VARCHAR2 Required
571: -- p_description IN VARCHAR2 Optional
572: -- Default = null

Line 603: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

599: --
600: -- End of comments
601: PROCEDURE update_expression(
602: p_api_version IN NUMBER
603: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
604: , p_commit IN VARCHAR2 := fnd_api.g_false
605: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
606: , p_update_parent_also IN VARCHAR2 := fnd_api.g_false
607: , p_org_id IN cn_calc_sql_exps.org_id%TYPE

Line 604: , p_commit IN VARCHAR2 := fnd_api.g_false

600: -- End of comments
601: PROCEDURE update_expression(
602: p_api_version IN NUMBER
603: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
604: , p_commit IN VARCHAR2 := fnd_api.g_false
605: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
606: , p_update_parent_also IN VARCHAR2 := fnd_api.g_false
607: , p_org_id IN cn_calc_sql_exps.org_id%TYPE
608: , p_calc_sql_exp_id IN cn_calc_sql_exps.calc_sql_exp_id%TYPE

Line 605: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

601: PROCEDURE update_expression(
602: p_api_version IN NUMBER
603: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
604: , p_commit IN VARCHAR2 := fnd_api.g_false
605: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
606: , p_update_parent_also IN VARCHAR2 := fnd_api.g_false
607: , p_org_id IN cn_calc_sql_exps.org_id%TYPE
608: , p_calc_sql_exp_id IN cn_calc_sql_exps.calc_sql_exp_id%TYPE
609: , p_name IN cn_calc_sql_exps.NAME%TYPE

Line 606: , p_update_parent_also IN VARCHAR2 := fnd_api.g_false

602: p_api_version IN NUMBER
603: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
604: , p_commit IN VARCHAR2 := fnd_api.g_false
605: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
606: , p_update_parent_also IN VARCHAR2 := fnd_api.g_false
607: , p_org_id IN cn_calc_sql_exps.org_id%TYPE
608: , p_calc_sql_exp_id IN cn_calc_sql_exps.calc_sql_exp_id%TYPE
609: , p_name IN cn_calc_sql_exps.NAME%TYPE
610: , p_description IN cn_calc_sql_exps.description%TYPE := NULL

Line 669: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

665: -- Standard Start of API savepoint
666: SAVEPOINT update_expression;
667:
668: -- Standard call to check for call compatibility.
669: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
670: RAISE fnd_api.g_exc_unexpected_error;
671: END IF;
672:
673: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 670: RAISE fnd_api.g_exc_unexpected_error;

666: SAVEPOINT update_expression;
667:
668: -- Standard call to check for call compatibility.
669: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
670: RAISE fnd_api.g_exc_unexpected_error;
671: END IF;
672:
673: -- Initialize message list if p_init_msg_list is set to TRUE.
674: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 674: IF fnd_api.to_boolean(p_init_msg_list) THEN

670: RAISE fnd_api.g_exc_unexpected_error;
671: END IF;
672:
673: -- Initialize message list if p_init_msg_list is set to TRUE.
674: IF fnd_api.to_boolean(p_init_msg_list) THEN
675: fnd_msg_pub.initialize;
676: END IF;
677:
678: -- Initialize API return status to success

Line 679: x_return_status := fnd_api.g_ret_sts_success;

675: fnd_msg_pub.initialize;
676: END IF;
677:
678: -- Initialize API return status to success
679: x_return_status := fnd_api.g_ret_sts_success;
680:
681: -- API body
682: IF (p_name IS NULL) THEN
683: IF (fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_error)) THEN

Line 690: RAISE fnd_api.g_exc_error;

686: fnd_message.set_token('OBJ_NAME', l_prompt);
687: fnd_msg_pub.ADD;
688: END IF;
689:
690: RAISE fnd_api.g_exc_error;
691: END IF;
692:
693: OPEN exp_exists;
694: FETCH exp_exists INTO l_dummy;

Line 703: RAISE fnd_api.g_exc_error;

699: fnd_message.set_name('CN', 'CN_NAME_NOT_UNIQUE');
700: fnd_msg_pub.ADD;
701: END IF;
702:
703: RAISE fnd_api.g_exc_error;
704: END IF;
705:
706: -- see if expression is in use
707: OPEN parent_exist;

Line 717: RAISE fnd_api.g_exc_error;

713: fnd_message.set_name('CN', 'CN_EXP_IN_USE');
714: fnd_msg_pub.ADD;
715: END IF;
716:
717: RAISE fnd_api.g_exc_error;
718: END IF;
719:
720: -- parse the expression and classify it into sub types
721: classify_expression(

Line 870: IF (fnd_api.to_boolean(p_update_parent_also)) THEN

866:
867: --END IF;
868:
869: -- update parent expressions and formulas also
870: IF (fnd_api.to_boolean(p_update_parent_also)) THEN
871: NULL;
872: END IF;
873:
874: -- End of API body.

Line 877: IF fnd_api.to_boolean(p_commit) THEN

873:
874: -- End of API body.
875:
876: -- Standard check of p_commit.
877: IF fnd_api.to_boolean(p_commit) THEN
878: COMMIT WORK;
879: END IF;
880:
881: -- Standard call to get message count and if count is 1, get message info.

Line 883: , p_encoded => fnd_api.g_false);

879: END IF;
880:
881: -- Standard call to get message count and if count is 1, get message info.
882: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
883: , p_encoded => fnd_api.g_false);
884: EXCEPTION
885: WHEN fnd_api.g_exc_error THEN
886: ROLLBACK TO update_expression;
887: x_return_status := fnd_api.g_ret_sts_error;

Line 885: WHEN fnd_api.g_exc_error THEN

881: -- Standard call to get message count and if count is 1, get message info.
882: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
883: , p_encoded => fnd_api.g_false);
884: EXCEPTION
885: WHEN fnd_api.g_exc_error THEN
886: ROLLBACK TO update_expression;
887: x_return_status := fnd_api.g_ret_sts_error;
888: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
889: , p_encoded => fnd_api.g_false);

Line 887: x_return_status := fnd_api.g_ret_sts_error;

883: , p_encoded => fnd_api.g_false);
884: EXCEPTION
885: WHEN fnd_api.g_exc_error THEN
886: ROLLBACK TO update_expression;
887: x_return_status := fnd_api.g_ret_sts_error;
888: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
889: , p_encoded => fnd_api.g_false);
890: WHEN fnd_api.g_exc_unexpected_error THEN
891: ROLLBACK TO update_expression;

Line 889: , p_encoded => fnd_api.g_false);

885: WHEN fnd_api.g_exc_error THEN
886: ROLLBACK TO update_expression;
887: x_return_status := fnd_api.g_ret_sts_error;
888: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
889: , p_encoded => fnd_api.g_false);
890: WHEN fnd_api.g_exc_unexpected_error THEN
891: ROLLBACK TO update_expression;
892: x_return_status := fnd_api.g_ret_sts_unexp_error;
893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 890: WHEN fnd_api.g_exc_unexpected_error THEN

886: ROLLBACK TO update_expression;
887: x_return_status := fnd_api.g_ret_sts_error;
888: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
889: , p_encoded => fnd_api.g_false);
890: WHEN fnd_api.g_exc_unexpected_error THEN
891: ROLLBACK TO update_expression;
892: x_return_status := fnd_api.g_ret_sts_unexp_error;
893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
894: , p_encoded => fnd_api.g_false);

Line 892: x_return_status := fnd_api.g_ret_sts_unexp_error;

888: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
889: , p_encoded => fnd_api.g_false);
890: WHEN fnd_api.g_exc_unexpected_error THEN
891: ROLLBACK TO update_expression;
892: x_return_status := fnd_api.g_ret_sts_unexp_error;
893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
894: , p_encoded => fnd_api.g_false);
895: WHEN OTHERS THEN
896: ROLLBACK TO update_expression;

Line 894: , p_encoded => fnd_api.g_false);

890: WHEN fnd_api.g_exc_unexpected_error THEN
891: ROLLBACK TO update_expression;
892: x_return_status := fnd_api.g_ret_sts_unexp_error;
893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
894: , p_encoded => fnd_api.g_false);
895: WHEN OTHERS THEN
896: ROLLBACK TO update_expression;
897: x_return_status := fnd_api.g_ret_sts_unexp_error;
898:

Line 897: x_return_status := fnd_api.g_ret_sts_unexp_error;

893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
894: , p_encoded => fnd_api.g_false);
895: WHEN OTHERS THEN
896: ROLLBACK TO update_expression;
897: x_return_status := fnd_api.g_ret_sts_unexp_error;
898:
899: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
900: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
901: END IF;

Line 904: , p_encoded => fnd_api.g_false);

900: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
901: END IF;
902:
903: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
904: , p_encoded => fnd_api.g_false);
905: END update_expression;
906:
907: -- Start of comments
908: -- API name : Delete_Expression

Line 915: -- Default = FND_API.G_FALSE

911: -- Pre-reqs : None.
912: -- Parameters :
913: -- IN : p_api_version IN NUMBER Required
914: -- p_init_msg_list IN VARCHAR2 Optional
915: -- Default = FND_API.G_FALSE
916: -- p_commit IN VARCHAR2 Optional
917: -- Default = FND_API.G_FALSE
918: -- p_validation_level IN NUMBER Optional
919: -- Default = FND_API.G_VALID_LEVEL_FULL

Line 917: -- Default = FND_API.G_FALSE

913: -- IN : p_api_version IN NUMBER Required
914: -- p_init_msg_list IN VARCHAR2 Optional
915: -- Default = FND_API.G_FALSE
916: -- p_commit IN VARCHAR2 Optional
917: -- Default = FND_API.G_FALSE
918: -- p_validation_level IN NUMBER Optional
919: -- Default = FND_API.G_VALID_LEVEL_FULL
920: -- p_calc_sql_exp_id IN NUMBER
921: -- OUT : x_return_status OUT VARCHAR2(1)

Line 919: -- Default = FND_API.G_VALID_LEVEL_FULL

915: -- Default = FND_API.G_FALSE
916: -- p_commit IN VARCHAR2 Optional
917: -- Default = FND_API.G_FALSE
918: -- p_validation_level IN NUMBER Optional
919: -- Default = FND_API.G_VALID_LEVEL_FULL
920: -- p_calc_sql_exp_id IN NUMBER
921: -- OUT : x_return_status OUT VARCHAR2(1)
922: -- x_msg_count OUT NUMBER
923: -- x_msg_data OUT VARCHAR2(4000)

Line 934: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

930: --
931: -- End of comments
932: PROCEDURE delete_expression(
933: p_api_version IN NUMBER
934: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
935: , p_commit IN VARCHAR2 := fnd_api.g_false
936: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
937: , p_calc_sql_exp_id IN cn_calc_sql_exps.calc_sql_exp_id%TYPE
938: , x_return_status OUT NOCOPY VARCHAR2

Line 935: , p_commit IN VARCHAR2 := fnd_api.g_false

931: -- End of comments
932: PROCEDURE delete_expression(
933: p_api_version IN NUMBER
934: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
935: , p_commit IN VARCHAR2 := fnd_api.g_false
936: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
937: , p_calc_sql_exp_id IN cn_calc_sql_exps.calc_sql_exp_id%TYPE
938: , x_return_status OUT NOCOPY VARCHAR2
939: , x_msg_count OUT NOCOPY NUMBER

Line 936: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

932: PROCEDURE delete_expression(
933: p_api_version IN NUMBER
934: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
935: , p_commit IN VARCHAR2 := fnd_api.g_false
936: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
937: , p_calc_sql_exp_id IN cn_calc_sql_exps.calc_sql_exp_id%TYPE
938: , x_return_status OUT NOCOPY VARCHAR2
939: , x_msg_count OUT NOCOPY NUMBER
940: , x_msg_data OUT NOCOPY VARCHAR2

Line 972: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

968: -- Standard Start of API savepoint
969: SAVEPOINT delete_expression;
970:
971: -- Standard call to check for call compatibility.
972: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
973: RAISE fnd_api.g_exc_unexpected_error;
974: END IF;
975:
976: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 973: RAISE fnd_api.g_exc_unexpected_error;

969: SAVEPOINT delete_expression;
970:
971: -- Standard call to check for call compatibility.
972: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
973: RAISE fnd_api.g_exc_unexpected_error;
974: END IF;
975:
976: -- Initialize message list if p_init_msg_list is set to TRUE.
977: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 977: IF fnd_api.to_boolean(p_init_msg_list) THEN

973: RAISE fnd_api.g_exc_unexpected_error;
974: END IF;
975:
976: -- Initialize message list if p_init_msg_list is set to TRUE.
977: IF fnd_api.to_boolean(p_init_msg_list) THEN
978: fnd_msg_pub.initialize;
979: END IF;
980:
981: -- Initialize API return status to success

Line 982: x_return_status := fnd_api.g_ret_sts_success;

978: fnd_msg_pub.initialize;
979: END IF;
980:
981: -- Initialize API return status to success
982: x_return_status := fnd_api.g_ret_sts_success;
983:
984: -- API body
985: OPEN parent_exist;
986: FETCH parent_exist INTO l_dummy;

Line 995: RAISE fnd_api.g_exc_error;

991: fnd_message.set_name('CN', 'CN_EXP_IN_USE');
992: fnd_msg_pub.ADD;
993: END IF;
994:
995: RAISE fnd_api.g_exc_error;
996: END IF;
997:
998: cn_calc_sql_exps_pkg.delete_row(x_calc_sql_exp_id => p_calc_sql_exp_id);
999:

Line 1008: IF fnd_api.to_boolean(p_commit) THEN

1004:
1005: -- End of API body.
1006:
1007: -- Standard check of p_commit.
1008: IF fnd_api.to_boolean(p_commit) THEN
1009: COMMIT WORK;
1010: END IF;
1011:
1012: -- Standard call to get message count and if count is 1, get message info.

Line 1014: , p_encoded => fnd_api.g_false);

1010: END IF;
1011:
1012: -- Standard call to get message count and if count is 1, get message info.
1013: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1014: , p_encoded => fnd_api.g_false);
1015: EXCEPTION
1016: WHEN fnd_api.g_exc_error THEN
1017: ROLLBACK TO delete_expression;
1018: x_return_status := fnd_api.g_ret_sts_error;

Line 1016: WHEN fnd_api.g_exc_error THEN

1012: -- Standard call to get message count and if count is 1, get message info.
1013: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1014: , p_encoded => fnd_api.g_false);
1015: EXCEPTION
1016: WHEN fnd_api.g_exc_error THEN
1017: ROLLBACK TO delete_expression;
1018: x_return_status := fnd_api.g_ret_sts_error;
1019: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1020: , p_encoded => fnd_api.g_false);

Line 1018: x_return_status := fnd_api.g_ret_sts_error;

1014: , p_encoded => fnd_api.g_false);
1015: EXCEPTION
1016: WHEN fnd_api.g_exc_error THEN
1017: ROLLBACK TO delete_expression;
1018: x_return_status := fnd_api.g_ret_sts_error;
1019: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1020: , p_encoded => fnd_api.g_false);
1021: WHEN fnd_api.g_exc_unexpected_error THEN
1022: ROLLBACK TO delete_expression;

Line 1020: , p_encoded => fnd_api.g_false);

1016: WHEN fnd_api.g_exc_error THEN
1017: ROLLBACK TO delete_expression;
1018: x_return_status := fnd_api.g_ret_sts_error;
1019: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1020: , p_encoded => fnd_api.g_false);
1021: WHEN fnd_api.g_exc_unexpected_error THEN
1022: ROLLBACK TO delete_expression;
1023: x_return_status := fnd_api.g_ret_sts_unexp_error;
1024: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 1021: WHEN fnd_api.g_exc_unexpected_error THEN

1017: ROLLBACK TO delete_expression;
1018: x_return_status := fnd_api.g_ret_sts_error;
1019: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1020: , p_encoded => fnd_api.g_false);
1021: WHEN fnd_api.g_exc_unexpected_error THEN
1022: ROLLBACK TO delete_expression;
1023: x_return_status := fnd_api.g_ret_sts_unexp_error;
1024: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1025: , p_encoded => fnd_api.g_false);

Line 1023: x_return_status := fnd_api.g_ret_sts_unexp_error;

1019: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1020: , p_encoded => fnd_api.g_false);
1021: WHEN fnd_api.g_exc_unexpected_error THEN
1022: ROLLBACK TO delete_expression;
1023: x_return_status := fnd_api.g_ret_sts_unexp_error;
1024: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1025: , p_encoded => fnd_api.g_false);
1026: WHEN OTHERS THEN
1027: ROLLBACK TO delete_expression;

Line 1025: , p_encoded => fnd_api.g_false);

1021: WHEN fnd_api.g_exc_unexpected_error THEN
1022: ROLLBACK TO delete_expression;
1023: x_return_status := fnd_api.g_ret_sts_unexp_error;
1024: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1025: , p_encoded => fnd_api.g_false);
1026: WHEN OTHERS THEN
1027: ROLLBACK TO delete_expression;
1028: x_return_status := fnd_api.g_ret_sts_unexp_error;
1029:

Line 1028: x_return_status := fnd_api.g_ret_sts_unexp_error;

1024: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1025: , p_encoded => fnd_api.g_false);
1026: WHEN OTHERS THEN
1027: ROLLBACK TO delete_expression;
1028: x_return_status := fnd_api.g_ret_sts_unexp_error;
1029:
1030: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1031: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1032: END IF;

Line 1035: , p_encoded => fnd_api.g_false);

1031: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1032: END IF;
1033:
1034: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1035: , p_encoded => fnd_api.g_false);
1036: END delete_expression;
1037:
1038: /*-- Start of comments
1039: -- API name : Get_Parent_Expressions

Line 1046: -- Default = FND_API.G_FALSE

1042: -- Pre-reqs : None.
1043: -- Parameters :
1044: -- IN : p_api_version IN NUMBER Required
1045: -- p_init_msg_list IN VARCHAR2 Optional
1046: -- Default = FND_API.G_FALSE
1047: -- p_commit IN VARCHAR2 Optional
1048: -- Default = FND_API.G_FALSE
1049: -- p_validation_level IN NUMBER Optional
1050: -- Default = FND_API.G_VALID_LEVEL_FULL

Line 1048: -- Default = FND_API.G_FALSE

1044: -- IN : p_api_version IN NUMBER Required
1045: -- p_init_msg_list IN VARCHAR2 Optional
1046: -- Default = FND_API.G_FALSE
1047: -- p_commit IN VARCHAR2 Optional
1048: -- Default = FND_API.G_FALSE
1049: -- p_validation_level IN NUMBER Optional
1050: -- Default = FND_API.G_VALID_LEVEL_FULL
1051: -- p_calc_sql_exp_id IN NUMBER
1052: -- OUT : x_parents_tbl OUT expression_tbl_type

Line 1050: -- Default = FND_API.G_VALID_LEVEL_FULL

1046: -- Default = FND_API.G_FALSE
1047: -- p_commit IN VARCHAR2 Optional
1048: -- Default = FND_API.G_FALSE
1049: -- p_validation_level IN NUMBER Optional
1050: -- Default = FND_API.G_VALID_LEVEL_FULL
1051: -- p_calc_sql_exp_id IN NUMBER
1052: -- OUT : x_parents_tbl OUT expression_tbl_type
1053: -- x_return_status OUT VARCHAR2(1)
1054: -- x_msg_count OUT NUMBER

Line 1064: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE ,

1060: --
1061: -- End of comments
1062: PROCEDURE Get_Parent_Expressions
1063: (p_api_version IN NUMBER ,
1064: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE ,
1065: p_commit IN VARCHAR2 := FND_API.G_FALSE ,
1066: p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL ,
1067: p_calc_sql_exp_id IN CN_CALC_SQL_EXPS.CALC_SQL_EXP_ID%TYPE,
1068: x_parents_tbl OUT NOCOPY parent_expression_tbl_type ,

Line 1065: p_commit IN VARCHAR2 := FND_API.G_FALSE ,

1061: -- End of comments
1062: PROCEDURE Get_Parent_Expressions
1063: (p_api_version IN NUMBER ,
1064: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE ,
1065: p_commit IN VARCHAR2 := FND_API.G_FALSE ,
1066: p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL ,
1067: p_calc_sql_exp_id IN CN_CALC_SQL_EXPS.CALC_SQL_EXP_ID%TYPE,
1068: x_parents_tbl OUT NOCOPY parent_expression_tbl_type ,
1069: x_return_status OUT NOCOPY VARCHAR2 ,

Line 1066: p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL ,

1062: PROCEDURE Get_Parent_Expressions
1063: (p_api_version IN NUMBER ,
1064: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE ,
1065: p_commit IN VARCHAR2 := FND_API.G_FALSE ,
1066: p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL ,
1067: p_calc_sql_exp_id IN CN_CALC_SQL_EXPS.CALC_SQL_EXP_ID%TYPE,
1068: x_parents_tbl OUT NOCOPY parent_expression_tbl_type ,
1069: x_return_status OUT NOCOPY VARCHAR2 ,
1070: x_msg_count OUT NOCOPY NUMBER ,

Line 1107: IF NOT FND_API.Compatible_API_Call

1103: OR f_calc_sql_exp_id = p_calc_sql_exp_id));
1104:
1105: BEGIN
1106: -- Standard call to check for call compatibility.
1107: IF NOT FND_API.Compatible_API_Call
1108: (l_api_version ,
1109: p_api_version ,
1110: l_api_name ,
1111: G_PKG_NAME )

Line 1113: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

1109: p_api_version ,
1110: l_api_name ,
1111: G_PKG_NAME )
1112: THEN
1113: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1114: END IF;
1115: -- Initialize message list if p_init_msg_list is set to TRUE.
1116: IF FND_API.to_Boolean( p_init_msg_list ) THEN
1117: FND_MSG_PUB.initialize;

Line 1116: IF FND_API.to_Boolean( p_init_msg_list ) THEN

1112: THEN
1113: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1114: END IF;
1115: -- Initialize message list if p_init_msg_list is set to TRUE.
1116: IF FND_API.to_Boolean( p_init_msg_list ) THEN
1117: FND_MSG_PUB.initialize;
1118: END IF;
1119: -- Initialize API return status to success
1120: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 1120: x_return_status := FND_API.G_RET_STS_SUCCESS;

1116: IF FND_API.to_Boolean( p_init_msg_list ) THEN
1117: FND_MSG_PUB.initialize;
1118: END IF;
1119: -- Initialize API return status to success
1120: x_return_status := FND_API.G_RET_STS_SUCCESS;
1121:
1122: -- API body
1123: FOR parent_name IN parent_names LOOP
1124: x_parents_tbl(i) := parent_name.name;

Line 1131: IF FND_API.To_Boolean( p_commit ) THEN

1127:
1128: -- End of API body.
1129:
1130: -- Standard check of p_commit.
1131: IF FND_API.To_Boolean( p_commit ) THEN
1132: COMMIT WORK;
1133: END IF;
1134: -- Standard call to get message count and if count is 1, get message info.
1135: FND_MSG_PUB.count_and_get

Line 1138: p_encoded => FND_API.G_FALSE );

1134: -- Standard call to get message count and if count is 1, get message info.
1135: FND_MSG_PUB.count_and_get
1136: (p_count => x_msg_count ,
1137: p_data => x_msg_data ,
1138: p_encoded => FND_API.G_FALSE );
1139: EXCEPTION
1140: WHEN FND_API.G_EXC_ERROR THEN
1141: x_return_status := FND_API.G_RET_STS_ERROR ;
1142: FND_MSG_PUB.count_and_get

Line 1140: WHEN FND_API.G_EXC_ERROR THEN

1136: (p_count => x_msg_count ,
1137: p_data => x_msg_data ,
1138: p_encoded => FND_API.G_FALSE );
1139: EXCEPTION
1140: WHEN FND_API.G_EXC_ERROR THEN
1141: x_return_status := FND_API.G_RET_STS_ERROR ;
1142: FND_MSG_PUB.count_and_get
1143: (p_count => x_msg_count ,
1144: p_data => x_msg_data ,

Line 1141: x_return_status := FND_API.G_RET_STS_ERROR ;

1137: p_data => x_msg_data ,
1138: p_encoded => FND_API.G_FALSE );
1139: EXCEPTION
1140: WHEN FND_API.G_EXC_ERROR THEN
1141: x_return_status := FND_API.G_RET_STS_ERROR ;
1142: FND_MSG_PUB.count_and_get
1143: (p_count => x_msg_count ,
1144: p_data => x_msg_data ,
1145: p_encoded => FND_API.G_FALSE );

Line 1145: p_encoded => FND_API.G_FALSE );

1141: x_return_status := FND_API.G_RET_STS_ERROR ;
1142: FND_MSG_PUB.count_and_get
1143: (p_count => x_msg_count ,
1144: p_data => x_msg_data ,
1145: p_encoded => FND_API.G_FALSE );
1146: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
1147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1148: FND_MSG_PUB.count_and_get
1149: (p_count => x_msg_count ,

Line 1146: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

1142: FND_MSG_PUB.count_and_get
1143: (p_count => x_msg_count ,
1144: p_data => x_msg_data ,
1145: p_encoded => FND_API.G_FALSE );
1146: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
1147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1148: FND_MSG_PUB.count_and_get
1149: (p_count => x_msg_count ,
1150: p_data => x_msg_data ,

Line 1147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1143: (p_count => x_msg_count ,
1144: p_data => x_msg_data ,
1145: p_encoded => FND_API.G_FALSE );
1146: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
1147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1148: FND_MSG_PUB.count_and_get
1149: (p_count => x_msg_count ,
1150: p_data => x_msg_data ,
1151: p_encoded => FND_API.G_FALSE );

Line 1151: p_encoded => FND_API.G_FALSE );

1147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1148: FND_MSG_PUB.count_and_get
1149: (p_count => x_msg_count ,
1150: p_data => x_msg_data ,
1151: p_encoded => FND_API.G_FALSE );
1152: WHEN OTHERS THEN
1153: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1154: IF FND_MSG_PUB.check_msg_level
1155: (FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR)

Line 1153: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1149: (p_count => x_msg_count ,
1150: p_data => x_msg_data ,
1151: p_encoded => FND_API.G_FALSE );
1152: WHEN OTHERS THEN
1153: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1154: IF FND_MSG_PUB.check_msg_level
1155: (FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR)
1156: THEN
1157: FND_MSG_PUB.add_exc_msg

Line 1164: p_encoded => FND_API.G_FALSE );

1160: END IF;
1161: FND_MSG_PUB.count_and_get
1162: (p_count => x_msg_count ,
1163: p_data => x_msg_data ,
1164: p_encoded => FND_API.G_FALSE );
1165: END Get_Parent_Expressions; */
1166:
1167: /* PROCEDURE get_expr_summary
1168: (p_first IN NUMBER,

Line 1549: RAISE fnd_api.g_exc_error;

1545: BEGIN
1546: IF p_node_type = p_original_node_type AND p_current_id = p_original_node_id AND p_level > 0 THEN
1547: fnd_message.set_name('CN', 'CN_PE_CANNOT_REF_ITSEF');
1548: fnd_msg_pub.ADD;
1549: RAISE fnd_api.g_exc_error;
1550: END IF;
1551:
1552: IF p_node_type = 'P' THEN
1553: IF p_level > 0 THEN

Line 1593: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1589: -- elements referenced directly or indirectly
1590: -- pass in a node type (formula=F, plan element=P, expression=E), and the ID
1591: PROCEDURE get_dependent_plan_elts(
1592: p_api_version IN NUMBER
1593: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1594: , p_commit IN VARCHAR2 := fnd_api.g_false
1595: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1596: , p_node_type IN VARCHAR2
1597: , p_node_id IN NUMBER

Line 1594: , p_commit IN VARCHAR2 := fnd_api.g_false

1590: -- pass in a node type (formula=F, plan element=P, expression=E), and the ID
1591: PROCEDURE get_dependent_plan_elts(
1592: p_api_version IN NUMBER
1593: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1594: , p_commit IN VARCHAR2 := fnd_api.g_false
1595: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1596: , p_node_type IN VARCHAR2
1597: , p_node_id IN NUMBER
1598: , x_plan_elt_id_tbl OUT NOCOPY num_tbl_type

Line 1595: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

1591: PROCEDURE get_dependent_plan_elts(
1592: p_api_version IN NUMBER
1593: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1594: , p_commit IN VARCHAR2 := fnd_api.g_false
1595: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1596: , p_node_type IN VARCHAR2
1597: , p_node_id IN NUMBER
1598: , x_plan_elt_id_tbl OUT NOCOPY num_tbl_type
1599: , x_return_status OUT NOCOPY VARCHAR2

Line 1607: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

1603: l_api_name CONSTANT VARCHAR2(30) := 'get_dependent_plan_elts';
1604: l_api_version CONSTANT NUMBER := 1.0;
1605: BEGIN
1606: -- Standard call to check for call compatibility.
1607: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1608: RAISE fnd_api.g_exc_unexpected_error;
1609: END IF;
1610:
1611: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 1608: RAISE fnd_api.g_exc_unexpected_error;

1604: l_api_version CONSTANT NUMBER := 1.0;
1605: BEGIN
1606: -- Standard call to check for call compatibility.
1607: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1608: RAISE fnd_api.g_exc_unexpected_error;
1609: END IF;
1610:
1611: -- Initialize message list if p_init_msg_list is set to TRUE.
1612: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 1612: IF fnd_api.to_boolean(p_init_msg_list) THEN

1608: RAISE fnd_api.g_exc_unexpected_error;
1609: END IF;
1610:
1611: -- Initialize message list if p_init_msg_list is set to TRUE.
1612: IF fnd_api.to_boolean(p_init_msg_list) THEN
1613: fnd_msg_pub.initialize;
1614: END IF;
1615:
1616: -- Initialize API return status to success

Line 1617: x_return_status := fnd_api.g_ret_sts_success;

1613: fnd_msg_pub.initialize;
1614: END IF;
1615:
1616: -- Initialize API return status to success
1617: x_return_status := fnd_api.g_ret_sts_success;
1618: -- API body
1619: dfs(p_node_type, p_node_id, p_node_type, p_node_id, 0, x_plan_elt_id_tbl);
1620:
1621: -- Standard check of p_commit.

Line 1622: IF fnd_api.to_boolean(p_commit) THEN

1618: -- API body
1619: dfs(p_node_type, p_node_id, p_node_type, p_node_id, 0, x_plan_elt_id_tbl);
1620:
1621: -- Standard check of p_commit.
1622: IF fnd_api.to_boolean(p_commit) THEN
1623: COMMIT WORK;
1624: END IF;
1625:
1626: -- Standard call to get message count and if count is 1, get message info.

Line 1628: , p_encoded => fnd_api.g_false);

1624: END IF;
1625:
1626: -- Standard call to get message count and if count is 1, get message info.
1627: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1628: , p_encoded => fnd_api.g_false);
1629: EXCEPTION
1630: WHEN fnd_api.g_exc_error THEN
1631: x_return_status := fnd_api.g_ret_sts_error;
1632: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 1630: WHEN fnd_api.g_exc_error THEN

1626: -- Standard call to get message count and if count is 1, get message info.
1627: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1628: , p_encoded => fnd_api.g_false);
1629: EXCEPTION
1630: WHEN fnd_api.g_exc_error THEN
1631: x_return_status := fnd_api.g_ret_sts_error;
1632: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1633: , p_encoded => fnd_api.g_false);
1634: WHEN fnd_api.g_exc_unexpected_error THEN

Line 1631: x_return_status := fnd_api.g_ret_sts_error;

1627: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1628: , p_encoded => fnd_api.g_false);
1629: EXCEPTION
1630: WHEN fnd_api.g_exc_error THEN
1631: x_return_status := fnd_api.g_ret_sts_error;
1632: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1633: , p_encoded => fnd_api.g_false);
1634: WHEN fnd_api.g_exc_unexpected_error THEN
1635: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1633: , p_encoded => fnd_api.g_false);

1629: EXCEPTION
1630: WHEN fnd_api.g_exc_error THEN
1631: x_return_status := fnd_api.g_ret_sts_error;
1632: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1633: , p_encoded => fnd_api.g_false);
1634: WHEN fnd_api.g_exc_unexpected_error THEN
1635: x_return_status := fnd_api.g_ret_sts_unexp_error;
1636: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1637: , p_encoded => fnd_api.g_false);

Line 1634: WHEN fnd_api.g_exc_unexpected_error THEN

1630: WHEN fnd_api.g_exc_error THEN
1631: x_return_status := fnd_api.g_ret_sts_error;
1632: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1633: , p_encoded => fnd_api.g_false);
1634: WHEN fnd_api.g_exc_unexpected_error THEN
1635: x_return_status := fnd_api.g_ret_sts_unexp_error;
1636: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1637: , p_encoded => fnd_api.g_false);
1638: WHEN OTHERS THEN

Line 1635: x_return_status := fnd_api.g_ret_sts_unexp_error;

1631: x_return_status := fnd_api.g_ret_sts_error;
1632: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1633: , p_encoded => fnd_api.g_false);
1634: WHEN fnd_api.g_exc_unexpected_error THEN
1635: x_return_status := fnd_api.g_ret_sts_unexp_error;
1636: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1637: , p_encoded => fnd_api.g_false);
1638: WHEN OTHERS THEN
1639: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1637: , p_encoded => fnd_api.g_false);

1633: , p_encoded => fnd_api.g_false);
1634: WHEN fnd_api.g_exc_unexpected_error THEN
1635: x_return_status := fnd_api.g_ret_sts_unexp_error;
1636: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1637: , p_encoded => fnd_api.g_false);
1638: WHEN OTHERS THEN
1639: x_return_status := fnd_api.g_ret_sts_unexp_error;
1640:
1641: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN

Line 1639: x_return_status := fnd_api.g_ret_sts_unexp_error;

1635: x_return_status := fnd_api.g_ret_sts_unexp_error;
1636: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1637: , p_encoded => fnd_api.g_false);
1638: WHEN OTHERS THEN
1639: x_return_status := fnd_api.g_ret_sts_unexp_error;
1640:
1641: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1642: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1643: END IF;

Line 1646: , p_encoded => fnd_api.g_false);

1642: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1643: END IF;
1644:
1645: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1646: , p_encoded => fnd_api.g_false);
1647: END get_dependent_plan_elts;
1648:
1649: -- private procedure used in get_parent_plan_elts
1650: PROCEDURE dfs2(

Line 1690: RAISE fnd_api.g_exc_error;

1686: BEGIN
1687: IF p_node_type = p_original_node_type AND p_current_id = p_original_node_id AND p_level > 0 THEN
1688: fnd_message.set_name('CN', 'CN_PE_CANNOT_REF_ITSEF');
1689: fnd_msg_pub.ADD;
1690: RAISE fnd_api.g_exc_error;
1691: END IF;
1692:
1693: IF p_node_type = g_node_type AND
1694: p_original_node_type = g_original_node_type AND

Line 1745: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1741: -- elements that reference it directly or indirectly
1742: -- pass in a node type (formula=F, plan element=P, expression=E), and the ID
1743: PROCEDURE get_parent_plan_elts(
1744: p_api_version IN NUMBER
1745: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1746: , p_commit IN VARCHAR2 := fnd_api.g_false
1747: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1748: , p_node_type IN VARCHAR2
1749: , p_node_id IN NUMBER

Line 1746: , p_commit IN VARCHAR2 := fnd_api.g_false

1742: -- pass in a node type (formula=F, plan element=P, expression=E), and the ID
1743: PROCEDURE get_parent_plan_elts(
1744: p_api_version IN NUMBER
1745: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1746: , p_commit IN VARCHAR2 := fnd_api.g_false
1747: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1748: , p_node_type IN VARCHAR2
1749: , p_node_id IN NUMBER
1750: , x_plan_elt_id_tbl OUT NOCOPY num_tbl_type

Line 1747: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

1743: PROCEDURE get_parent_plan_elts(
1744: p_api_version IN NUMBER
1745: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1746: , p_commit IN VARCHAR2 := fnd_api.g_false
1747: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1748: , p_node_type IN VARCHAR2
1749: , p_node_id IN NUMBER
1750: , x_plan_elt_id_tbl OUT NOCOPY num_tbl_type
1751: , x_return_status OUT NOCOPY VARCHAR2

Line 1759: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

1755: l_api_name CONSTANT VARCHAR2(30) := 'get_parent_plan_elts';
1756: l_api_version CONSTANT NUMBER := 1.0;
1757: BEGIN
1758: -- Standard call to check for call compatibility.
1759: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1760: RAISE fnd_api.g_exc_unexpected_error;
1761: END IF;
1762:
1763: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 1760: RAISE fnd_api.g_exc_unexpected_error;

1756: l_api_version CONSTANT NUMBER := 1.0;
1757: BEGIN
1758: -- Standard call to check for call compatibility.
1759: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1760: RAISE fnd_api.g_exc_unexpected_error;
1761: END IF;
1762:
1763: -- Initialize message list if p_init_msg_list is set to TRUE.
1764: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 1764: IF fnd_api.to_boolean(p_init_msg_list) THEN

1760: RAISE fnd_api.g_exc_unexpected_error;
1761: END IF;
1762:
1763: -- Initialize message list if p_init_msg_list is set to TRUE.
1764: IF fnd_api.to_boolean(p_init_msg_list) THEN
1765: fnd_msg_pub.initialize;
1766: END IF;
1767:
1768: -- Initialize API return status to success

Line 1769: x_return_status := fnd_api.g_ret_sts_success;

1765: fnd_msg_pub.initialize;
1766: END IF;
1767:
1768: -- Initialize API return status to success
1769: x_return_status := fnd_api.g_ret_sts_success;
1770: -- API body
1771: dfs2(p_node_type, p_node_id, p_node_type, p_node_id, 0, x_plan_elt_id_tbl);
1772:
1773: -- Standard check of p_commit.

Line 1774: IF fnd_api.to_boolean(p_commit) THEN

1770: -- API body
1771: dfs2(p_node_type, p_node_id, p_node_type, p_node_id, 0, x_plan_elt_id_tbl);
1772:
1773: -- Standard check of p_commit.
1774: IF fnd_api.to_boolean(p_commit) THEN
1775: COMMIT WORK;
1776: END IF;
1777:
1778: -- Standard call to get message count and if count is 1, get message info.

Line 1780: , p_encoded => fnd_api.g_false);

1776: END IF;
1777:
1778: -- Standard call to get message count and if count is 1, get message info.
1779: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1780: , p_encoded => fnd_api.g_false);
1781: EXCEPTION
1782: WHEN fnd_api.g_exc_error THEN
1783: x_return_status := fnd_api.g_ret_sts_error;
1784: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 1782: WHEN fnd_api.g_exc_error THEN

1778: -- Standard call to get message count and if count is 1, get message info.
1779: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1780: , p_encoded => fnd_api.g_false);
1781: EXCEPTION
1782: WHEN fnd_api.g_exc_error THEN
1783: x_return_status := fnd_api.g_ret_sts_error;
1784: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1785: , p_encoded => fnd_api.g_false);
1786: WHEN fnd_api.g_exc_unexpected_error THEN

Line 1783: x_return_status := fnd_api.g_ret_sts_error;

1779: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1780: , p_encoded => fnd_api.g_false);
1781: EXCEPTION
1782: WHEN fnd_api.g_exc_error THEN
1783: x_return_status := fnd_api.g_ret_sts_error;
1784: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1785: , p_encoded => fnd_api.g_false);
1786: WHEN fnd_api.g_exc_unexpected_error THEN
1787: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1785: , p_encoded => fnd_api.g_false);

1781: EXCEPTION
1782: WHEN fnd_api.g_exc_error THEN
1783: x_return_status := fnd_api.g_ret_sts_error;
1784: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1785: , p_encoded => fnd_api.g_false);
1786: WHEN fnd_api.g_exc_unexpected_error THEN
1787: x_return_status := fnd_api.g_ret_sts_unexp_error;
1788: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1789: , p_encoded => fnd_api.g_false);

Line 1786: WHEN fnd_api.g_exc_unexpected_error THEN

1782: WHEN fnd_api.g_exc_error THEN
1783: x_return_status := fnd_api.g_ret_sts_error;
1784: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1785: , p_encoded => fnd_api.g_false);
1786: WHEN fnd_api.g_exc_unexpected_error THEN
1787: x_return_status := fnd_api.g_ret_sts_unexp_error;
1788: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1789: , p_encoded => fnd_api.g_false);
1790: WHEN OTHERS THEN

Line 1787: x_return_status := fnd_api.g_ret_sts_unexp_error;

1783: x_return_status := fnd_api.g_ret_sts_error;
1784: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1785: , p_encoded => fnd_api.g_false);
1786: WHEN fnd_api.g_exc_unexpected_error THEN
1787: x_return_status := fnd_api.g_ret_sts_unexp_error;
1788: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1789: , p_encoded => fnd_api.g_false);
1790: WHEN OTHERS THEN
1791: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1789: , p_encoded => fnd_api.g_false);

1785: , p_encoded => fnd_api.g_false);
1786: WHEN fnd_api.g_exc_unexpected_error THEN
1787: x_return_status := fnd_api.g_ret_sts_unexp_error;
1788: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1789: , p_encoded => fnd_api.g_false);
1790: WHEN OTHERS THEN
1791: x_return_status := fnd_api.g_ret_sts_unexp_error;
1792:
1793: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN

Line 1791: x_return_status := fnd_api.g_ret_sts_unexp_error;

1787: x_return_status := fnd_api.g_ret_sts_unexp_error;
1788: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1789: , p_encoded => fnd_api.g_false);
1790: WHEN OTHERS THEN
1791: x_return_status := fnd_api.g_ret_sts_unexp_error;
1792:
1793: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1794: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1795: END IF;

Line 1798: , p_encoded => fnd_api.g_false);

1794: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
1795: END IF;
1796:
1797: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
1798: , p_encoded => fnd_api.g_false);
1799: END get_parent_plan_elts;
1800:
1801: PROCEDURE parse_sql_select(
1802: p_api_version IN NUMBER

Line 1803: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1799: END get_parent_plan_elts;
1800:
1801: PROCEDURE parse_sql_select(
1802: p_api_version IN NUMBER
1803: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1804: , p_commit IN VARCHAR2 := fnd_api.g_false
1805: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1806: , p_sql_select IN OUT NOCOPY VARCHAR2
1807: , x_piped_sql_select OUT NOCOPY VARCHAR2

Line 1804: , p_commit IN VARCHAR2 := fnd_api.g_false

1800:
1801: PROCEDURE parse_sql_select(
1802: p_api_version IN NUMBER
1803: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1804: , p_commit IN VARCHAR2 := fnd_api.g_false
1805: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1806: , p_sql_select IN OUT NOCOPY VARCHAR2
1807: , x_piped_sql_select OUT NOCOPY VARCHAR2
1808: , x_expr_disp OUT NOCOPY VARCHAR2

Line 1805: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

1801: PROCEDURE parse_sql_select(
1802: p_api_version IN NUMBER
1803: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1804: , p_commit IN VARCHAR2 := fnd_api.g_false
1805: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
1806: , p_sql_select IN OUT NOCOPY VARCHAR2
1807: , x_piped_sql_select OUT NOCOPY VARCHAR2
1808: , x_expr_disp OUT NOCOPY VARCHAR2
1809: , x_piped_expr_disp OUT NOCOPY VARCHAR2

Line 1909: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

1905: FROM user_objects
1906: WHERE object_type = 'FUNCTION' AND status = 'VALID';
1907: BEGIN
1908: -- Standard call to check for call compatibility.
1909: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1910: RAISE fnd_api.g_exc_unexpected_error;
1911: END IF;
1912:
1913: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 1910: RAISE fnd_api.g_exc_unexpected_error;

1906: WHERE object_type = 'FUNCTION' AND status = 'VALID';
1907: BEGIN
1908: -- Standard call to check for call compatibility.
1909: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
1910: RAISE fnd_api.g_exc_unexpected_error;
1911: END IF;
1912:
1913: -- Initialize message list if p_init_msg_list is set to TRUE.
1914: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 1914: IF fnd_api.to_boolean(p_init_msg_list) THEN

1910: RAISE fnd_api.g_exc_unexpected_error;
1911: END IF;
1912:
1913: -- Initialize message list if p_init_msg_list is set to TRUE.
1914: IF fnd_api.to_boolean(p_init_msg_list) THEN
1915: fnd_msg_pub.initialize;
1916: END IF;
1917:
1918: -- Initialize API return status to success

Line 1919: x_return_status := fnd_api.g_ret_sts_success;

1915: fnd_msg_pub.initialize;
1916: END IF;
1917:
1918: -- Initialize API return status to success
1919: x_return_status := fnd_api.g_ret_sts_success;
1920: -- translate RateResult and ForecastAmount
1921: disp_pieces(1) := cn_api.get_lkup_meaning('RATE_TABLE_RESULT', 'EXPRESSION_TYPE');
1922: disp_pieces(2) := cn_api.get_lkup_meaning('FORECAST_AMOUNT', 'EXPRESSION_TYPE');
1923:

Line 1964: RAISE fnd_api.g_exc_error;

1960:
1961: IF l_ix = 0 THEN
1962: fnd_message.set_name('CN', 'CN_SQL_SELECT_PARSE_ERR');
1963: fnd_msg_pub.ADD;
1964: RAISE fnd_api.g_exc_error;
1965: END IF;
1966:
1967: x_piped_sql_select := x_piped_sql_select || SUBSTR(l_sql_select_left, 1, l_ix) || '|';
1968: x_piped_expr_disp := x_piped_expr_disp || SUBSTR(l_sql_select_left, 1, l_ix) || '|';

Line 2054: RAISE fnd_api.g_exc_error;

2050:
2051: IF l_disp_seg IS NULL THEN
2052: fnd_message.set_name('CN', 'CN_SQL_SELECT_PARSE_ERR');
2053: fnd_msg_pub.ADD;
2054: RAISE fnd_api.g_exc_error;
2055: END IF;
2056:
2057: -- add to sql from
2058: IF (x_piped_sql_from IS NULL OR INSTR(x_piped_sql_from, l_table_name) = 0) THEN

Line 2083: RAISE fnd_api.g_exc_error;

2079:
2080: IF l_disp_seg IS NULL THEN
2081: fnd_message.set_name('CN', 'CN_SQL_SELECT_PARSE_ERR');
2082: fnd_msg_pub.ADD;
2083: RAISE fnd_api.g_exc_error;
2084: END IF;
2085:
2086: x_piped_sql_select := x_piped_sql_select || '.' || l_seg || '|';
2087: x_piped_expr_disp := x_piped_expr_disp || '.' || l_disp_seg || '|';

Line 2095: RAISE fnd_api.g_exc_unexpected_error;

2091:
2092: IF ct = 400 THEN
2093: fnd_message.set_name('CN', 'CN_SQL_SELECT_PARSE_ERR');
2094: fnd_msg_pub.ADD;
2095: RAISE fnd_api.g_exc_unexpected_error;
2096: END IF;
2097:
2098: IF success = FALSE THEN
2099: EXIT;

Line 2114: IF fnd_api.to_boolean(p_commit) THEN

2110: x_sql_from := REPLACE(SUBSTR(x_piped_sql_from, 1, LENGTH(x_piped_sql_from) - 1), '|'
2111: , ', '); -- trim last comma
2112:
2113: -- Standard check of p_commit.
2114: IF fnd_api.to_boolean(p_commit) THEN
2115: COMMIT WORK;
2116: END IF;
2117:
2118: -- Standard call to get message count and if count is 1, get message info.

Line 2120: , p_encoded => fnd_api.g_false);

2116: END IF;
2117:
2118: -- Standard call to get message count and if count is 1, get message info.
2119: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2120: , p_encoded => fnd_api.g_false);
2121: EXCEPTION
2122: WHEN fnd_api.g_exc_error THEN
2123: x_return_status := fnd_api.g_ret_sts_error;
2124: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 2122: WHEN fnd_api.g_exc_error THEN

2118: -- Standard call to get message count and if count is 1, get message info.
2119: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2120: , p_encoded => fnd_api.g_false);
2121: EXCEPTION
2122: WHEN fnd_api.g_exc_error THEN
2123: x_return_status := fnd_api.g_ret_sts_error;
2124: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2125: , p_encoded => fnd_api.g_false);
2126: WHEN fnd_api.g_exc_unexpected_error THEN

Line 2123: x_return_status := fnd_api.g_ret_sts_error;

2119: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2120: , p_encoded => fnd_api.g_false);
2121: EXCEPTION
2122: WHEN fnd_api.g_exc_error THEN
2123: x_return_status := fnd_api.g_ret_sts_error;
2124: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2125: , p_encoded => fnd_api.g_false);
2126: WHEN fnd_api.g_exc_unexpected_error THEN
2127: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 2125: , p_encoded => fnd_api.g_false);

2121: EXCEPTION
2122: WHEN fnd_api.g_exc_error THEN
2123: x_return_status := fnd_api.g_ret_sts_error;
2124: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2125: , p_encoded => fnd_api.g_false);
2126: WHEN fnd_api.g_exc_unexpected_error THEN
2127: x_return_status := fnd_api.g_ret_sts_unexp_error;
2128: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2129: , p_encoded => fnd_api.g_false);

Line 2126: WHEN fnd_api.g_exc_unexpected_error THEN

2122: WHEN fnd_api.g_exc_error THEN
2123: x_return_status := fnd_api.g_ret_sts_error;
2124: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2125: , p_encoded => fnd_api.g_false);
2126: WHEN fnd_api.g_exc_unexpected_error THEN
2127: x_return_status := fnd_api.g_ret_sts_unexp_error;
2128: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2129: , p_encoded => fnd_api.g_false);
2130: WHEN OTHERS THEN

Line 2127: x_return_status := fnd_api.g_ret_sts_unexp_error;

2123: x_return_status := fnd_api.g_ret_sts_error;
2124: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2125: , p_encoded => fnd_api.g_false);
2126: WHEN fnd_api.g_exc_unexpected_error THEN
2127: x_return_status := fnd_api.g_ret_sts_unexp_error;
2128: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2129: , p_encoded => fnd_api.g_false);
2130: WHEN OTHERS THEN
2131: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 2129: , p_encoded => fnd_api.g_false);

2125: , p_encoded => fnd_api.g_false);
2126: WHEN fnd_api.g_exc_unexpected_error THEN
2127: x_return_status := fnd_api.g_ret_sts_unexp_error;
2128: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2129: , p_encoded => fnd_api.g_false);
2130: WHEN OTHERS THEN
2131: x_return_status := fnd_api.g_ret_sts_unexp_error;
2132:
2133: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN

Line 2131: x_return_status := fnd_api.g_ret_sts_unexp_error;

2127: x_return_status := fnd_api.g_ret_sts_unexp_error;
2128: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2129: , p_encoded => fnd_api.g_false);
2130: WHEN OTHERS THEN
2131: x_return_status := fnd_api.g_ret_sts_unexp_error;
2132:
2133: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2134: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2135: END IF;

Line 2138: , p_encoded => fnd_api.g_false);

2134: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2135: END IF;
2136:
2137: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2138: , p_encoded => fnd_api.g_false);
2139: END parse_sql_select;
2140:
2141: PROCEDURE import(
2142: errbuf OUT NOCOPY VARCHAR2

Line 2269: , p_init_msg_list => fnd_api.g_true

2265:
2266: -- build components of record
2267: parse_sql_select(
2268: p_api_version => 1.0
2269: , p_init_msg_list => fnd_api.g_true
2270: , p_sql_select => l_api_rec.sql_select
2271: , x_piped_sql_select => l_piped_sql_select
2272: , x_expr_disp => l_expr_disp
2273: , x_piped_expr_disp => l_piped_expr_disp

Line 2281: IF l_return_status = fnd_api.g_ret_sts_success THEN

2277: , x_msg_count => l_msg_count
2278: , x_msg_data => l_msg_data
2279: );
2280:
2281: IF l_return_status = fnd_api.g_ret_sts_success THEN
2282: -- do import here
2283: l_exp_id := NULL;
2284: create_expression(
2285: p_api_version => 1.0

Line 2286: , p_init_msg_list => fnd_api.g_false

2282: -- do import here
2283: l_exp_id := NULL;
2284: create_expression(
2285: p_api_version => 1.0
2286: , p_init_msg_list => fnd_api.g_false
2287: , p_org_id => p_org_id
2288: , p_name => l_api_rec.expression_name
2289: , p_description => l_api_rec.description
2290: , p_expression_disp => l_expr_disp

Line 2305: IF l_return_status = fnd_api.g_ret_sts_success THEN

2301: , x_msg_data => l_msg_data
2302: , x_object_version_number => l_object_version_number
2303: );
2304:
2305: IF l_return_status = fnd_api.g_ret_sts_success THEN
2306: -- update attribute values appropriately since API doesn't
2307: -- handle flexfields
2308: UPDATE cn_calc_sql_exps
2309: SET attribute_category = l_api_rec.attribute_category

Line 2329: IF l_return_status <> fnd_api.g_ret_sts_success THEN

2325: WHERE calc_sql_exp_id = l_exp_id;
2326: END IF;
2327: END IF;
2328:
2329: IF l_return_status <> fnd_api.g_ret_sts_success THEN
2330: -- try to get correct message
2331: l_failed_row := l_failed_row + 1;
2332: my_message :=
2333: fnd_msg_pub.get(p_msg_index => fnd_msg_pub.g_first

Line 2334: , p_encoded => fnd_api.g_false);

2330: -- try to get correct message
2331: l_failed_row := l_failed_row + 1;
2332: my_message :=
2333: fnd_msg_pub.get(p_msg_index => fnd_msg_pub.g_first
2334: , p_encoded => fnd_api.g_false);
2335:
2336: WHILE(my_message IS NOT NULL) LOOP
2337: l_error_code := my_message;
2338: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);

Line 2338: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);

2334: , p_encoded => fnd_api.g_false);
2335:
2336: WHILE(my_message IS NOT NULL) LOOP
2337: l_error_code := my_message;
2338: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);
2339: END LOOP;
2340:
2341: cn_import_pvt.update_imp_lines(
2342: p_imp_line_id => l_api_rec.imp_line_id

Line 2446: WHEN fnd_api.g_exc_unexpected_error THEN

2442: cn_message_pkg.end_batch(l_process_audit_id);
2443: -- Commit all imports
2444: COMMIT;
2445: EXCEPTION
2446: WHEN fnd_api.g_exc_unexpected_error THEN
2447: retcode := 2;
2448: cn_message_pkg.end_batch(l_process_audit_id);
2449: fnd_msg_pub.count_and_get(p_count => l_msg_count, p_data => errbuf
2450: , p_encoded => fnd_api.g_false);

Line 2450: , p_encoded => fnd_api.g_false);

2446: WHEN fnd_api.g_exc_unexpected_error THEN
2447: retcode := 2;
2448: cn_message_pkg.end_batch(l_process_audit_id);
2449: fnd_msg_pub.count_and_get(p_count => l_msg_count, p_data => errbuf
2450: , p_encoded => fnd_api.g_false);
2451: WHEN OTHERS THEN
2452: err_num := SQLCODE;
2453:
2454: IF err_num = -6501 THEN

Line 2465: , p_encoded => fnd_api.g_false);

2461: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2462: END IF;
2463:
2464: fnd_msg_pub.count_and_get(p_count => l_msg_count, p_data => errbuf
2465: , p_encoded => fnd_api.g_false);
2466: END IF;
2467:
2468: cn_message_pkg.set_error(l_api_name, errbuf);
2469: cn_message_pkg.end_batch(l_process_audit_id);

Line 2643: IF l_return_status <> fnd_api.g_ret_sts_success THEN

2639: , x_msg_count => l_msg_count
2640: , x_msg_data => l_msg_data
2641: );
2642:
2643: IF l_return_status <> fnd_api.g_ret_sts_success THEN
2644: cn_import_pvt.update_imp_headers(p_imp_header_id => p_imp_header_id, p_status_code => 'FAIL'
2645: , p_failed_row => l_rowcount);
2646: cn_message_pkg.WRITE(
2647: p_message_text => 'Export threw exception : rts sts ' || l_return_status

Line 2650: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);

2646: cn_message_pkg.WRITE(
2647: p_message_text => 'Export threw exception : rts sts ' || l_return_status
2648: , p_message_type => 'ERROR'
2649: );
2650: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);
2651:
2652: WHILE(my_message IS NOT NULL) LOOP
2653: l_message := l_message || my_message || '; ';
2654: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);

Line 2654: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);

2650: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);
2651:
2652: WHILE(my_message IS NOT NULL) LOOP
2653: l_message := l_message || my_message || '; ';
2654: my_message := fnd_msg_pub.get(p_encoded => fnd_api.g_false);
2655: END LOOP;
2656:
2657: cn_message_pkg.WRITE(p_message_text => l_message, p_message_type => 'ERROR');
2658: retcode := 2;

Line 2701: WHEN fnd_api.g_exc_unexpected_error THEN

2697: cn_message_pkg.end_batch(l_process_audit_id);
2698: -- Commit all imports
2699: COMMIT;
2700: EXCEPTION
2701: WHEN fnd_api.g_exc_unexpected_error THEN
2702: retcode := 2;
2703: cn_message_pkg.end_batch(l_process_audit_id);
2704: fnd_msg_pub.count_and_get(p_count => l_msg_count, p_data => errbuf
2705: , p_encoded => fnd_api.g_false);

Line 2705: , p_encoded => fnd_api.g_false);

2701: WHEN fnd_api.g_exc_unexpected_error THEN
2702: retcode := 2;
2703: cn_message_pkg.end_batch(l_process_audit_id);
2704: fnd_msg_pub.count_and_get(p_count => l_msg_count, p_data => errbuf
2705: , p_encoded => fnd_api.g_false);
2706: WHEN OTHERS THEN
2707: err_num := SQLCODE;
2708:
2709: IF err_num = -6501 THEN

Line 2720: , p_encoded => fnd_api.g_false);

2716: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2717: END IF;
2718:
2719: fnd_msg_pub.count_and_get(p_count => l_msg_count, p_data => errbuf
2720: , p_encoded => fnd_api.g_false);
2721: END IF;
2722:
2723: cn_message_pkg.set_error(l_api_name, errbuf);
2724: cn_message_pkg.end_batch(l_process_audit_id);

Line 2729: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2725: END export;
2726:
2727: PROCEDURE duplicate_expression(
2728: p_api_version IN NUMBER
2729: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2730: , p_commit IN VARCHAR2 := fnd_api.g_false
2731: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2732: , p_old_expr_id IN NUMBER
2733: , x_new_expr_id OUT NOCOPY NUMBER

Line 2730: , p_commit IN VARCHAR2 := fnd_api.g_false

2726:
2727: PROCEDURE duplicate_expression(
2728: p_api_version IN NUMBER
2729: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2730: , p_commit IN VARCHAR2 := fnd_api.g_false
2731: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2732: , p_old_expr_id IN NUMBER
2733: , x_new_expr_id OUT NOCOPY NUMBER
2734: , x_new_expr_name OUT NOCOPY cn_calc_sql_exps.NAME%TYPE

Line 2731: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full

2727: PROCEDURE duplicate_expression(
2728: p_api_version IN NUMBER
2729: , p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2730: , p_commit IN VARCHAR2 := fnd_api.g_false
2731: , p_validation_level IN NUMBER := fnd_api.g_valid_level_full
2732: , p_old_expr_id IN NUMBER
2733: , x_new_expr_id OUT NOCOPY NUMBER
2734: , x_new_expr_name OUT NOCOPY cn_calc_sql_exps.NAME%TYPE
2735: , x_return_status OUT NOCOPY VARCHAR2

Line 2759: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

2755: -- Standard Start of API savepoint
2756: SAVEPOINT create_expression;
2757:
2758: -- Standard call to check for call compatibility.
2759: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2760: RAISE fnd_api.g_exc_unexpected_error;
2761: END IF;
2762:
2763: -- Initialize message list if p_init_msg_list is set to TRUE.

Line 2760: RAISE fnd_api.g_exc_unexpected_error;

2756: SAVEPOINT create_expression;
2757:
2758: -- Standard call to check for call compatibility.
2759: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2760: RAISE fnd_api.g_exc_unexpected_error;
2761: END IF;
2762:
2763: -- Initialize message list if p_init_msg_list is set to TRUE.
2764: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 2764: IF fnd_api.to_boolean(p_init_msg_list) THEN

2760: RAISE fnd_api.g_exc_unexpected_error;
2761: END IF;
2762:
2763: -- Initialize message list if p_init_msg_list is set to TRUE.
2764: IF fnd_api.to_boolean(p_init_msg_list) THEN
2765: fnd_msg_pub.initialize;
2766: END IF;
2767:
2768: -- Initialize API return status to success

Line 2769: x_return_status := fnd_api.g_ret_sts_success;

2765: fnd_msg_pub.initialize;
2766: END IF;
2767:
2768: -- Initialize API return status to success
2769: x_return_status := fnd_api.g_ret_sts_success;
2770:
2771: SELECT org_id
2772: , NAME
2773: , description

Line 2805: IF (x_return_status <> fnd_api.g_ret_sts_success) THEN

2801: , x_msg_count => x_msg_count
2802: , x_msg_data => x_msg_data
2803: );
2804:
2805: IF (x_return_status <> fnd_api.g_ret_sts_success) THEN
2806: RAISE fnd_api.g_exc_error;
2807: END IF;
2808:
2809: create_expression(

Line 2806: RAISE fnd_api.g_exc_error;

2802: , x_msg_data => x_msg_data
2803: );
2804:
2805: IF (x_return_status <> fnd_api.g_ret_sts_success) THEN
2806: RAISE fnd_api.g_exc_error;
2807: END IF;
2808:
2809: create_expression(
2810: p_api_version => p_api_version

Line 2833: IF fnd_api.to_boolean(p_commit) THEN

2829: , x_object_version_number => x_object_version_number
2830: );
2831:
2832: -- Standard check of p_commit.
2833: IF fnd_api.to_boolean(p_commit) THEN
2834: COMMIT WORK;
2835: END IF;
2836:
2837: -- Standard call to get message count and if count is 1, get message info.

Line 2839: , p_encoded => fnd_api.g_false);

2835: END IF;
2836:
2837: -- Standard call to get message count and if count is 1, get message info.
2838: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2839: , p_encoded => fnd_api.g_false);
2840: EXCEPTION
2841: WHEN fnd_api.g_exc_error THEN
2842: ROLLBACK TO duplicate_expression;
2843: x_return_status := fnd_api.g_ret_sts_error;

Line 2841: WHEN fnd_api.g_exc_error THEN

2837: -- Standard call to get message count and if count is 1, get message info.
2838: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2839: , p_encoded => fnd_api.g_false);
2840: EXCEPTION
2841: WHEN fnd_api.g_exc_error THEN
2842: ROLLBACK TO duplicate_expression;
2843: x_return_status := fnd_api.g_ret_sts_error;
2844: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2845: , p_encoded => fnd_api.g_false);

Line 2843: x_return_status := fnd_api.g_ret_sts_error;

2839: , p_encoded => fnd_api.g_false);
2840: EXCEPTION
2841: WHEN fnd_api.g_exc_error THEN
2842: ROLLBACK TO duplicate_expression;
2843: x_return_status := fnd_api.g_ret_sts_error;
2844: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2845: , p_encoded => fnd_api.g_false);
2846: WHEN fnd_api.g_exc_unexpected_error THEN
2847: ROLLBACK TO duplicate_expression;

Line 2845: , p_encoded => fnd_api.g_false);

2841: WHEN fnd_api.g_exc_error THEN
2842: ROLLBACK TO duplicate_expression;
2843: x_return_status := fnd_api.g_ret_sts_error;
2844: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2845: , p_encoded => fnd_api.g_false);
2846: WHEN fnd_api.g_exc_unexpected_error THEN
2847: ROLLBACK TO duplicate_expression;
2848: x_return_status := fnd_api.g_ret_sts_unexp_error;
2849: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data

Line 2846: WHEN fnd_api.g_exc_unexpected_error THEN

2842: ROLLBACK TO duplicate_expression;
2843: x_return_status := fnd_api.g_ret_sts_error;
2844: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2845: , p_encoded => fnd_api.g_false);
2846: WHEN fnd_api.g_exc_unexpected_error THEN
2847: ROLLBACK TO duplicate_expression;
2848: x_return_status := fnd_api.g_ret_sts_unexp_error;
2849: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2850: , p_encoded => fnd_api.g_false);

Line 2848: x_return_status := fnd_api.g_ret_sts_unexp_error;

2844: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2845: , p_encoded => fnd_api.g_false);
2846: WHEN fnd_api.g_exc_unexpected_error THEN
2847: ROLLBACK TO duplicate_expression;
2848: x_return_status := fnd_api.g_ret_sts_unexp_error;
2849: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2850: , p_encoded => fnd_api.g_false);
2851: WHEN OTHERS THEN
2852: ROLLBACK TO duplicate_expression;

Line 2850: , p_encoded => fnd_api.g_false);

2846: WHEN fnd_api.g_exc_unexpected_error THEN
2847: ROLLBACK TO duplicate_expression;
2848: x_return_status := fnd_api.g_ret_sts_unexp_error;
2849: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2850: , p_encoded => fnd_api.g_false);
2851: WHEN OTHERS THEN
2852: ROLLBACK TO duplicate_expression;
2853: x_return_status := fnd_api.g_ret_sts_unexp_error;
2854:

Line 2853: x_return_status := fnd_api.g_ret_sts_unexp_error;

2849: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2850: , p_encoded => fnd_api.g_false);
2851: WHEN OTHERS THEN
2852: ROLLBACK TO duplicate_expression;
2853: x_return_status := fnd_api.g_ret_sts_unexp_error;
2854:
2855: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2856: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2857: END IF;

Line 2860: , p_encoded => fnd_api.g_false);

2856: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
2857: END IF;
2858:
2859: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data
2860: , p_encoded => fnd_api.g_false);
2861: END duplicate_expression;
2862: END cn_calc_sql_exps_pvt;