DBA Data[Home] [Help]

APPS.CSI_II_RELATIONSHIPS_PVT dependencies on FND_API

Line 64: IF NOT fnd_api.compatible_api_call ( l_api_version,

60: -- standard start of api savepoint
61: --SAVEPOINT get_cylic_relationships_pvt;
62:
63: -- standard call to check for call compatibility.
64: IF NOT fnd_api.compatible_api_call ( l_api_version,
65: p_api_version,
66: l_api_name,
67: g_pkg_name)
68: THEN

Line 69: RAISE fnd_api.g_exc_unexpected_error;

65: p_api_version,
66: l_api_name,
67: g_pkg_name)
68: THEN
69: RAISE fnd_api.g_exc_unexpected_error;
70: END IF;
71:
72: -- initialize message list if p_init_msg_list is set to true.
73: IF fnd_api.to_boolean( p_init_msg_list )

Line 73: IF fnd_api.to_boolean( p_init_msg_list )

69: RAISE fnd_api.g_exc_unexpected_error;
70: END IF;
71:
72: -- initialize message list if p_init_msg_list is set to true.
73: IF fnd_api.to_boolean( p_init_msg_list )
74: THEN
75: fnd_msg_pub.initialize;
76: END IF;
77:

Line 79: x_return_status := fnd_api.g_ret_sts_success;

75: fnd_msg_pub.initialize;
76: END IF;
77:
78: -- initialize api return status to success
79: x_return_status := fnd_api.g_ret_sts_success;
80: l_debug_level := fnd_profile.value('CSI_DEBUG_LEVEL');
81:
82: IF (l_debug_level > 0) THEN
83: CSI_gen_utility_pvt.put_line( 'get_cyclic_relationships');

Line 109: x_return_status := fnd_api.g_ret_sts_error;

105: IF p_instance_id IS NULL
106: THEN
107: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
108: fnd_msg_pub.add;
109: x_return_status := fnd_api.g_ret_sts_error;
110: RAISE fnd_api.g_exc_error;
111: END IF;
112:
113: select to_char(sysdate,'YY-MON-DD HH:MI:SS')

Line 110: RAISE fnd_api.g_exc_error;

106: THEN
107: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
108: fnd_msg_pub.add;
109: x_return_status := fnd_api.g_ret_sts_error;
110: RAISE fnd_api.g_exc_error;
111: END IF;
112:
113: select to_char(sysdate,'YY-MON-DD HH:MI:SS')
114: into l_start_time

Line 229: WHEN fnd_api.g_exc_unexpected_error THEN

225: into l_end_time
226: from dual ;
227:
228: EXCEPTION
229: WHEN fnd_api.g_exc_unexpected_error THEN
230: --ROLLBACK TO get_cylic_relationships_pvt;
231: x_return_status := fnd_api.g_ret_sts_unexp_error ;
232: fnd_msg_pub.count_AND_get
233: (p_count => x_msg_count ,

Line 231: x_return_status := fnd_api.g_ret_sts_unexp_error ;

227:
228: EXCEPTION
229: WHEN fnd_api.g_exc_unexpected_error THEN
230: --ROLLBACK TO get_cylic_relationships_pvt;
231: x_return_status := fnd_api.g_ret_sts_unexp_error ;
232: fnd_msg_pub.count_AND_get
233: (p_count => x_msg_count ,
234: p_data => x_msg_data);
235:

Line 238: x_return_status := fnd_api.g_ret_sts_unexp_error ;

234: p_data => x_msg_data);
235:
236: WHEN OTHERS THEN
237: --ROLLBACK TO get_cylic_relationships_pvt;
238: x_return_status := fnd_api.g_ret_sts_unexp_error ;
239: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
240: THEN
241: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
242: END IF;

Line 297: AND DECODE(p_active_relationship_only,FND_API.G_TRUE,NVL((active_end_date),c_sysdate+1),c_sysdate+1) > NVL((l_time_stamp),c_sysdate) ;

293: FROM csi_ii_relationships
294: WHERE (subject_id = p_instance_id OR object_id = p_instance_id )
295: AND relationship_type_code = 'CONNECTED-TO'
296: AND nvl(active_start_date,creation_date) <= NVL(l_time_stamp,nvl(active_start_date,creation_date))
297: AND DECODE(p_active_relationship_only,FND_API.G_TRUE,NVL((active_end_date),c_sysdate+1),c_sysdate+1) > NVL((l_time_stamp),c_sysdate) ;
298:
299: BEGIN
300: i:= 0;
301: SELECT SYSDATE

Line 306: IF p_time_stamp = FND_API.G_MISS_DATE THEN

302: INTO l_sysdate
303: FROM dual;
304: --
305: -- srramakr Bug # 2882876
306: IF p_time_stamp = FND_API.G_MISS_DATE THEN
307: l_time_stamp := null;
308: ELSE
309: l_time_stamp := p_time_stamp;
310: END IF;

Line 405: AND DECODE(p_active_relationship_only,FND_API.G_TRUE,NVL((active_end_date),c_sysdate+1),c_sysdate+1) > NVL((l_time_stamp),c_sysdate)

401: FROM csi_ii_relationships
402: WHERE (subject_id = p_instance_id OR object_id = p_instance_id)
403: AND relationship_type_code = 'CONNECTED-TO'
404: AND nvl(active_start_date,creation_date) <= NVL(l_time_stamp,nvl(active_start_date,creation_date))
405: AND DECODE(p_active_relationship_only,FND_API.G_TRUE,NVL((active_end_date),c_sysdate+1),c_sysdate+1) > NVL((l_time_stamp),c_sysdate)
406: UNION ALL
407: SELECT object_id instance_id
408: FROM csi_ii_relationships
409: WHERE (subject_id = p_instance_id OR object_id = p_instance_id)

Line 412: AND DECODE(p_active_relationship_only,FND_API.G_TRUE,NVL((active_end_date),c_sysdate+1),c_sysdate+1) > NVL((l_time_stamp),c_sysdate) ;

408: FROM csi_ii_relationships
409: WHERE (subject_id = p_instance_id OR object_id = p_instance_id)
410: AND relationship_type_code = 'CONNECTED-TO'
411: AND nvl(active_start_date,creation_date) <= NVL(l_time_stamp,nvl(active_start_date,creation_date))
412: AND DECODE(p_active_relationship_only,FND_API.G_TRUE,NVL((active_end_date),c_sysdate+1),c_sysdate+1) > NVL((l_time_stamp),c_sysdate) ;
413:
414: BEGIN
415: SELECT SYSDATE
416: INTO l_sysdate

Line 420: IF p_time_stamp = FND_API.G_MISS_DATE THEN

416: INTO l_sysdate
417: FROM DUAL;
418: --
419: -- srramakr Bug # 2882876
420: IF p_time_stamp = FND_API.G_MISS_DATE THEN
421: l_time_stamp := null;
422: ELSE
423: l_time_stamp := p_time_stamp;
424: END IF;

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

448:
449: /* End of Cyclic Relationships */
450:
451: PROCEDURE validate_ii_relationships(
452: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
453: p_validation_level IN NUMBER := fnd_api.g_valid_level_full,
454: p_validation_mode IN VARCHAR2,
455: p_ii_relationship_tbl IN csi_datastructures_pub.ii_relationship_tbl,
456: x_return_status OUT NOCOPY VARCHAR2,

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

449: /* End of Cyclic Relationships */
450:
451: PROCEDURE validate_ii_relationships(
452: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
453: p_validation_level IN NUMBER := fnd_api.g_valid_level_full,
454: p_validation_mode IN VARCHAR2,
455: p_ii_relationship_tbl IN csi_datastructures_pub.ii_relationship_tbl,
456: x_return_status OUT NOCOPY VARCHAR2,
457: x_msg_count OUT NOCOPY NUMBER,

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

458: x_msg_data OUT NOCOPY VARCHAR2
459: );
460:
461: PROCEDURE validate_relationship_id (
462: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
463: p_validation_mode IN VARCHAR2,
464: p_relationship_id IN NUMBER,
465: x_return_status OUT NOCOPY VARCHAR2,
466: x_msg_count OUT NOCOPY NUMBER,

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

467: x_msg_data OUT NOCOPY VARCHAR2
468: );
469:
470: PROCEDURE validate_rel_type_code (
471: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
472: p_validation_mode IN VARCHAR2,
473: p_relationship_type_code IN VARCHAR2,
474: x_return_status OUT NOCOPY VARCHAR2,
475: x_msg_count OUT NOCOPY NUMBER,

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

477: );
478:
479:
480: PROCEDURE validate_object_id (
481: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
482: p_validation_mode IN VARCHAR2,
483: p_object_id IN NUMBER,
484: x_return_status OUT NOCOPY VARCHAR2,
485: x_msg_count OUT NOCOPY NUMBER,

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

487: );
488:
489:
490: PROCEDURE validate_subject_id (
491: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
492: p_validation_mode IN VARCHAR2,
493: p_subject_id IN NUMBER,
494: x_return_status OUT NOCOPY VARCHAR2,
495: x_msg_count OUT NOCOPY NUMBER,

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

497: );
498:
499:
500: PROCEDURE validate_active_end_date (
501: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
502: p_validation_mode IN VARCHAR2,
503: p_active_end_date IN DATE,
504: x_return_status OUT NOCOPY VARCHAR2,
505: x_msg_count OUT NOCOPY NUMBER,

Line 594: IF( (p_relationship_query_rec.relationship_id IS NOT NULL) AND (p_relationship_query_rec.relationship_id <> fnd_api.g_miss_num) )

590: )
591: IS
592: BEGIN
593:
594: IF( (p_relationship_query_rec.relationship_id IS NOT NULL) AND (p_relationship_query_rec.relationship_id <> fnd_api.g_miss_num) )
595: THEN
596: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_id', p_relationship_query_rec.relationship_id);
597: END IF;
598:

Line 599: IF( (p_relationship_query_rec.relationship_type_code IS NOT NULL) AND (p_relationship_query_rec.relationship_type_code <> fnd_api.g_miss_char) )

595: THEN
596: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_id', p_relationship_query_rec.relationship_id);
597: END IF;
598:
599: IF( (p_relationship_query_rec.relationship_type_code IS NOT NULL) AND (p_relationship_query_rec.relationship_type_code <> fnd_api.g_miss_char) )
600: THEN
601: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_type_code', p_relationship_query_rec.relationship_type_code);
602: END IF;
603:

Line 604: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )

600: THEN
601: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_type_code', p_relationship_query_rec.relationship_type_code);
602: END IF;
603:
604: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
605: THEN
606: dbms_sql.bind_variable(p_cur_get_relations, 'object_id', p_relationship_query_rec.object_id);
607: END IF;
608:

Line 609: IF( (p_relationship_query_rec.subject_id IS NOT NULL) AND (p_relationship_query_rec.subject_id <> fnd_api.g_miss_num) )

605: THEN
606: dbms_sql.bind_variable(p_cur_get_relations, 'object_id', p_relationship_query_rec.object_id);
607: END IF;
608:
609: IF( (p_relationship_query_rec.subject_id IS NOT NULL) AND (p_relationship_query_rec.subject_id <> fnd_api.g_miss_num) )
610: THEN
611: dbms_sql.bind_variable(p_cur_get_relations, 'subject_id', p_relationship_query_rec.subject_id);
612: END IF;
613:

Line 659: IF( (p_relship_query_rec.relationship_id IS NOT NULL) AND (p_relship_query_rec.relationship_id <> fnd_api.g_miss_num) )

655:
656: BEGIN
657:
658:
659: IF( (p_relship_query_rec.relationship_id IS NOT NULL) AND (p_relship_query_rec.relationship_id <> fnd_api.g_miss_num) )
660: THEN
661: l_cnt:=l_cnt+1;
662: IF(x_relations_where IS NULL) THEN
663: x_relations_where := ' WHERE ';

Line 680: IF( (p_relship_query_rec.subject_id IS NOT NULL) AND (p_relship_query_rec.subject_id <> fnd_api.g_miss_num) )

676: END IF;
677: x_relations_where := x_relations_where ||' ( active_end_date is null or active_end_date >= SYSDATE ) ';
678: END IF; **** END OF COMMENT ****/
679:
680: IF( (p_relship_query_rec.subject_id IS NOT NULL) AND (p_relship_query_rec.subject_id <> fnd_api.g_miss_num) )
681: THEN
682: l_cnt:=l_cnt+1;
683: IF(x_relations_where IS NULL) THEN
684: x_relations_where := ' WHERE ';

Line 691: IF( (p_relship_query_rec.relationship_type_code IS NOT NULL) AND (p_relship_query_rec.relationship_type_code <> fnd_api.g_miss_char) )

687: END IF;
688: x_relations_where := x_relations_where || 'subject_id = :subject_id';
689: END IF;
690:
691: IF( (p_relship_query_rec.relationship_type_code IS NOT NULL) AND (p_relship_query_rec.relationship_type_code <> fnd_api.g_miss_char) )
692: THEN
693: l_cnt:=l_cnt+1;
694: i:=0;
695: -- check IF item value contains '%' wildcard

Line 724: IF( (p_relship_query_rec.object_id IS NOT NULL) AND (p_relship_query_rec.object_id <> fnd_api.g_miss_num) )

720: END IF;
721: x_relations_where := x_relations_where || 'relationship_type_code ' || l_operator || ' :relationship_type_code';
722: END IF;
723:
724: IF( (p_relship_query_rec.object_id IS NOT NULL) AND (p_relship_query_rec.object_id <> fnd_api.g_miss_num) )
725: THEN
726: IF(x_relations_where IS NULL) THEN
727: x_relations_where := ' WHERE ';
728: ELSE

Line 739: IF ( (p_depth IS NOT NULL) AND (p_depth <> fnd_api.g_miss_num) ) THEN

735: IF l_cnt>1 THEN
736: x_relations_where := x_relations_where || 'object_id = :object_id ';
737: ELSE
738: x_relations_where := x_relations_where || 'object_id = :object_id ' ||'CONNECT BY object_id = PRIOR subject_id' ;
739: IF ( (p_depth IS NOT NULL) AND (p_depth <> fnd_api.g_miss_num) ) THEN
740: x_relations_where := x_relations_where || ' AND level <= '||p_depth;
741: END IF;
742: END IF;
743: END IF;

Line 772: l_f_date VARCHAR2(25) := fnd_api.g_miss_char;

768: p_time_stamp IN DATE,
769: from_time_stamp OUT NOCOPY VARCHAR2,
770: to_time_stamp OUT NOCOPY VARCHAR2)
771: IS
772: l_f_date VARCHAR2(25) := fnd_api.g_miss_char;
773: l_t_date VARCHAR2(25) := fnd_api.g_miss_char;
774: BEGIN
775:
776: SELECT max(min(to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss')))

Line 773: l_t_date VARCHAR2(25) := fnd_api.g_miss_char;

769: from_time_stamp OUT NOCOPY VARCHAR2,
770: to_time_stamp OUT NOCOPY VARCHAR2)
771: IS
772: l_f_date VARCHAR2(25) := fnd_api.g_miss_char;
773: l_t_date VARCHAR2(25) := fnd_api.g_miss_char;
774: BEGIN
775:
776: SELECT max(min(to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss')))
777: INTO l_f_date

Line 873: l_f_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;

869: AND a.transaction_date BETWEEN to_date(p_f_time_stamp,'dd/mm/rr hh24:mi:ss')
870: AND to_date(p_t_time_stamp,'dd/mm/rr hh24:mi:ss')
871: ORDER BY to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss') ;
872:
873: l_f_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
874: l_t_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
875: l_to_date VARCHAR2(25);
876: BEGIN
877: FROM_to_tran(p_relationship_id => p_rel_rec.relationship_id,

Line 874: l_t_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;

870: AND to_date(p_t_time_stamp,'dd/mm/rr hh24:mi:ss')
871: ORDER BY to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss') ;
872:
873: l_f_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
874: l_t_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
875: l_to_date VARCHAR2(25);
876: BEGIN
877: FROM_to_tran(p_relationship_id => p_rel_rec.relationship_id,
878: p_time_stamp => p_time_stamp,

Line 1042: IF p_new_rec.display_order = fnd_api.g_miss_num THEN

1038: p_new_rec.attribute15 := get_csr.old_attribute15;
1039: END IF;
1040:
1041: END LOOP;
1042: IF p_new_rec.display_order = fnd_api.g_miss_num THEN
1043: p_new_rec.display_order := NULL;
1044: END IF;
1045:
1046: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN

Line 1046: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN

1042: IF p_new_rec.display_order = fnd_api.g_miss_num THEN
1043: p_new_rec.display_order := NULL;
1044: END IF;
1045:
1046: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN
1047: p_new_rec.subject_id := NULL;
1048: END IF;
1049:
1050: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN

Line 1050: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN

1046: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN
1047: p_new_rec.subject_id := NULL;
1048: END IF;
1049:
1050: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN
1051: p_new_rec.position_reference := NULL;
1052: END IF;
1053:
1054: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN

Line 1054: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN

1050: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN
1051: p_new_rec.position_reference := NULL;
1052: END IF;
1053:
1054: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN
1055: p_new_rec.active_start_date := NULL;
1056: END IF;
1057:
1058: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN

Line 1058: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN

1054: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN
1055: p_new_rec.active_start_date := NULL;
1056: END IF;
1057:
1058: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN
1059: p_new_rec.active_end_date := NULL;
1060: END IF;
1061:
1062: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN

Line 1062: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN

1058: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN
1059: p_new_rec.active_end_date := NULL;
1060: END IF;
1061:
1062: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN
1063: p_new_rec.mandatory_flag := NULL;
1064: END IF;
1065:
1066: IF p_new_rec.context = fnd_api.g_miss_char THEN

Line 1066: IF p_new_rec.context = fnd_api.g_miss_char THEN

1062: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN
1063: p_new_rec.mandatory_flag := NULL;
1064: END IF;
1065:
1066: IF p_new_rec.context = fnd_api.g_miss_char THEN
1067: p_new_rec.context := NULL;
1068: END IF;
1069:
1070: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN

Line 1070: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN

1066: IF p_new_rec.context = fnd_api.g_miss_char THEN
1067: p_new_rec.context := NULL;
1068: END IF;
1069:
1070: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN
1071: p_new_rec.attribute1 := NULL;
1072: END IF;
1073:
1074: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN

Line 1074: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN

1070: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN
1071: p_new_rec.attribute1 := NULL;
1072: END IF;
1073:
1074: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN
1075: p_new_rec.attribute2 := NULL;
1076: END IF;
1077:
1078: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN

Line 1078: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN

1074: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN
1075: p_new_rec.attribute2 := NULL;
1076: END IF;
1077:
1078: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN
1079: p_new_rec.attribute3 := NULL;
1080: END IF;
1081:
1082: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN

Line 1082: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN

1078: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN
1079: p_new_rec.attribute3 := NULL;
1080: END IF;
1081:
1082: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN
1083: p_new_rec.attribute4 := NULL;
1084: END IF;
1085:
1086: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN

Line 1086: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN

1082: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN
1083: p_new_rec.attribute4 := NULL;
1084: END IF;
1085:
1086: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN
1087: p_new_rec.attribute5 := NULL;
1088: END IF;
1089:
1090: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN

Line 1090: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN

1086: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN
1087: p_new_rec.attribute5 := NULL;
1088: END IF;
1089:
1090: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN
1091: p_new_rec.attribute6 := NULL;
1092: END IF;
1093:
1094: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN

Line 1094: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN

1090: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN
1091: p_new_rec.attribute6 := NULL;
1092: END IF;
1093:
1094: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN
1095: p_new_rec.attribute7 := NULL;
1096: END IF;
1097:
1098: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN

Line 1098: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN

1094: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN
1095: p_new_rec.attribute7 := NULL;
1096: END IF;
1097:
1098: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN
1099: p_new_rec.attribute8 := NULL;
1100: END IF;
1101:
1102: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN

Line 1102: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN

1098: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN
1099: p_new_rec.attribute8 := NULL;
1100: END IF;
1101:
1102: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN
1103: p_new_rec.attribute9 := NULL;
1104: END IF;
1105:
1106: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN

Line 1106: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN

1102: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN
1103: p_new_rec.attribute9 := NULL;
1104: END IF;
1105:
1106: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN
1107: p_new_rec.attribute10 := NULL;
1108: END IF;
1109:
1110: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN

Line 1110: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN

1106: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN
1107: p_new_rec.attribute10 := NULL;
1108: END IF;
1109:
1110: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN
1111: p_new_rec.attribute11 := NULL;
1112: END IF;
1113:
1114: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN

Line 1114: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN

1110: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN
1111: p_new_rec.attribute11 := NULL;
1112: END IF;
1113:
1114: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN
1115: p_new_rec.attribute12 := NULL;
1116: END IF;
1117:
1118: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN

Line 1118: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN

1114: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN
1115: p_new_rec.attribute12 := NULL;
1116: END IF;
1117:
1118: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN
1119: p_new_rec.attribute13 := NULL;
1120: END IF;
1121:
1122: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN

Line 1122: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN

1118: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN
1119: p_new_rec.attribute13 := NULL;
1120: END IF;
1121:
1122: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN
1123: p_new_rec.attribute14 := NULL;
1124: END IF;
1125:
1126: IF p_new_rec.attribute15 = fnd_api.g_miss_char THEN

Line 1126: IF p_new_rec.attribute15 = fnd_api.g_miss_char THEN

1122: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN
1123: p_new_rec.attribute14 := NULL;
1124: END IF;
1125:
1126: IF p_new_rec.attribute15 = fnd_api.g_miss_char THEN
1127: p_new_rec.attribute15 := NULL;
1128: END IF;
1129:
1130: p_flag :='ADD';

Line 1291: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate

1287: object_version_number
1288: from CSI_II_RELATIONSHIPS cir
1289: where cir.object_id = p_object_id
1290: and cir.relationship_type_code = p_rel_type_code
1291: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1292: and EXISTS (select 'x'
1293: from CSI_ITEM_INSTANCES csi
1294: where csi.instance_id = cir.subject_id
1295: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

Line 1295: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

1291: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1292: and EXISTS (select 'x'
1293: from CSI_ITEM_INSTANCES csi
1294: where csi.instance_id = cir.subject_id
1295: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1296: --
1297: CURSOR OBJECT_CUR1(c_sysdate IN DATE) IS -- Used when Object ID and Rel Type are passed
1298: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1299: active_start_date,active_end_date,display_order,mandatory_flag,context,

Line 1306: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate

1302: object_version_number
1303: from CSI_II_RELATIONSHIPS cir
1304: where cir.object_id = p_object_id
1305: and cir.relationship_type_code = p_rel_type_code
1306: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1307: and EXISTS (select 'x'
1308: from CSI_ITEM_INSTANCES csi
1309: where csi.instance_id = cir.subject_id
1310: and csi.config_inst_hdr_id is not null

Line 1313: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

1309: where csi.instance_id = cir.subject_id
1310: and csi.config_inst_hdr_id is not null
1311: and csi.config_inst_item_id is not null
1312: and csi.config_inst_rev_num is not null
1313: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1314: --
1315: CURSOR OBJECT_ONLY_CUR(c_sysdate IN DATE) IS -- Used when only Object ID is passed
1316: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1317: active_start_date,active_end_date,display_order,mandatory_flag,context,

Line 1323: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate

1319: attribute9,attribute10,attribute11,attribute12,attribute13,attribute14,attribute15,
1320: object_version_number
1321: from CSI_II_RELATIONSHIPS cir
1322: where cir.object_id = p_object_id
1323: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1324: and EXISTS (select 'x'
1325: from CSI_ITEM_INSTANCES csi
1326: where csi.instance_id = cir.subject_id
1327: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

Line 1327: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

1323: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1324: and EXISTS (select 'x'
1325: from CSI_ITEM_INSTANCES csi
1326: where csi.instance_id = cir.subject_id
1327: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1328: --
1329: CURSOR SUBJECT_CUR(c_sysdate IN DATE) IS --Used when subject ID and Rel type are passed
1330: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1331: active_start_date,active_end_date,display_order,mandatory_flag,context,

Line 1338: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate

1334: object_version_number
1335: from CSI_II_RELATIONSHIPS cir
1336: where cir.subject_id = p_subject_id
1337: and cir.relationship_type_code = p_rel_type_code
1338: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1339: and EXISTS (select 'x'
1340: from CSI_ITEM_INSTANCES csi
1341: where csi.instance_id = cir.subject_id
1342: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

Line 1342: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

1338: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1339: and EXISTS (select 'x'
1340: from CSI_ITEM_INSTANCES csi
1341: where csi.instance_id = cir.subject_id
1342: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1343: --
1344: CURSOR REL_ID_CUR(c_sysdate IN DATE) IS -- Used when only relationship_id is passed
1345: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1346: active_start_date,active_end_date,display_order,mandatory_flag,context,

Line 1352: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate

1348: attribute9,attribute10,attribute11,attribute12,attribute13,attribute14,attribute15,
1349: object_version_number
1350: from CSI_II_RELATIONSHIPS cir
1351: where cir.relationship_id = p_relationship_id
1352: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1353: and EXISTS (select 'x'
1354: from CSI_ITEM_INSTANCES csi
1355: where csi.instance_id = cir.subject_id
1356: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

Line 1356: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

1352: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1353: and EXISTS (select 'x'
1354: from CSI_ITEM_INSTANCES csi
1355: where csi.instance_id = cir.subject_id
1356: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1357: --
1358: CURSOR OTHER_PARAM_CUR(c_sysdate IN DATE) IS
1359: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1360: active_start_date,active_end_date,display_order,mandatory_flag,context,

Line 1369: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate

1365: where cir.relationship_id = NVL(p_relationship_id,cir.relationship_id)
1366: and cir.object_id = NVL(p_object_id,cir.object_id)
1367: and cir.relationship_type_code = NVL(p_rel_type_code,cir.relationship_type_code)
1368: and cir.subject_id = NVL(p_subject_id,cir.subject_id)
1369: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1370: and EXISTS (select 'x'
1371: from CSI_ITEM_INSTANCES csi
1372: where csi.instance_id = cir.subject_id
1373: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

Line 1373: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

1369: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1370: and EXISTS (select 'x'
1371: from CSI_ITEM_INSTANCES csi
1372: where csi.instance_id = cir.subject_id
1373: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1374: --
1375: l_ctr NUMBER := 0;
1376: l_sysdate DATE;
1377: COMP_EXCEP EXCEPTION;

Line 1384: l_active_instances_only := FND_API.G_FALSE;

1380: into l_sysdate
1381: from dual;
1382: --
1383: IF p_time_stamp IS NOT NULL THEN
1384: l_active_instances_only := FND_API.G_FALSE;
1385: l_active_relationship_only := FND_API.G_FALSE;
1386: ELSE
1387: l_active_relationship_only := p_active_relationship_only;
1388: l_active_instances_only := p_active_instances_only;

Line 1385: l_active_relationship_only := FND_API.G_FALSE;

1381: from dual;
1382: --
1383: IF p_time_stamp IS NOT NULL THEN
1384: l_active_instances_only := FND_API.G_FALSE;
1385: l_active_relationship_only := FND_API.G_FALSE;
1386: ELSE
1387: l_active_relationship_only := p_active_relationship_only;
1388: l_active_instances_only := p_active_instances_only;
1389: END IF;

Line 1397: p_config_only = fnd_api.g_false

1393: p_subject_id IS NULL AND
1394: p_relationship_id IS NULL
1395: THEN
1396: IF p_config_only IS NULL OR
1397: p_config_only = fnd_api.g_false
1398: THEN
1399: FOR rel IN OBJECT_CUR(l_sysdate) LOOP
1400: l_ctr := l_ctr + 1;
1401: p_rel_tbl(l_ctr).relationship_id := rel.relationship_id;

Line 1441: p_config_only = fnd_api.g_true

1437: p_rel_tbl(l_ctr).subject_has_child := 'N';
1438: End;
1439: END LOOP;
1440: ELSIF p_config_only IS NOT NULL AND
1441: p_config_only = fnd_api.g_true
1442: THEN
1443: FOR rel IN OBJECT_CUR1(l_sysdate) LOOP
1444: l_ctr := l_ctr + 1;
1445: p_rel_tbl(l_ctr).relationship_id := rel.relationship_id;

Line 1716: x_return_status := FND_API.G_RET_STS_SUCCESS;

1712: l_relationship_id NUMBER;
1713: l_time_stamp DATE;
1714: l_max_count NUMBER;
1715: BEGIN
1716: x_return_status := FND_API.G_RET_STS_SUCCESS;
1717: --savepoint Get_Children;
1718: IF l_depth IS NULL OR
1719: l_depth = FND_API.G_MISS_NUM OR
1720: l_depth <= 0 THEN

Line 1719: l_depth = FND_API.G_MISS_NUM OR

1715: BEGIN
1716: x_return_status := FND_API.G_RET_STS_SUCCESS;
1717: --savepoint Get_Children;
1718: IF l_depth IS NULL OR
1719: l_depth = FND_API.G_MISS_NUM OR
1720: l_depth <= 0 THEN
1721: l_depth := 9999999;
1722: END IF;
1723: --

Line 1725: p_relationship_query_rec.object_id = FND_API.G_MISS_NUM THEN

1721: l_depth := 9999999;
1722: END IF;
1723: --
1724: IF p_relationship_query_rec.object_id IS NULL OR
1725: p_relationship_query_rec.object_id = FND_API.G_MISS_NUM THEN
1726: l_object_id := null;
1727: ELSE
1728: l_object_id := p_relationship_query_rec.object_id;
1729: END IF;

Line 1732: p_relationship_query_rec.subject_id = FND_API.G_MISS_NUM THEN

1728: l_object_id := p_relationship_query_rec.object_id;
1729: END IF;
1730: --
1731: IF p_relationship_query_rec.subject_id IS NULL OR
1732: p_relationship_query_rec.subject_id = FND_API.G_MISS_NUM THEN
1733: l_subject_id := null;
1734: ELSE
1735: l_subject_id := p_relationship_query_rec.subject_id;
1736: END IF;

Line 1739: p_relationship_query_rec.relationship_id = FND_API.G_MISS_NUM THEN

1735: l_subject_id := p_relationship_query_rec.subject_id;
1736: END IF;
1737: --
1738: IF p_relationship_query_rec.relationship_id IS NULL OR
1739: p_relationship_query_rec.relationship_id = FND_API.G_MISS_NUM THEN
1740: l_relationship_id := null;
1741: ELSE
1742: l_relationship_id := p_relationship_query_rec.relationship_id;
1743: END IF;

Line 1746: p_relationship_query_rec.relationship_type_code = FND_API.G_MISS_CHAR THEN

1742: l_relationship_id := p_relationship_query_rec.relationship_id;
1743: END IF;
1744: --
1745: IF p_relationship_query_rec.relationship_type_code IS NULL OR
1746: p_relationship_query_rec.relationship_type_code = FND_API.G_MISS_CHAR THEN
1747: l_rel_type_code := null;
1748: ELSE
1749: l_rel_type_code := p_relationship_query_rec.relationship_type_code;
1750: END IF;

Line 1758: x_return_status := fnd_api.g_ret_sts_error;

1754: l_relationship_id IS NULL AND
1755: l_rel_type_code IS NULL THEN
1756: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
1757: fnd_msg_pub.add;
1758: x_return_status := fnd_api.g_ret_sts_error;
1759: RAISE fnd_api.g_exc_error;
1760: END IF;
1761: --
1762: IF p_time_stamp IS NULL OR

Line 1759: RAISE fnd_api.g_exc_error;

1755: l_rel_type_code IS NULL THEN
1756: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
1757: fnd_msg_pub.add;
1758: x_return_status := fnd_api.g_ret_sts_error;
1759: RAISE fnd_api.g_exc_error;
1760: END IF;
1761: --
1762: IF p_time_stamp IS NULL OR
1763: p_time_stamp = FND_API.G_MISS_DATE THEN

Line 1763: p_time_stamp = FND_API.G_MISS_DATE THEN

1759: RAISE fnd_api.g_exc_error;
1760: END IF;
1761: --
1762: IF p_time_stamp IS NULL OR
1763: p_time_stamp = FND_API.G_MISS_DATE THEN
1764: l_time_stamp := NULL;
1765: ELSE
1766: l_time_stamp := p_time_stamp;
1767: END IF;

Line 1842: IF nvl(p_get_dfs,FND_API.G_TRUE) = FND_API.G_TRUE AND

1838: --
1839: p_rel_tbl := l_rel_tbl_final;
1840: --
1841: -- Need to Sort if Object_id alone is passed
1842: IF nvl(p_get_dfs,FND_API.G_TRUE) = FND_API.G_TRUE AND
1843: l_object_id IS NOT NULL AND
1844: l_subject_id IS NULL AND
1845: l_relationship_id IS NULL THEN
1846: p_rel_tbl.DELETE;

Line 1889: WHEN fnd_api.g_exc_error THEN

1885: END LOOP;
1886: END IF;
1887: END IF; -- p_get_dfs check
1888: EXCEPTION
1889: WHEN fnd_api.g_exc_error THEN
1890: -- ROLLBACK TO Get_Children;
1891: x_return_status := fnd_api.g_ret_sts_error ;
1892: fnd_msg_pub.count_AND_get
1893: (p_count => x_msg_count ,

Line 1891: x_return_status := fnd_api.g_ret_sts_error ;

1887: END IF; -- p_get_dfs check
1888: EXCEPTION
1889: WHEN fnd_api.g_exc_error THEN
1890: -- ROLLBACK TO Get_Children;
1891: x_return_status := fnd_api.g_ret_sts_error ;
1892: fnd_msg_pub.count_AND_get
1893: (p_count => x_msg_count ,
1894: p_data => x_msg_data
1895: );

Line 1897: WHEN fnd_api.g_exc_unexpected_error THEN

1893: (p_count => x_msg_count ,
1894: p_data => x_msg_data
1895: );
1896:
1897: WHEN fnd_api.g_exc_unexpected_error THEN
1898: -- ROLLBACK TO Get_Children;
1899: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1900: fnd_msg_pub.count_AND_get
1901: (p_count => x_msg_count ,

Line 1899: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1895: );
1896:
1897: WHEN fnd_api.g_exc_unexpected_error THEN
1898: -- ROLLBACK TO Get_Children;
1899: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1900: fnd_msg_pub.count_AND_get
1901: (p_count => x_msg_count ,
1902: p_data => x_msg_data
1903: );

Line 1907: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1903: );
1904:
1905: WHEN OTHERS THEN
1906: -- ROLLBACK TO Get_Children;
1907: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1908: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1909: fnd_msg_pub.add_exc_msg('csi_relationships_pvt' ,l_api_name);
1910: END IF;
1911: fnd_msg_pub.count_AND_get

Line 1962: p_subject_id = FND_API.G_MISS_NUM THEN

1958: l_subject_id NUMBER;
1959: l_exists VARCHAR2(1);
1960: BEGIN
1961: IF p_subject_id IS NULL OR
1962: p_subject_id = FND_API.G_MISS_NUM THEN
1963: Return;
1964: END IF;
1965: --
1966: l_subject_id := p_subject_id;

Line 2099: IF NOT fnd_api.compatible_api_call ( l_api_version,

2095: -- standard start of api savepoint
2096: -- SAVEPOINT get_relationships_pvt;
2097:
2098: -- standard call to check for call compatibility.
2099: IF NOT fnd_api.compatible_api_call ( l_api_version,
2100: p_api_version,
2101: l_api_name,
2102: g_pkg_name)
2103: THEN

Line 2104: RAISE fnd_api.g_exc_unexpected_error;

2100: p_api_version,
2101: l_api_name,
2102: g_pkg_name)
2103: THEN
2104: RAISE fnd_api.g_exc_unexpected_error;
2105: END IF;
2106:
2107:
2108: -- initialize message list if p_init_msg_list is set to true.

Line 2109: IF fnd_api.to_boolean( p_init_msg_list )

2105: END IF;
2106:
2107:
2108: -- initialize message list if p_init_msg_list is set to true.
2109: IF fnd_api.to_boolean( p_init_msg_list )
2110: THEN
2111: fnd_msg_pub.initialize;
2112: END IF;
2113:

Line 2118: x_return_status := fnd_api.g_ret_sts_success;

2114:
2115:
2116:
2117: -- initialize api return status to success
2118: x_return_status := fnd_api.g_ret_sts_success;
2119:
2120:
2121: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
2122: IF (l_debug_level > 0) THEN

Line 2147: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))

2143: -- validate environment
2144: -- ******************************************************************
2145:
2146: IF
2147: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2148: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2149: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2150: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2151: )

Line 2148: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))

2144: -- ******************************************************************
2145:
2146: IF
2147: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2148: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2149: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2150: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2151: )
2152: THEN

Line 2149: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))

2145:
2146: IF
2147: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2148: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2149: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2150: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2151: )
2152: THEN
2153: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');

Line 2150: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))

2146: IF
2147: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2148: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2149: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2150: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2151: )
2152: THEN
2153: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2154: fnd_msg_pub.add;

Line 2155: x_return_status := fnd_api.g_ret_sts_error;

2151: )
2152: THEN
2153: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2154: fnd_msg_pub.add;
2155: x_return_status := fnd_api.g_ret_sts_error;
2156: RAISE fnd_api.g_exc_error;
2157: END IF;
2158:
2159: /* Cyclic Relationships */

Line 2156: RAISE fnd_api.g_exc_error;

2152: THEN
2153: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2154: fnd_msg_pub.add;
2155: x_return_status := fnd_api.g_ret_sts_error;
2156: RAISE fnd_api.g_exc_error;
2157: END IF;
2158:
2159: /* Cyclic Relationships */
2160: IF (p_relationship_query_rec.relationship_type_code = 'CONNECTED-TO')

Line 2165: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num)

2161: THEN
2162: IF ((p_relationship_query_rec.subject_id IS NULL
2163: AND p_relationship_query_rec.object_id IS NULL)
2164: OR ((p_relationship_query_rec.subject_id IS NOT NULL
2165: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num)
2166: AND (p_relationship_query_rec.object_id IS NOT NULL
2167: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))
2168: THEN
2169: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');

Line 2167: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))

2163: AND p_relationship_query_rec.object_id IS NULL)
2164: OR ((p_relationship_query_rec.subject_id IS NOT NULL
2165: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num)
2166: AND (p_relationship_query_rec.object_id IS NOT NULL
2167: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))
2168: THEN
2169: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2170: fnd_msg_pub.add;
2171: x_return_status := fnd_api.g_ret_sts_error;

Line 2171: x_return_status := fnd_api.g_ret_sts_error;

2167: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))
2168: THEN
2169: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2170: fnd_msg_pub.add;
2171: x_return_status := fnd_api.g_ret_sts_error;
2172: RAISE fnd_api.g_exc_error;
2173: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2174: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2175: OR (p_relationship_query_rec.object_id IS NOT NULL

Line 2172: RAISE fnd_api.g_exc_error;

2168: THEN
2169: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2170: fnd_msg_pub.add;
2171: x_return_status := fnd_api.g_ret_sts_error;
2172: RAISE fnd_api.g_exc_error;
2173: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2174: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2175: OR (p_relationship_query_rec.object_id IS NOT NULL
2176: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)

Line 2174: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))

2170: fnd_msg_pub.add;
2171: x_return_status := fnd_api.g_ret_sts_error;
2172: RAISE fnd_api.g_exc_error;
2173: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2174: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2175: OR (p_relationship_query_rec.object_id IS NOT NULL
2176: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)
2177: THEN
2178: IF p_relationship_query_rec.subject_id IS NOT NULL

Line 2176: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)

2172: RAISE fnd_api.g_exc_error;
2173: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2174: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2175: OR (p_relationship_query_rec.object_id IS NOT NULL
2176: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)
2177: THEN
2178: IF p_relationship_query_rec.subject_id IS NOT NULL
2179: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num
2180: THEN

Line 2179: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num

2175: OR (p_relationship_query_rec.object_id IS NOT NULL
2176: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)
2177: THEN
2178: IF p_relationship_query_rec.subject_id IS NOT NULL
2179: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num
2180: THEN
2181: l_instance_id := p_relationship_query_rec.subject_id;
2182: ELSIF p_relationship_query_rec.object_id IS NOT NULL
2183: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num

Line 2183: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num

2179: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num
2180: THEN
2181: l_instance_id := p_relationship_query_rec.subject_id;
2182: ELSIF p_relationship_query_rec.object_id IS NOT NULL
2183: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num
2184: THEN
2185: l_instance_id := p_relationship_query_rec.object_id;
2186: END IF;
2187: END IF;

Line 2191: p_commit => fnd_api.g_false,

2187: END IF;
2188:
2189: csi_ii_relationships_pvt.get_cyclic_relationships(
2190: p_api_version => p_api_version,
2191: p_commit => fnd_api.g_false,
2192: p_init_msg_list => p_init_msg_list,
2193: p_validation_level => p_validation_level,
2194: p_instance_id => l_instance_id,
2195: p_depth => p_depth ,

Line 2226: IF ((p_time_stamp IS NOT NULL) AND (p_time_stamp <> FND_API.G_MISS_DATE))

2222: LOOP
2223: l_rel_rec := null ;
2224: l_rel_rec := xc_relationship_tbl(i);
2225:
2226: IF ((p_time_stamp IS NOT NULL) AND (p_time_stamp <> FND_API.G_MISS_DATE))
2227: THEN
2228: IF ((l_last_purge_date IS NOT NULL) AND (p_time_stamp <= l_last_purge_date))
2229: THEN
2230: csi_gen_utility_pvt.put_line('Warning! History for this entity has already been purged for the datetime stamp passed. ' ||

Line 2249: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date) )THEN

2245: ELSE
2246: l_relationship_tbl(i) := l_rel_rec;
2247: END IF;
2248: --
2249: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date) )THEN
2250: IF l_relationship_tbl.count > 0
2251: THEN
2252: BEGIN
2253: SELECT 'Y'

Line 2264: AND l_relationship_tbl(i).relationship_id <> fnd_api.g_miss_num) --Added for bug 2999353

2260: EXCEPTION
2261: WHEN OTHERS THEN
2262: --l_relationship_tbl(i).subject_has_child := 'N';
2263: IF (l_relationship_tbl(i).relationship_id IS NOT NULL --Added for bug 2999353
2264: AND l_relationship_tbl(i).relationship_id <> fnd_api.g_miss_num) --Added for bug 2999353
2265: THEN
2266: l_relationship_tbl(i).subject_has_child := 'N';
2267: END IF;
2268: END;

Line 2290: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)

2286: END LOOP;
2287: END IF;
2288: --
2289: IF l_exists_flag <> 'Y' THEN
2290: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2291: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2292: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2293: THEN
2294: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;

Line 2292: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353

2288: --
2289: IF l_exists_flag <> 'Y' THEN
2290: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2291: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2292: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2293: THEN
2294: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;
2295: CSI_ITEM_INSTANCE_PUB.Get_item_instance_details(
2296: 1.0,

Line 2321: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN

2317: x_msg_count,
2318: x_msg_data
2319: );
2320: --
2321: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
2322: l_msg_index := 1;
2323: l_msg_count := x_msg_count;
2324: WHILE l_msg_count > 0 LOOP
2325: x_msg_data := FND_MSG_PUB.GET

Line 2327: FND_API.G_FALSE );

2323: l_msg_count := x_msg_count;
2324: WHILE l_msg_count > 0 LOOP
2325: x_msg_data := FND_MSG_PUB.GET
2326: ( l_msg_index,
2327: FND_API.G_FALSE );
2328: csi_gen_utility_pvt.put_line( ' Error from Get_Item_Instance_Details.. ');
2329: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2330: l_msg_index := l_msg_index + 1;
2331: l_msg_count := l_msg_count - 1;

Line 2333: RAISE FND_API.G_EXC_ERROR;

2329: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2330: l_msg_index := l_msg_index + 1;
2331: l_msg_count := l_msg_count - 1;
2332: END LOOP;
2333: RAISE FND_API.G_EXC_ERROR;
2334: END IF;
2335: IF nvl(l_instance_rec.active_end_date,(sysdate+1)) < sysdate THEN
2336: l_ctr := l_exp_inst_tbl.count;
2337: l_ctr := l_ctr + 1;

Line 2385: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))

2381:
2382: -- End addition by sguthiva
2383: ELSE ---if not CONNECTED-TO
2384: --gen_select(l_crit_relations_rec,l_select_cl);
2385: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2386: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2387: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2388: THEN
2389: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )

Line 2386: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))

2382: -- End addition by sguthiva
2383: ELSE ---if not CONNECTED-TO
2384: --gen_select(l_crit_relations_rec,l_select_cl);
2385: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2386: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2387: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2388: THEN
2389: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2390: THEN

Line 2387: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )

2383: ELSE ---if not CONNECTED-TO
2384: --gen_select(l_crit_relations_rec,l_select_cl);
2385: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2386: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2387: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2388: THEN
2389: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2390: THEN
2391: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )

Line 2389: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )

2385: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2386: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2387: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2388: THEN
2389: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2390: THEN
2391: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )
2392: THEN
2393: fnd_message.set_name('CSI','CSI_NO_RELCODE_PASSED');

Line 2391: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )

2387: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2388: THEN
2389: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2390: THEN
2391: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )
2392: THEN
2393: fnd_message.set_name('CSI','CSI_NO_RELCODE_PASSED');
2394: fnd_msg_pub.add;
2395: RAISE fnd_api.g_exc_error;

Line 2395: RAISE fnd_api.g_exc_error;

2391: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )
2392: THEN
2393: fnd_message.set_name('CSI','CSI_NO_RELCODE_PASSED');
2394: fnd_msg_pub.add;
2395: RAISE fnd_api.g_exc_error;
2396: END IF;
2397: END IF;
2398: END IF;
2399: /*

Line 2421: p_get_dfs => fnd_api.g_true,

2417: p_rel_tbl => l_rel_tbl,
2418: p_depth => p_depth,
2419: p_active_relationship_only => p_active_relationship_only,
2420: p_time_stamp => p_time_stamp,
2421: p_get_dfs => fnd_api.g_true,
2422: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
2423: x_return_status => x_return_status,
2424: x_msg_count => x_msg_count,
2425: x_msg_data => x_msg_data

Line 2427: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS)

2423: x_return_status => x_return_status,
2424: x_msg_count => x_msg_count,
2425: x_msg_data => x_msg_data
2426: );
2427: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS)
2428: THEN
2429: l_msg_index := 1;
2430: l_msg_count := x_msg_count;
2431: WHILE l_msg_count > 0

Line 2435: FND_API.G_FALSE );

2431: WHILE l_msg_count > 0
2432: LOOP
2433: x_msg_data := FND_MSG_PUB.GET
2434: ( l_msg_index,
2435: FND_API.G_FALSE );
2436: csi_gen_utility_pvt.put_line( ' Error from Get_Chidren.. ');
2437: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2438: l_msg_index := l_msg_index + 1;
2439: l_msg_count := l_msg_count - 1;

Line 2441: RAISE FND_API.G_EXC_ERROR;

2437: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2438: l_msg_index := l_msg_index + 1;
2439: l_msg_count := l_msg_count - 1;
2440: END LOOP;
2441: RAISE FND_API.G_EXC_ERROR;
2442: END IF;
2443:
2444: --
2445: -- Get the last purge date from csi_item_instances table

Line 2459: IF p_time_stamp IS NULL OR p_time_stamp = fnd_api.g_miss_date

2455: WHEN others THEN
2456: NULL;
2457: END;
2458: --
2459: IF p_time_stamp IS NULL OR p_time_stamp = fnd_api.g_miss_date
2460: THEN
2461: x_relationship_tbl:=l_rel_tbl;
2462: ELSIF l_rel_tbl.COUNT >0
2463: THEN

Line 2485: l_new_rec.relationship_id <> fnd_api.g_miss_num

2481: ,p_time_stamp => p_time_stamp);
2482: END IF;
2483: -- Added by sguthiva for bug 2373109
2484: IF l_new_rec.relationship_id IS NOT NULL AND
2485: l_new_rec.relationship_id <> fnd_api.g_miss_num
2486: THEN
2487: IF l_flag='ADD' THEN
2488: l_relationship_tbl(l_returned_rec_count) :=l_new_rec;
2489: -- Added for bug 2999353

Line 2497: p_depth <> fnd_api.g_miss_num AND

2493: --
2494: l_depth:=0;
2495: IF l_ii_relationship_level_tbl.COUNT > 0 AND
2496: p_depth IS NOT NULL AND
2497: p_depth <> fnd_api.g_miss_num AND
2498: p_depth >0
2499: THEN
2500: FOR l_lvl_csr IN l_ii_relationship_level_tbl.FIRST .. l_ii_relationship_level_tbl.LAST
2501: LOOP

Line 2505: l_ii_relationship_level_tbl(l_lvl_csr).relationship_id <> fnd_api.g_miss_num AND

2501: LOOP
2502: IF l_ii_relationship_level_tbl.EXISTS(l_lvl_csr)
2503: THEN
2504: IF l_ii_relationship_level_tbl(l_lvl_csr).relationship_id IS NOT NULL AND
2505: l_ii_relationship_level_tbl(l_lvl_csr).relationship_id <> fnd_api.g_miss_num AND
2506: l_ii_relationship_level_tbl(l_lvl_csr).relationship_id =l_relationship_tbl(l_returned_rec_count).relationship_id
2507: THEN
2508: l_depth:=p_depth-l_ii_relationship_level_tbl(l_lvl_csr).current_level;
2509: EXIT;

Line 2518: l_relationship_query_rec.subject_id:=fnd_api.g_miss_num;

2514: IF l_depth>0 OR
2515: p_depth IS NULL
2516: THEN
2517: l_relationship_query_rec.object_id:=l_relationship_tbl(l_returned_rec_count).subject_id;
2518: l_relationship_query_rec.subject_id:=fnd_api.g_miss_num;
2519: csi_gen_utility_pvt.put_line('Into recurrsive call for get_relationships. ');
2520: csi_ii_relationships_pvt.get_relationships
2521: ( p_api_version => p_api_version
2522: ,p_commit => p_commit

Line 2529: ,p_recursive_flag => fnd_api.g_true

2525: ,p_relationship_query_rec => l_relationship_query_rec
2526: ,p_depth => l_depth
2527: ,p_time_stamp => p_time_stamp
2528: ,p_active_relationship_only => p_active_relationship_only
2529: ,p_recursive_flag => fnd_api.g_true
2530: ,x_relationship_tbl => x_relationship_tbl
2531: ,x_return_status => x_return_status
2532: ,x_msg_count => x_msg_count
2533: ,x_msg_data => x_msg_data

Line 2536: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS)

2532: ,x_msg_count => x_msg_count
2533: ,x_msg_data => x_msg_data
2534: );
2535:
2536: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS)
2537: THEN
2538: l_msg_index := 1;
2539: l_msg_count := x_msg_count;
2540: WHILE l_msg_count > 0

Line 2544: FND_API.G_FALSE );

2540: WHILE l_msg_count > 0
2541: LOOP
2542: x_msg_data := FND_MSG_PUB.GET
2543: ( l_msg_index,
2544: FND_API.G_FALSE );
2545: csi_gen_utility_pvt.put_line( ' Error from recursive Get_relationships.. ');
2546: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2547: l_msg_index := l_msg_index + 1;
2548: l_msg_count := l_msg_count - 1;

Line 2550: RAISE FND_API.G_EXC_ERROR;

2546: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2547: l_msg_index := l_msg_index + 1;
2548: l_msg_count := l_msg_count - 1;
2549: END LOOP;
2550: RAISE FND_API.G_EXC_ERROR;
2551: END IF;
2552:
2553: IF x_relationship_tbl.count > 0
2554: THEN

Line 2560: x_relationship_tbl(i).relationship_id <> fnd_api.g_miss_num

2556: LOOP
2557: IF x_relationship_tbl.EXISTS(i)
2558: THEN
2559: IF x_relationship_tbl(i).relationship_id IS NOT NULL AND
2560: x_relationship_tbl(i).relationship_id <> fnd_api.g_miss_num
2561: THEN
2562: l_returned_rec_count := l_returned_rec_count + 1;
2563: l_relationship_tbl(l_returned_rec_count):=x_relationship_tbl(i);
2564: END IF;

Line 2589: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date) )THEN

2585: END IF;
2586: -- End addition by sguthiva for bug 2373109
2587:
2588: --
2589: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date) )THEN
2590: IF l_relationship_tbl.count > 0
2591: THEN
2592: BEGIN
2593: SELECT 'Y'

Line 2604: AND l_relationship_tbl(l_returned_rec_count).relationship_id <> fnd_api.g_miss_num) --Added for bug 2999353

2600: EXCEPTION
2601: WHEN OTHERS THEN
2602: --l_relationship_tbl(l_returned_rec_count).subject_has_child := 'N';
2603: IF (l_relationship_tbl(l_returned_rec_count).relationship_id IS NOT NULL --Added for bug 2999353
2604: AND l_relationship_tbl(l_returned_rec_count).relationship_id <> fnd_api.g_miss_num) --Added for bug 2999353
2605: THEN
2606: l_relationship_tbl(l_returned_rec_count).subject_has_child := 'N';
2607: END IF;
2608: END;

Line 2633: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)

2629: END LOOP;
2630: END IF;
2631: --
2632: IF l_exists_flag <> 'Y' THEN
2633: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2634: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2635: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2636: THEN
2637: IF p_recursive_flag=fnd_api.g_false

Line 2635: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353

2631: --
2632: IF l_exists_flag <> 'Y' THEN
2633: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2634: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2635: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2636: THEN
2637: IF p_recursive_flag=fnd_api.g_false
2638: THEN
2639: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;

Line 2637: IF p_recursive_flag=fnd_api.g_false

2633: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2634: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2635: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2636: THEN
2637: IF p_recursive_flag=fnd_api.g_false
2638: THEN
2639: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;
2640: CSI_ITEM_INSTANCE_PUB.Get_item_instance_details(
2641: 1.0,

Line 2670: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN

2666: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;
2667: l_instance_rec.active_end_date := NULL;
2668: END IF;
2669: --
2670: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
2671: l_msg_index := 1;
2672: l_msg_count := x_msg_count;
2673: WHILE l_msg_count > 0 LOOP
2674: x_msg_data := FND_MSG_PUB.GET

Line 2676: FND_API.G_FALSE );

2672: l_msg_count := x_msg_count;
2673: WHILE l_msg_count > 0 LOOP
2674: x_msg_data := FND_MSG_PUB.GET
2675: ( l_msg_index,
2676: FND_API.G_FALSE );
2677: csi_gen_utility_pvt.put_line( ' Error from Get_Item_Instance_Details.. ');
2678: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2679: l_msg_index := l_msg_index + 1;
2680: l_msg_count := l_msg_count - 1;

Line 2682: RAISE FND_API.G_EXC_ERROR;

2678: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2679: l_msg_index := l_msg_index + 1;
2680: l_msg_count := l_msg_count - 1;
2681: END LOOP;
2682: RAISE FND_API.G_EXC_ERROR;
2683: END IF;
2684: IF nvl(l_instance_rec.active_end_date,(sysdate+1)) < sysdate THEN
2685: l_ctr := l_exp_inst_tbl.count;
2686: l_ctr := l_ctr + 1;

Line 2766: l_temp_relationship_tbl(l_csr).relationship_id<> fnd_api.g_miss_num

2762: LOOP
2763: IF l_temp_relationship_tbl.EXISTS(l_csr)
2764: THEN
2765: IF l_temp_relationship_tbl(l_csr).relationship_id IS NOT NULL AND
2766: l_temp_relationship_tbl(l_csr).relationship_id<> fnd_api.g_miss_num
2767: THEN
2768: IF l_temp_relationship_tbl(l_csr).relationship_type_code<>'COMPONENT-OF'
2769: THEN
2770: l_exp_count:=l_exp_count + 1;

Line 2815: l_exp_tbl(l_exp_csr).relationship_id <> fnd_api.g_miss_num AND

2811: LOOP
2812: IF l_exp_tbl.EXISTS(l_exp_csr)
2813: THEN
2814: IF l_exp_tbl(l_exp_csr).relationship_id IS NOT NULL AND
2815: l_exp_tbl(l_exp_csr).relationship_id <> fnd_api.g_miss_num AND
2816: nvl(l_exp_tbl(l_exp_csr).attribute1,'NOT-EXPIRED')<>'EXPIRED'
2817: THEN
2818: l_exp_act_tbl.delete;
2819: -- Used the following procedure instead of a cursor which use

Line 2895: l_temp_relationship_tbl(l_tot_csr).relationship_id <> fnd_api.g_miss_num

2891: IF NOT(l_found1)
2892: THEN
2893: l_fin_count1 :=l_fin_count1+1;
2894: IF l_temp_relationship_tbl(l_tot_csr).relationship_id IS NOT NULL AND
2895: l_temp_relationship_tbl(l_tot_csr).relationship_id <> fnd_api.g_miss_num
2896: THEN
2897: x_relationship_tbl(l_fin_count1):=l_temp_relationship_tbl(l_tot_csr);
2898: END IF;
2899: END IF;

Line 2919: WHEN fnd_api.g_exc_error THEN

2915: ( p_count => x_msg_count,
2916: p_data => x_msg_data
2917: );
2918: EXCEPTION
2919: WHEN fnd_api.g_exc_error THEN
2920: -- ROLLBACK TO get_relationships_pvt;
2921: x_return_status := fnd_api.g_ret_sts_error ;
2922: fnd_msg_pub.count_AND_get
2923: (p_count => x_msg_count ,

Line 2921: x_return_status := fnd_api.g_ret_sts_error ;

2917: );
2918: EXCEPTION
2919: WHEN fnd_api.g_exc_error THEN
2920: -- ROLLBACK TO get_relationships_pvt;
2921: x_return_status := fnd_api.g_ret_sts_error ;
2922: fnd_msg_pub.count_AND_get
2923: (p_count => x_msg_count ,
2924: p_data => x_msg_data
2925: );

Line 2927: WHEN fnd_api.g_exc_unexpected_error THEN

2923: (p_count => x_msg_count ,
2924: p_data => x_msg_data
2925: );
2926:
2927: WHEN fnd_api.g_exc_unexpected_error THEN
2928: -- ROLLBACK TO get_relationships_pvt;
2929: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2930: fnd_msg_pub.count_AND_get
2931: (p_count => x_msg_count ,

Line 2929: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2925: );
2926:
2927: WHEN fnd_api.g_exc_unexpected_error THEN
2928: -- ROLLBACK TO get_relationships_pvt;
2929: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2930: fnd_msg_pub.count_AND_get
2931: (p_count => x_msg_count ,
2932: p_data => x_msg_data
2933: );

Line 2937: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2933: );
2934:
2935: WHEN OTHERS THEN
2936: -- ROLLBACK TO get_relationships_pvt;
2937: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2938: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2939: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
2940: END IF;
2941: fnd_msg_pub.count_AND_get

Line 2956: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num

2952: p_subject_id IN NUMBER
2953: ) RETURN BOOLEAN IS
2954:
2955: BEGIN
2956: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num
2957: THEN
2958: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2959: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2960: THEN

Line 2958: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)

2954:
2955: BEGIN
2956: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num
2957: THEN
2958: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2959: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2960: THEN
2961: RETURN TRUE;
2962: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)

Line 2959: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))

2955: BEGIN
2956: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num
2957: THEN
2958: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2959: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2960: THEN
2961: RETURN TRUE;
2962: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2963: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))

Line 2962: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)

2958: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2959: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2960: THEN
2961: RETURN TRUE;
2962: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2963: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
2964: THEN
2965: RETURN FALSE;
2966: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)

Line 2963: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))

2959: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2960: THEN
2961: RETURN TRUE;
2962: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2963: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
2964: THEN
2965: RETURN FALSE;
2966: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2967: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))

Line 2966: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)

2962: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
2963: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
2964: THEN
2965: RETURN FALSE;
2966: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2967: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2968: THEN
2969: RETURN TRUE;
2970: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)

Line 2967: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))

2963: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
2964: THEN
2965: RETURN FALSE;
2966: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2967: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2968: THEN
2969: RETURN TRUE;
2970: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2971: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))

Line 2970: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)

2966: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2967: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2968: THEN
2969: RETURN TRUE;
2970: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2971: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
2972: THEN
2973: RETURN TRUE;
2974: END IF;

Line 2971: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))

2967: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
2968: THEN
2969: RETURN TRUE;
2970: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
2971: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
2972: THEN
2973: RETURN TRUE;
2974: END IF;
2975: END IF;

Line 3225: AND(p_subject_id is null OR p_subject_id= fnd_api.g_miss_num)

3221: l_relship_type_code VARCHAR2(30);
3222: l_dummy VARCHAR2(1) :=NULL;
3223: BEGIN
3224: IF p_relationship_id is not null
3225: AND(p_subject_id is null OR p_subject_id= fnd_api.g_miss_num)
3226: THEN
3227: RETURN TRUE;
3228: ELSE
3229: SELECT subject_id,relationship_type_code

Line 3318: x_return_status := fnd_api.g_ret_sts_success;

3314: CONNECT BY object_id = PRIOR subject_id;
3315: l_dummy VARCHAR2(1); */
3316:
3317: BEGIN
3318: x_return_status := fnd_api.g_ret_sts_success;
3319: IF p_subject_id IS NULL OR
3320: p_subject_id = FND_API.G_MISS_NUM OR
3321: p_object_id IS NULL OR
3322: p_object_id = FND_API.G_MISS_NUM THEN

Line 3320: p_subject_id = FND_API.G_MISS_NUM OR

3316:
3317: BEGIN
3318: x_return_status := fnd_api.g_ret_sts_success;
3319: IF p_subject_id IS NULL OR
3320: p_subject_id = FND_API.G_MISS_NUM OR
3321: p_object_id IS NULL OR
3322: p_object_id = FND_API.G_MISS_NUM THEN
3323: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3324: fnd_msg_pub.add;

Line 3322: p_object_id = FND_API.G_MISS_NUM THEN

3318: x_return_status := fnd_api.g_ret_sts_success;
3319: IF p_subject_id IS NULL OR
3320: p_subject_id = FND_API.G_MISS_NUM OR
3321: p_object_id IS NULL OR
3322: p_object_id = FND_API.G_MISS_NUM THEN
3323: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3324: fnd_msg_pub.add;
3325: x_return_status := fnd_api.g_ret_sts_error;
3326: RETURN;

Line 3325: x_return_status := fnd_api.g_ret_sts_error;

3321: p_object_id IS NULL OR
3322: p_object_id = FND_API.G_MISS_NUM THEN
3323: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3324: fnd_msg_pub.add;
3325: x_return_status := fnd_api.g_ret_sts_error;
3326: RETURN;
3327: END IF;
3328: --
3329: p_relationship_query_rec.object_id := p_subject_id; -- To check for Loop

Line 3337: p_active_relationship_only => FND_API.G_TRUE,

3333: csi_ii_relationships_pvt.Get_Children
3334: ( p_relationship_query_rec => p_relationship_query_rec,
3335: p_rel_tbl => l_rel_tbl,
3336: p_depth => NULL,
3337: p_active_relationship_only => FND_API.G_TRUE,
3338: p_active_instances_only => FND_API.G_FALSE,
3339: p_time_stamp => FND_API.G_MISS_DATE,
3340: p_get_dfs => FND_API.G_FALSE,
3341: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,

Line 3338: p_active_instances_only => FND_API.G_FALSE,

3334: ( p_relationship_query_rec => p_relationship_query_rec,
3335: p_rel_tbl => l_rel_tbl,
3336: p_depth => NULL,
3337: p_active_relationship_only => FND_API.G_TRUE,
3338: p_active_instances_only => FND_API.G_FALSE,
3339: p_time_stamp => FND_API.G_MISS_DATE,
3340: p_get_dfs => FND_API.G_FALSE,
3341: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
3342: x_return_status => x_return_status,

Line 3339: p_time_stamp => FND_API.G_MISS_DATE,

3335: p_rel_tbl => l_rel_tbl,
3336: p_depth => NULL,
3337: p_active_relationship_only => FND_API.G_TRUE,
3338: p_active_instances_only => FND_API.G_FALSE,
3339: p_time_stamp => FND_API.G_MISS_DATE,
3340: p_get_dfs => FND_API.G_FALSE,
3341: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
3342: x_return_status => x_return_status,
3343: x_msg_count => x_msg_count,

Line 3340: p_get_dfs => FND_API.G_FALSE,

3336: p_depth => NULL,
3337: p_active_relationship_only => FND_API.G_TRUE,
3338: p_active_instances_only => FND_API.G_FALSE,
3339: p_time_stamp => FND_API.G_MISS_DATE,
3340: p_get_dfs => FND_API.G_FALSE,
3341: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
3342: x_return_status => x_return_status,
3343: x_msg_count => x_msg_count,
3344: x_msg_data => x_msg_data

Line 3347: IF x_return_status = FND_API.G_RET_STS_SUCCESS AND

3343: x_msg_count => x_msg_count,
3344: x_msg_data => x_msg_data
3345: );
3346: --
3347: IF x_return_status = FND_API.G_RET_STS_SUCCESS AND
3348: l_rel_tbl.count > 0 THEN
3349: FOR j in l_rel_tbl.FIRST .. l_rel_tbl.LAST LOOP
3350: IF l_rel_tbl(j).subject_id = p_object_id THEN
3351: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');

Line 3353: x_return_status := fnd_api.g_ret_sts_error;

3349: FOR j in l_rel_tbl.FIRST .. l_rel_tbl.LAST LOOP
3350: IF l_rel_tbl(j).subject_id = p_object_id THEN
3351: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');
3352: fnd_msg_pub.add;
3353: x_return_status := fnd_api.g_ret_sts_error;
3354: exit;
3355: END IF;
3356: END LOOP;
3357: END IF;

Line 3361: x_return_status := fnd_api.g_ret_sts_error;

3357: END IF;
3358: ELSE
3359: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3360: fnd_msg_pub.add;
3361: x_return_status := fnd_api.g_ret_sts_error;
3362: END IF;
3363: END check_for_object;
3364:
3365: PROCEDURE validate_history(p_old_relship_rec IN csi_datastructures_pub.ii_relationship_rec,

Line 3438: x_return_status := fnd_api.g_ret_sts_success;

3434:
3435: BEGIN
3436:
3437:
3438: x_return_status := fnd_api.g_ret_sts_success;
3439: --
3440: IF csi_datastructures_pub.g_install_param_rec.fetch_flag IS NULL THEN
3441: csi_gen_utility_pvt.populate_install_param_rec;
3442: END IF;

Line 3449: RAISE FND_API.G_EXC_ERROR;

3445: --
3446: IF l_full_dump IS NULL THEN
3447: FND_MESSAGE.SET_NAME('CSI','CSI_API_GET_FULL_DUMP_FAILED');
3448: FND_MSG_PUB.ADD;
3449: RAISE FND_API.G_EXC_ERROR;
3450: END IF;
3451: --
3452: IF p_flag = 'EXPIRE' THEN
3453: l_new_relship_rec.active_end_date := p_sysdate;

Line 3471: p_relationship_id => fnd_api.g_miss_num ,

3467: IF l_rel_hist_csr.full_dump_flag = 'Y'
3468: THEN
3469: csi_ii_relationships_h_pkg.update_row(
3470: p_relationship_history_id => l_rel_hist_id ,
3471: p_relationship_id => fnd_api.g_miss_num ,
3472: p_transaction_id => fnd_api.g_miss_num ,
3473: p_old_subject_id => fnd_api.g_miss_num ,
3474: p_new_subject_id => l_new_relship_rec.subject_id ,
3475: p_old_position_reference => fnd_api.g_miss_char ,

Line 3472: p_transaction_id => fnd_api.g_miss_num ,

3468: THEN
3469: csi_ii_relationships_h_pkg.update_row(
3470: p_relationship_history_id => l_rel_hist_id ,
3471: p_relationship_id => fnd_api.g_miss_num ,
3472: p_transaction_id => fnd_api.g_miss_num ,
3473: p_old_subject_id => fnd_api.g_miss_num ,
3474: p_new_subject_id => l_new_relship_rec.subject_id ,
3475: p_old_position_reference => fnd_api.g_miss_char ,
3476: p_new_position_reference => l_new_relship_rec.position_reference,

Line 3473: p_old_subject_id => fnd_api.g_miss_num ,

3469: csi_ii_relationships_h_pkg.update_row(
3470: p_relationship_history_id => l_rel_hist_id ,
3471: p_relationship_id => fnd_api.g_miss_num ,
3472: p_transaction_id => fnd_api.g_miss_num ,
3473: p_old_subject_id => fnd_api.g_miss_num ,
3474: p_new_subject_id => l_new_relship_rec.subject_id ,
3475: p_old_position_reference => fnd_api.g_miss_char ,
3476: p_new_position_reference => l_new_relship_rec.position_reference,
3477: p_old_active_start_date => fnd_api.g_miss_date ,

Line 3475: p_old_position_reference => fnd_api.g_miss_char ,

3471: p_relationship_id => fnd_api.g_miss_num ,
3472: p_transaction_id => fnd_api.g_miss_num ,
3473: p_old_subject_id => fnd_api.g_miss_num ,
3474: p_new_subject_id => l_new_relship_rec.subject_id ,
3475: p_old_position_reference => fnd_api.g_miss_char ,
3476: p_new_position_reference => l_new_relship_rec.position_reference,
3477: p_old_active_start_date => fnd_api.g_miss_date ,
3478: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3479: p_old_active_end_date => fnd_api.g_miss_date ,

Line 3477: p_old_active_start_date => fnd_api.g_miss_date ,

3473: p_old_subject_id => fnd_api.g_miss_num ,
3474: p_new_subject_id => l_new_relship_rec.subject_id ,
3475: p_old_position_reference => fnd_api.g_miss_char ,
3476: p_new_position_reference => l_new_relship_rec.position_reference,
3477: p_old_active_start_date => fnd_api.g_miss_date ,
3478: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3479: p_old_active_end_date => fnd_api.g_miss_date ,
3480: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3481: p_old_mandatory_flag => fnd_api.g_miss_char ,

Line 3479: p_old_active_end_date => fnd_api.g_miss_date ,

3475: p_old_position_reference => fnd_api.g_miss_char ,
3476: p_new_position_reference => l_new_relship_rec.position_reference,
3477: p_old_active_start_date => fnd_api.g_miss_date ,
3478: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3479: p_old_active_end_date => fnd_api.g_miss_date ,
3480: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3481: p_old_mandatory_flag => fnd_api.g_miss_char ,
3482: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3483: p_old_context => fnd_api.g_miss_char ,

Line 3481: p_old_mandatory_flag => fnd_api.g_miss_char ,

3477: p_old_active_start_date => fnd_api.g_miss_date ,
3478: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3479: p_old_active_end_date => fnd_api.g_miss_date ,
3480: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3481: p_old_mandatory_flag => fnd_api.g_miss_char ,
3482: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3483: p_old_context => fnd_api.g_miss_char ,
3484: p_new_context => l_new_relship_rec.context ,
3485: p_old_attribute1 => fnd_api.g_miss_char ,

Line 3483: p_old_context => fnd_api.g_miss_char ,

3479: p_old_active_end_date => fnd_api.g_miss_date ,
3480: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3481: p_old_mandatory_flag => fnd_api.g_miss_char ,
3482: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3483: p_old_context => fnd_api.g_miss_char ,
3484: p_new_context => l_new_relship_rec.context ,
3485: p_old_attribute1 => fnd_api.g_miss_char ,
3486: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3487: p_old_attribute2 => fnd_api.g_miss_char ,

Line 3485: p_old_attribute1 => fnd_api.g_miss_char ,

3481: p_old_mandatory_flag => fnd_api.g_miss_char ,
3482: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3483: p_old_context => fnd_api.g_miss_char ,
3484: p_new_context => l_new_relship_rec.context ,
3485: p_old_attribute1 => fnd_api.g_miss_char ,
3486: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3487: p_old_attribute2 => fnd_api.g_miss_char ,
3488: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3489: p_old_attribute3 => fnd_api.g_miss_char ,

Line 3487: p_old_attribute2 => fnd_api.g_miss_char ,

3483: p_old_context => fnd_api.g_miss_char ,
3484: p_new_context => l_new_relship_rec.context ,
3485: p_old_attribute1 => fnd_api.g_miss_char ,
3486: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3487: p_old_attribute2 => fnd_api.g_miss_char ,
3488: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3489: p_old_attribute3 => fnd_api.g_miss_char ,
3490: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3491: p_old_attribute4 => fnd_api.g_miss_char ,

Line 3489: p_old_attribute3 => fnd_api.g_miss_char ,

3485: p_old_attribute1 => fnd_api.g_miss_char ,
3486: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3487: p_old_attribute2 => fnd_api.g_miss_char ,
3488: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3489: p_old_attribute3 => fnd_api.g_miss_char ,
3490: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3491: p_old_attribute4 => fnd_api.g_miss_char ,
3492: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3493: p_old_attribute5 => fnd_api.g_miss_char ,

Line 3491: p_old_attribute4 => fnd_api.g_miss_char ,

3487: p_old_attribute2 => fnd_api.g_miss_char ,
3488: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3489: p_old_attribute3 => fnd_api.g_miss_char ,
3490: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3491: p_old_attribute4 => fnd_api.g_miss_char ,
3492: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3493: p_old_attribute5 => fnd_api.g_miss_char ,
3494: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3495: p_old_attribute6 => fnd_api.g_miss_char ,

Line 3493: p_old_attribute5 => fnd_api.g_miss_char ,

3489: p_old_attribute3 => fnd_api.g_miss_char ,
3490: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3491: p_old_attribute4 => fnd_api.g_miss_char ,
3492: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3493: p_old_attribute5 => fnd_api.g_miss_char ,
3494: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3495: p_old_attribute6 => fnd_api.g_miss_char ,
3496: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3497: p_old_attribute7 => fnd_api.g_miss_char ,

Line 3495: p_old_attribute6 => fnd_api.g_miss_char ,

3491: p_old_attribute4 => fnd_api.g_miss_char ,
3492: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3493: p_old_attribute5 => fnd_api.g_miss_char ,
3494: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3495: p_old_attribute6 => fnd_api.g_miss_char ,
3496: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3497: p_old_attribute7 => fnd_api.g_miss_char ,
3498: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3499: p_old_attribute8 => fnd_api.g_miss_char ,

Line 3497: p_old_attribute7 => fnd_api.g_miss_char ,

3493: p_old_attribute5 => fnd_api.g_miss_char ,
3494: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3495: p_old_attribute6 => fnd_api.g_miss_char ,
3496: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3497: p_old_attribute7 => fnd_api.g_miss_char ,
3498: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3499: p_old_attribute8 => fnd_api.g_miss_char ,
3500: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3501: p_old_attribute9 => fnd_api.g_miss_char ,

Line 3499: p_old_attribute8 => fnd_api.g_miss_char ,

3495: p_old_attribute6 => fnd_api.g_miss_char ,
3496: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3497: p_old_attribute7 => fnd_api.g_miss_char ,
3498: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3499: p_old_attribute8 => fnd_api.g_miss_char ,
3500: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3501: p_old_attribute9 => fnd_api.g_miss_char ,
3502: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3503: p_old_attribute10 => fnd_api.g_miss_char ,

Line 3501: p_old_attribute9 => fnd_api.g_miss_char ,

3497: p_old_attribute7 => fnd_api.g_miss_char ,
3498: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3499: p_old_attribute8 => fnd_api.g_miss_char ,
3500: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3501: p_old_attribute9 => fnd_api.g_miss_char ,
3502: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3503: p_old_attribute10 => fnd_api.g_miss_char ,
3504: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3505: p_old_attribute11 => fnd_api.g_miss_char ,

Line 3503: p_old_attribute10 => fnd_api.g_miss_char ,

3499: p_old_attribute8 => fnd_api.g_miss_char ,
3500: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3501: p_old_attribute9 => fnd_api.g_miss_char ,
3502: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3503: p_old_attribute10 => fnd_api.g_miss_char ,
3504: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3505: p_old_attribute11 => fnd_api.g_miss_char ,
3506: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3507: p_old_attribute12 => fnd_api.g_miss_char ,

Line 3505: p_old_attribute11 => fnd_api.g_miss_char ,

3501: p_old_attribute9 => fnd_api.g_miss_char ,
3502: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3503: p_old_attribute10 => fnd_api.g_miss_char ,
3504: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3505: p_old_attribute11 => fnd_api.g_miss_char ,
3506: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3507: p_old_attribute12 => fnd_api.g_miss_char ,
3508: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3509: p_old_attribute13 => fnd_api.g_miss_char ,

Line 3507: p_old_attribute12 => fnd_api.g_miss_char ,

3503: p_old_attribute10 => fnd_api.g_miss_char ,
3504: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3505: p_old_attribute11 => fnd_api.g_miss_char ,
3506: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3507: p_old_attribute12 => fnd_api.g_miss_char ,
3508: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3509: p_old_attribute13 => fnd_api.g_miss_char ,
3510: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3511: p_old_attribute14 => fnd_api.g_miss_char ,

Line 3509: p_old_attribute13 => fnd_api.g_miss_char ,

3505: p_old_attribute11 => fnd_api.g_miss_char ,
3506: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3507: p_old_attribute12 => fnd_api.g_miss_char ,
3508: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3509: p_old_attribute13 => fnd_api.g_miss_char ,
3510: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3511: p_old_attribute14 => fnd_api.g_miss_char ,
3512: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3513: p_old_attribute15 => fnd_api.g_miss_char ,

Line 3511: p_old_attribute14 => fnd_api.g_miss_char ,

3507: p_old_attribute12 => fnd_api.g_miss_char ,
3508: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3509: p_old_attribute13 => fnd_api.g_miss_char ,
3510: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3511: p_old_attribute14 => fnd_api.g_miss_char ,
3512: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3513: p_old_attribute15 => fnd_api.g_miss_char ,
3514: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3515: p_full_dump_flag => fnd_api.g_miss_char ,

Line 3513: p_old_attribute15 => fnd_api.g_miss_char ,

3509: p_old_attribute13 => fnd_api.g_miss_char ,
3510: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3511: p_old_attribute14 => fnd_api.g_miss_char ,
3512: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3513: p_old_attribute15 => fnd_api.g_miss_char ,
3514: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3515: p_full_dump_flag => fnd_api.g_miss_char ,
3516: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3517: p_creation_date => fnd_api.g_miss_date ,

Line 3515: p_full_dump_flag => fnd_api.g_miss_char ,

3511: p_old_attribute14 => fnd_api.g_miss_char ,
3512: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3513: p_old_attribute15 => fnd_api.g_miss_char ,
3514: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3515: p_full_dump_flag => fnd_api.g_miss_char ,
3516: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3517: p_creation_date => fnd_api.g_miss_date ,
3518: p_last_updated_by => fnd_global.user_id ,
3519: p_last_update_date => SYSDATE ,

Line 3516: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,

3512: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3513: p_old_attribute15 => fnd_api.g_miss_char ,
3514: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3515: p_full_dump_flag => fnd_api.g_miss_char ,
3516: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3517: p_creation_date => fnd_api.g_miss_date ,
3518: p_last_updated_by => fnd_global.user_id ,
3519: p_last_update_date => SYSDATE ,
3520: p_last_update_login => fnd_global.conc_login_id ,

Line 3517: p_creation_date => fnd_api.g_miss_date ,

3513: p_old_attribute15 => fnd_api.g_miss_char ,
3514: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3515: p_full_dump_flag => fnd_api.g_miss_char ,
3516: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3517: p_creation_date => fnd_api.g_miss_date ,
3518: p_last_updated_by => fnd_global.user_id ,
3519: p_last_update_date => SYSDATE ,
3520: p_last_update_login => fnd_global.conc_login_id ,
3521: p_object_version_number => fnd_api.g_miss_num );

Line 3521: p_object_version_number => fnd_api.g_miss_num );

3517: p_creation_date => fnd_api.g_miss_date ,
3518: p_last_updated_by => fnd_global.user_id ,
3519: p_last_update_date => SYSDATE ,
3520: p_last_update_login => fnd_global.conc_login_id ,
3521: p_object_version_number => fnd_api.g_miss_num );
3522: ELSE
3523: --
3524: IF ( l_rel_hist_csr.old_subject_id IS NULL
3525: AND l_rel_hist_csr.new_subject_id IS NULL ) THEN

Line 3527: OR ( l_new_relship_rec.subject_id = fnd_api.g_miss_num ) THEN

3523: --
3524: IF ( l_rel_hist_csr.old_subject_id IS NULL
3525: AND l_rel_hist_csr.new_subject_id IS NULL ) THEN
3526: IF ( l_new_relship_rec.subject_id = l_old_relship_rec.subject_id )
3527: OR ( l_new_relship_rec.subject_id = fnd_api.g_miss_num ) THEN
3528: l_rel_hist_csr.old_subject_id := NULL;
3529: l_rel_hist_csr.new_subject_id := NULL;
3530: ELSE
3531: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;

Line 3531: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;

3527: OR ( l_new_relship_rec.subject_id = fnd_api.g_miss_num ) THEN
3528: l_rel_hist_csr.old_subject_id := NULL;
3529: l_rel_hist_csr.new_subject_id := NULL;
3530: ELSE
3531: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;
3532: l_rel_hist_csr.new_subject_id := l_new_relship_rec.subject_id;
3533: END IF;
3534: ELSE
3535: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;

Line 3535: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;

3531: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;
3532: l_rel_hist_csr.new_subject_id := l_new_relship_rec.subject_id;
3533: END IF;
3534: ELSE
3535: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;
3536: l_rel_hist_csr.new_subject_id := l_new_relship_rec.subject_id;
3537: END IF;
3538: --
3539: IF ( l_rel_hist_csr.old_position_reference IS NULL

Line 3542: OR ( l_new_relship_rec.position_reference = fnd_api.g_miss_char ) THEN

3538: --
3539: IF ( l_rel_hist_csr.old_position_reference IS NULL
3540: AND l_rel_hist_csr.new_position_reference IS NULL ) THEN
3541: IF ( l_new_relship_rec.position_reference = l_old_relship_rec.position_reference )
3542: OR ( l_new_relship_rec.position_reference = fnd_api.g_miss_char ) THEN
3543: l_rel_hist_csr.old_position_reference := NULL;
3544: l_rel_hist_csr.new_position_reference := NULL;
3545: ELSE
3546: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;

Line 3546: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;

3542: OR ( l_new_relship_rec.position_reference = fnd_api.g_miss_char ) THEN
3543: l_rel_hist_csr.old_position_reference := NULL;
3544: l_rel_hist_csr.new_position_reference := NULL;
3545: ELSE
3546: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;
3547: l_rel_hist_csr.new_position_reference := l_new_relship_rec.position_reference;
3548: END IF;
3549: ELSE
3550: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;

Line 3550: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;

3546: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;
3547: l_rel_hist_csr.new_position_reference := l_new_relship_rec.position_reference;
3548: END IF;
3549: ELSE
3550: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;
3551: l_rel_hist_csr.new_position_reference := l_new_relship_rec.position_reference;
3552: END IF;
3553: --
3554: IF ( l_rel_hist_csr.old_active_start_date IS NULL

Line 3557: OR ( l_new_relship_rec.active_start_date = fnd_api.g_miss_date ) THEN

3553: --
3554: IF ( l_rel_hist_csr.old_active_start_date IS NULL
3555: AND l_rel_hist_csr.new_active_start_date IS NULL ) THEN
3556: IF ( l_new_relship_rec.active_start_date = l_old_relship_rec.active_start_date )
3557: OR ( l_new_relship_rec.active_start_date = fnd_api.g_miss_date ) THEN
3558: l_rel_hist_csr.old_active_start_date := NULL;
3559: l_rel_hist_csr.new_active_start_date := NULL;
3560: ELSE
3561: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;

Line 3561: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;

3557: OR ( l_new_relship_rec.active_start_date = fnd_api.g_miss_date ) THEN
3558: l_rel_hist_csr.old_active_start_date := NULL;
3559: l_rel_hist_csr.new_active_start_date := NULL;
3560: ELSE
3561: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;
3562: l_rel_hist_csr.new_active_start_date := l_new_relship_rec.active_start_date;
3563: END IF;
3564: ELSE
3565: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;

Line 3565: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;

3561: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;
3562: l_rel_hist_csr.new_active_start_date := l_new_relship_rec.active_start_date;
3563: END IF;
3564: ELSE
3565: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;
3566: l_rel_hist_csr.new_active_start_date := l_new_relship_rec.active_start_date;
3567: END IF;
3568: --
3569: IF ( l_rel_hist_csr.old_active_end_date IS NULL

Line 3572: OR ( l_new_relship_rec.active_end_date = fnd_api.g_miss_date ) THEN

3568: --
3569: IF ( l_rel_hist_csr.old_active_end_date IS NULL
3570: AND l_rel_hist_csr.new_active_end_date IS NULL ) THEN
3571: IF ( l_new_relship_rec.active_end_date = l_old_relship_rec.active_end_date )
3572: OR ( l_new_relship_rec.active_end_date = fnd_api.g_miss_date ) THEN
3573: l_rel_hist_csr.old_active_end_date := NULL;
3574: l_rel_hist_csr.new_active_end_date := NULL;
3575: ELSE
3576: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;

Line 3576: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;

3572: OR ( l_new_relship_rec.active_end_date = fnd_api.g_miss_date ) THEN
3573: l_rel_hist_csr.old_active_end_date := NULL;
3574: l_rel_hist_csr.new_active_end_date := NULL;
3575: ELSE
3576: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;
3577: l_rel_hist_csr.new_active_end_date := l_new_relship_rec.active_end_date;
3578: END IF;
3579: ELSE
3580: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;

Line 3580: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;

3576: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;
3577: l_rel_hist_csr.new_active_end_date := l_new_relship_rec.active_end_date;
3578: END IF;
3579: ELSE
3580: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;
3581: l_rel_hist_csr.new_active_end_date := l_new_relship_rec.active_end_date;
3582: END IF;
3583: --
3584: IF ( l_rel_hist_csr.old_mandatory_flag IS NULL

Line 3587: OR ( l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char ) THEN

3583: --
3584: IF ( l_rel_hist_csr.old_mandatory_flag IS NULL
3585: AND l_rel_hist_csr.new_mandatory_flag IS NULL ) THEN
3586: IF ( l_new_relship_rec.mandatory_flag = l_old_relship_rec.mandatory_flag )
3587: OR ( l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char ) THEN
3588: l_rel_hist_csr.old_mandatory_flag := NULL;
3589: l_rel_hist_csr.new_mandatory_flag := NULL;
3590: ELSE
3591: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;

Line 3591: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;

3587: OR ( l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char ) THEN
3588: l_rel_hist_csr.old_mandatory_flag := NULL;
3589: l_rel_hist_csr.new_mandatory_flag := NULL;
3590: ELSE
3591: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;
3592: l_rel_hist_csr.new_mandatory_flag := l_new_relship_rec.mandatory_flag;
3593: END IF;
3594: ELSE
3595: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;

Line 3595: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;

3591: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;
3592: l_rel_hist_csr.new_mandatory_flag := l_new_relship_rec.mandatory_flag;
3593: END IF;
3594: ELSE
3595: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;
3596: l_rel_hist_csr.new_mandatory_flag := l_new_relship_rec.mandatory_flag;
3597: END IF;
3598: --
3599: IF ( l_rel_hist_csr.old_context IS NULL

Line 3602: OR ( l_new_relship_rec.context = fnd_api.g_miss_char ) THEN

3598: --
3599: IF ( l_rel_hist_csr.old_context IS NULL
3600: AND l_rel_hist_csr.new_context IS NULL ) THEN
3601: IF ( l_new_relship_rec.context = l_old_relship_rec.context )
3602: OR ( l_new_relship_rec.context = fnd_api.g_miss_char ) THEN
3603: l_rel_hist_csr.old_context := NULL;
3604: l_rel_hist_csr.new_context := NULL;
3605: ELSE
3606: l_rel_hist_csr.old_context := fnd_api.g_miss_char;

Line 3606: l_rel_hist_csr.old_context := fnd_api.g_miss_char;

3602: OR ( l_new_relship_rec.context = fnd_api.g_miss_char ) THEN
3603: l_rel_hist_csr.old_context := NULL;
3604: l_rel_hist_csr.new_context := NULL;
3605: ELSE
3606: l_rel_hist_csr.old_context := fnd_api.g_miss_char;
3607: l_rel_hist_csr.new_context := l_new_relship_rec.context;
3608: END IF;
3609: ELSE
3610: l_rel_hist_csr.old_context := fnd_api.g_miss_char;

Line 3610: l_rel_hist_csr.old_context := fnd_api.g_miss_char;

3606: l_rel_hist_csr.old_context := fnd_api.g_miss_char;
3607: l_rel_hist_csr.new_context := l_new_relship_rec.context;
3608: END IF;
3609: ELSE
3610: l_rel_hist_csr.old_context := fnd_api.g_miss_char;
3611: l_rel_hist_csr.new_context := l_new_relship_rec.context;
3612: END IF;
3613: --
3614: IF ( l_rel_hist_csr.old_attribute1 IS NULL

Line 3617: OR ( l_new_relship_rec.attribute1 = fnd_api.g_miss_char ) THEN

3613: --
3614: IF ( l_rel_hist_csr.old_attribute1 IS NULL
3615: AND l_rel_hist_csr.new_attribute1 IS NULL ) THEN
3616: IF ( l_new_relship_rec.attribute1 = l_old_relship_rec.attribute1 )
3617: OR ( l_new_relship_rec.attribute1 = fnd_api.g_miss_char ) THEN
3618: l_rel_hist_csr.old_attribute1 := NULL;
3619: l_rel_hist_csr.new_attribute1 := NULL;
3620: ELSE
3621: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;

Line 3621: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;

3617: OR ( l_new_relship_rec.attribute1 = fnd_api.g_miss_char ) THEN
3618: l_rel_hist_csr.old_attribute1 := NULL;
3619: l_rel_hist_csr.new_attribute1 := NULL;
3620: ELSE
3621: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;
3622: l_rel_hist_csr.new_attribute1 := l_new_relship_rec.attribute1;
3623: END IF;
3624: ELSE
3625: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;

Line 3625: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;

3621: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;
3622: l_rel_hist_csr.new_attribute1 := l_new_relship_rec.attribute1;
3623: END IF;
3624: ELSE
3625: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;
3626: l_rel_hist_csr.new_attribute1 := l_new_relship_rec.attribute1;
3627: END IF;
3628: --
3629: IF ( l_rel_hist_csr.old_attribute2 IS NULL

Line 3632: OR ( l_new_relship_rec.attribute2 = fnd_api.g_miss_char ) THEN

3628: --
3629: IF ( l_rel_hist_csr.old_attribute2 IS NULL
3630: AND l_rel_hist_csr.new_attribute2 IS NULL ) THEN
3631: IF ( l_new_relship_rec.attribute2 = l_old_relship_rec.attribute2 )
3632: OR ( l_new_relship_rec.attribute2 = fnd_api.g_miss_char ) THEN
3633: l_rel_hist_csr.old_attribute2 := NULL;
3634: l_rel_hist_csr.new_attribute2 := NULL;
3635: ELSE
3636: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;

Line 3636: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;

3632: OR ( l_new_relship_rec.attribute2 = fnd_api.g_miss_char ) THEN
3633: l_rel_hist_csr.old_attribute2 := NULL;
3634: l_rel_hist_csr.new_attribute2 := NULL;
3635: ELSE
3636: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;
3637: l_rel_hist_csr.new_attribute2 := l_new_relship_rec.attribute2;
3638: END IF;
3639: ELSE
3640: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;

Line 3640: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;

3636: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;
3637: l_rel_hist_csr.new_attribute2 := l_new_relship_rec.attribute2;
3638: END IF;
3639: ELSE
3640: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;
3641: l_rel_hist_csr.new_attribute2 := l_new_relship_rec.attribute2;
3642: END IF;
3643: --
3644: IF ( l_rel_hist_csr.old_attribute3 IS NULL

Line 3647: OR ( l_new_relship_rec.attribute3 = fnd_api.g_miss_char ) THEN

3643: --
3644: IF ( l_rel_hist_csr.old_attribute3 IS NULL
3645: AND l_rel_hist_csr.new_attribute3 IS NULL ) THEN
3646: IF ( l_new_relship_rec.attribute3 = l_old_relship_rec.attribute3 )
3647: OR ( l_new_relship_rec.attribute3 = fnd_api.g_miss_char ) THEN
3648: l_rel_hist_csr.old_attribute3 := NULL;
3649: l_rel_hist_csr.new_attribute3 := NULL;
3650: ELSE
3651: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;

Line 3651: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;

3647: OR ( l_new_relship_rec.attribute3 = fnd_api.g_miss_char ) THEN
3648: l_rel_hist_csr.old_attribute3 := NULL;
3649: l_rel_hist_csr.new_attribute3 := NULL;
3650: ELSE
3651: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;
3652: l_rel_hist_csr.new_attribute3 := l_new_relship_rec.attribute3;
3653: END IF;
3654: ELSE
3655: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;

Line 3655: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;

3651: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;
3652: l_rel_hist_csr.new_attribute3 := l_new_relship_rec.attribute3;
3653: END IF;
3654: ELSE
3655: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;
3656: l_rel_hist_csr.new_attribute3 := l_new_relship_rec.attribute3;
3657: END IF;
3658: --
3659: IF ( l_rel_hist_csr.old_attribute4 IS NULL

Line 3662: OR ( l_new_relship_rec.attribute4 = fnd_api.g_miss_char ) THEN

3658: --
3659: IF ( l_rel_hist_csr.old_attribute4 IS NULL
3660: AND l_rel_hist_csr.new_attribute4 IS NULL ) THEN
3661: IF ( l_new_relship_rec.attribute4 = l_old_relship_rec.attribute4 )
3662: OR ( l_new_relship_rec.attribute4 = fnd_api.g_miss_char ) THEN
3663: l_rel_hist_csr.old_attribute4 := NULL;
3664: l_rel_hist_csr.new_attribute4 := NULL;
3665: ELSE
3666: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;

Line 3666: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;

3662: OR ( l_new_relship_rec.attribute4 = fnd_api.g_miss_char ) THEN
3663: l_rel_hist_csr.old_attribute4 := NULL;
3664: l_rel_hist_csr.new_attribute4 := NULL;
3665: ELSE
3666: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;
3667: l_rel_hist_csr.new_attribute4 := l_new_relship_rec.attribute4;
3668: END IF;
3669: ELSE
3670: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;

Line 3670: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;

3666: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;
3667: l_rel_hist_csr.new_attribute4 := l_new_relship_rec.attribute4;
3668: END IF;
3669: ELSE
3670: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;
3671: l_rel_hist_csr.new_attribute4 := l_new_relship_rec.attribute4;
3672: END IF;
3673: --
3674: IF ( l_rel_hist_csr.old_attribute5 IS NULL

Line 3677: OR ( l_new_relship_rec.attribute5 = fnd_api.g_miss_char ) THEN

3673: --
3674: IF ( l_rel_hist_csr.old_attribute5 IS NULL
3675: AND l_rel_hist_csr.new_attribute5 IS NULL ) THEN
3676: IF ( l_new_relship_rec.attribute5 = l_old_relship_rec.attribute5 )
3677: OR ( l_new_relship_rec.attribute5 = fnd_api.g_miss_char ) THEN
3678: l_rel_hist_csr.old_attribute5 := NULL;
3679: l_rel_hist_csr.new_attribute5 := NULL;
3680: ELSE
3681: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;

Line 3681: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;

3677: OR ( l_new_relship_rec.attribute5 = fnd_api.g_miss_char ) THEN
3678: l_rel_hist_csr.old_attribute5 := NULL;
3679: l_rel_hist_csr.new_attribute5 := NULL;
3680: ELSE
3681: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;
3682: l_rel_hist_csr.new_attribute5 := l_new_relship_rec.attribute5;
3683: END IF;
3684: ELSE
3685: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;

Line 3685: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;

3681: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;
3682: l_rel_hist_csr.new_attribute5 := l_new_relship_rec.attribute5;
3683: END IF;
3684: ELSE
3685: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;
3686: l_rel_hist_csr.new_attribute5 := l_new_relship_rec.attribute5;
3687: END IF;
3688: --
3689: IF ( l_rel_hist_csr.old_attribute6 IS NULL

Line 3692: OR ( l_new_relship_rec.attribute6 = fnd_api.g_miss_char ) THEN

3688: --
3689: IF ( l_rel_hist_csr.old_attribute6 IS NULL
3690: AND l_rel_hist_csr.new_attribute6 IS NULL ) THEN
3691: IF ( l_new_relship_rec.attribute6 = l_old_relship_rec.attribute6 )
3692: OR ( l_new_relship_rec.attribute6 = fnd_api.g_miss_char ) THEN
3693: l_rel_hist_csr.old_attribute6 := NULL;
3694: l_rel_hist_csr.new_attribute6 := NULL;
3695: ELSE
3696: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;

Line 3696: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;

3692: OR ( l_new_relship_rec.attribute6 = fnd_api.g_miss_char ) THEN
3693: l_rel_hist_csr.old_attribute6 := NULL;
3694: l_rel_hist_csr.new_attribute6 := NULL;
3695: ELSE
3696: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;
3697: l_rel_hist_csr.new_attribute6 := l_new_relship_rec.attribute6;
3698: END IF;
3699: ELSE
3700: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;

Line 3700: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;

3696: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;
3697: l_rel_hist_csr.new_attribute6 := l_new_relship_rec.attribute6;
3698: END IF;
3699: ELSE
3700: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;
3701: l_rel_hist_csr.new_attribute6 := l_new_relship_rec.attribute6;
3702: END IF;
3703: --
3704: IF ( l_rel_hist_csr.old_attribute7 IS NULL

Line 3707: OR ( l_new_relship_rec.attribute7 = fnd_api.g_miss_char ) THEN

3703: --
3704: IF ( l_rel_hist_csr.old_attribute7 IS NULL
3705: AND l_rel_hist_csr.new_attribute7 IS NULL ) THEN
3706: IF ( l_new_relship_rec.attribute7 = l_old_relship_rec.attribute7 )
3707: OR ( l_new_relship_rec.attribute7 = fnd_api.g_miss_char ) THEN
3708: l_rel_hist_csr.old_attribute7 := NULL;
3709: l_rel_hist_csr.new_attribute7 := NULL;
3710: ELSE
3711: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;

Line 3711: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;

3707: OR ( l_new_relship_rec.attribute7 = fnd_api.g_miss_char ) THEN
3708: l_rel_hist_csr.old_attribute7 := NULL;
3709: l_rel_hist_csr.new_attribute7 := NULL;
3710: ELSE
3711: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;
3712: l_rel_hist_csr.new_attribute7 := l_new_relship_rec.attribute7;
3713: END IF;
3714: ELSE
3715: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;

Line 3715: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;

3711: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;
3712: l_rel_hist_csr.new_attribute7 := l_new_relship_rec.attribute7;
3713: END IF;
3714: ELSE
3715: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;
3716: l_rel_hist_csr.new_attribute7 := l_new_relship_rec.attribute7;
3717: END IF;
3718: --
3719: IF ( l_rel_hist_csr.old_attribute8 IS NULL

Line 3722: OR ( l_new_relship_rec.attribute8 = fnd_api.g_miss_char ) THEN

3718: --
3719: IF ( l_rel_hist_csr.old_attribute8 IS NULL
3720: AND l_rel_hist_csr.new_attribute8 IS NULL ) THEN
3721: IF ( l_new_relship_rec.attribute8 = l_old_relship_rec.attribute8 )
3722: OR ( l_new_relship_rec.attribute8 = fnd_api.g_miss_char ) THEN
3723: l_rel_hist_csr.old_attribute8 := NULL;
3724: l_rel_hist_csr.new_attribute8 := NULL;
3725: ELSE
3726: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;

Line 3726: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;

3722: OR ( l_new_relship_rec.attribute8 = fnd_api.g_miss_char ) THEN
3723: l_rel_hist_csr.old_attribute8 := NULL;
3724: l_rel_hist_csr.new_attribute8 := NULL;
3725: ELSE
3726: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;
3727: l_rel_hist_csr.new_attribute8 := l_new_relship_rec.attribute8;
3728: END IF;
3729: ELSE
3730: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;

Line 3730: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;

3726: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;
3727: l_rel_hist_csr.new_attribute8 := l_new_relship_rec.attribute8;
3728: END IF;
3729: ELSE
3730: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;
3731: l_rel_hist_csr.new_attribute8 := l_new_relship_rec.attribute8;
3732: END IF;
3733: --
3734: IF ( l_rel_hist_csr.old_attribute9 IS NULL

Line 3737: OR ( l_new_relship_rec.attribute9 = fnd_api.g_miss_char ) THEN

3733: --
3734: IF ( l_rel_hist_csr.old_attribute9 IS NULL
3735: AND l_rel_hist_csr.new_attribute9 IS NULL ) THEN
3736: IF ( l_new_relship_rec.attribute9 = l_old_relship_rec.attribute9 )
3737: OR ( l_new_relship_rec.attribute9 = fnd_api.g_miss_char ) THEN
3738: l_rel_hist_csr.old_attribute9 := NULL;
3739: l_rel_hist_csr.new_attribute9 := NULL;
3740: ELSE
3741: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;

Line 3741: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;

3737: OR ( l_new_relship_rec.attribute9 = fnd_api.g_miss_char ) THEN
3738: l_rel_hist_csr.old_attribute9 := NULL;
3739: l_rel_hist_csr.new_attribute9 := NULL;
3740: ELSE
3741: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;
3742: l_rel_hist_csr.new_attribute9 := l_new_relship_rec.attribute9;
3743: END IF;
3744: ELSE
3745: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;

Line 3745: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;

3741: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;
3742: l_rel_hist_csr.new_attribute9 := l_new_relship_rec.attribute9;
3743: END IF;
3744: ELSE
3745: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;
3746: l_rel_hist_csr.new_attribute9 := l_new_relship_rec.attribute9;
3747: END IF;
3748: --
3749: IF ( l_rel_hist_csr.old_attribute10 IS NULL

Line 3752: OR ( l_new_relship_rec.attribute10 = fnd_api.g_miss_char ) THEN

3748: --
3749: IF ( l_rel_hist_csr.old_attribute10 IS NULL
3750: AND l_rel_hist_csr.new_attribute10 IS NULL ) THEN
3751: IF ( l_new_relship_rec.attribute10 = l_old_relship_rec.attribute10 )
3752: OR ( l_new_relship_rec.attribute10 = fnd_api.g_miss_char ) THEN
3753: l_rel_hist_csr.old_attribute10 := NULL;
3754: l_rel_hist_csr.new_attribute10 := NULL;
3755: ELSE
3756: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;

Line 3756: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;

3752: OR ( l_new_relship_rec.attribute10 = fnd_api.g_miss_char ) THEN
3753: l_rel_hist_csr.old_attribute10 := NULL;
3754: l_rel_hist_csr.new_attribute10 := NULL;
3755: ELSE
3756: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;
3757: l_rel_hist_csr.new_attribute10 := l_new_relship_rec.attribute10;
3758: END IF;
3759: ELSE
3760: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;

Line 3760: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;

3756: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;
3757: l_rel_hist_csr.new_attribute10 := l_new_relship_rec.attribute10;
3758: END IF;
3759: ELSE
3760: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;
3761: l_rel_hist_csr.new_attribute10 := l_new_relship_rec.attribute10;
3762: END IF;
3763: --
3764: IF ( l_rel_hist_csr.old_attribute11 IS NULL

Line 3767: OR ( l_new_relship_rec.attribute11 = fnd_api.g_miss_char ) THEN

3763: --
3764: IF ( l_rel_hist_csr.old_attribute11 IS NULL
3765: AND l_rel_hist_csr.new_attribute11 IS NULL ) THEN
3766: IF ( l_new_relship_rec.attribute11 = l_old_relship_rec.attribute11 )
3767: OR ( l_new_relship_rec.attribute11 = fnd_api.g_miss_char ) THEN
3768: l_rel_hist_csr.old_attribute11 := NULL;
3769: l_rel_hist_csr.new_attribute11 := NULL;
3770: ELSE
3771: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;

Line 3771: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;

3767: OR ( l_new_relship_rec.attribute11 = fnd_api.g_miss_char ) THEN
3768: l_rel_hist_csr.old_attribute11 := NULL;
3769: l_rel_hist_csr.new_attribute11 := NULL;
3770: ELSE
3771: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;
3772: l_rel_hist_csr.new_attribute11 := l_new_relship_rec.attribute11;
3773: END IF;
3774: ELSE
3775: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;

Line 3775: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;

3771: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;
3772: l_rel_hist_csr.new_attribute11 := l_new_relship_rec.attribute11;
3773: END IF;
3774: ELSE
3775: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;
3776: l_rel_hist_csr.new_attribute11 := l_new_relship_rec.attribute11;
3777: END IF;
3778: --
3779: IF ( l_rel_hist_csr.old_attribute12 IS NULL

Line 3782: OR ( l_new_relship_rec.attribute12 = fnd_api.g_miss_char ) THEN

3778: --
3779: IF ( l_rel_hist_csr.old_attribute12 IS NULL
3780: AND l_rel_hist_csr.new_attribute12 IS NULL ) THEN
3781: IF ( l_new_relship_rec.attribute12 = l_old_relship_rec.attribute12 )
3782: OR ( l_new_relship_rec.attribute12 = fnd_api.g_miss_char ) THEN
3783: l_rel_hist_csr.old_attribute12 := NULL;
3784: l_rel_hist_csr.new_attribute12 := NULL;
3785: ELSE
3786: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;

Line 3786: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;

3782: OR ( l_new_relship_rec.attribute12 = fnd_api.g_miss_char ) THEN
3783: l_rel_hist_csr.old_attribute12 := NULL;
3784: l_rel_hist_csr.new_attribute12 := NULL;
3785: ELSE
3786: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;
3787: l_rel_hist_csr.new_attribute12 := l_new_relship_rec.attribute12;
3788: END IF;
3789: ELSE
3790: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;

Line 3790: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;

3786: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;
3787: l_rel_hist_csr.new_attribute12 := l_new_relship_rec.attribute12;
3788: END IF;
3789: ELSE
3790: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;
3791: l_rel_hist_csr.new_attribute12 := l_new_relship_rec.attribute12;
3792: END IF;
3793: --
3794: IF ( l_rel_hist_csr.old_attribute13 IS NULL

Line 3797: OR ( l_new_relship_rec.attribute13 = fnd_api.g_miss_char ) THEN

3793: --
3794: IF ( l_rel_hist_csr.old_attribute13 IS NULL
3795: AND l_rel_hist_csr.new_attribute13 IS NULL ) THEN
3796: IF ( l_new_relship_rec.attribute13 = l_old_relship_rec.attribute13 )
3797: OR ( l_new_relship_rec.attribute13 = fnd_api.g_miss_char ) THEN
3798: l_rel_hist_csr.old_attribute13 := NULL;
3799: l_rel_hist_csr.new_attribute13 := NULL;
3800: ELSE
3801: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;

Line 3801: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;

3797: OR ( l_new_relship_rec.attribute13 = fnd_api.g_miss_char ) THEN
3798: l_rel_hist_csr.old_attribute13 := NULL;
3799: l_rel_hist_csr.new_attribute13 := NULL;
3800: ELSE
3801: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;
3802: l_rel_hist_csr.new_attribute13 := l_new_relship_rec.attribute13;
3803: END IF;
3804: ELSE
3805: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;

Line 3805: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;

3801: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;
3802: l_rel_hist_csr.new_attribute13 := l_new_relship_rec.attribute13;
3803: END IF;
3804: ELSE
3805: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;
3806: l_rel_hist_csr.new_attribute13 := l_new_relship_rec.attribute13;
3807: END IF;
3808: --
3809: IF ( l_rel_hist_csr.old_attribute14 IS NULL

Line 3812: OR ( l_new_relship_rec.attribute14 = fnd_api.g_miss_char ) THEN

3808: --
3809: IF ( l_rel_hist_csr.old_attribute14 IS NULL
3810: AND l_rel_hist_csr.new_attribute14 IS NULL ) THEN
3811: IF ( l_new_relship_rec.attribute14 = l_old_relship_rec.attribute14 )
3812: OR ( l_new_relship_rec.attribute14 = fnd_api.g_miss_char ) THEN
3813: l_rel_hist_csr.old_attribute14 := NULL;
3814: l_rel_hist_csr.new_attribute14 := NULL;
3815: ELSE
3816: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;

Line 3816: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;

3812: OR ( l_new_relship_rec.attribute14 = fnd_api.g_miss_char ) THEN
3813: l_rel_hist_csr.old_attribute14 := NULL;
3814: l_rel_hist_csr.new_attribute14 := NULL;
3815: ELSE
3816: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;
3817: l_rel_hist_csr.new_attribute14 := l_new_relship_rec.attribute14;
3818: END IF;
3819: ELSE
3820: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;

Line 3820: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;

3816: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;
3817: l_rel_hist_csr.new_attribute14 := l_new_relship_rec.attribute14;
3818: END IF;
3819: ELSE
3820: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;
3821: l_rel_hist_csr.new_attribute14 := l_new_relship_rec.attribute14;
3822: END IF;
3823: --
3824: IF ( l_rel_hist_csr.old_attribute15 IS NULL

Line 3827: OR ( l_new_relship_rec.attribute15 = fnd_api.g_miss_char ) THEN

3823: --
3824: IF ( l_rel_hist_csr.old_attribute15 IS NULL
3825: AND l_rel_hist_csr.new_attribute15 IS NULL ) THEN
3826: IF ( l_new_relship_rec.attribute15 = l_old_relship_rec.attribute15 )
3827: OR ( l_new_relship_rec.attribute15 = fnd_api.g_miss_char ) THEN
3828: l_rel_hist_csr.old_attribute15 := NULL;
3829: l_rel_hist_csr.new_attribute15 := NULL;
3830: ELSE
3831: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;

Line 3831: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;

3827: OR ( l_new_relship_rec.attribute15 = fnd_api.g_miss_char ) THEN
3828: l_rel_hist_csr.old_attribute15 := NULL;
3829: l_rel_hist_csr.new_attribute15 := NULL;
3830: ELSE
3831: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;
3832: l_rel_hist_csr.new_attribute15 := l_new_relship_rec.attribute15;
3833: END IF;
3834: ELSE
3835: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;

Line 3835: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;

3831: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;
3832: l_rel_hist_csr.new_attribute15 := l_new_relship_rec.attribute15;
3833: END IF;
3834: ELSE
3835: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;
3836: l_rel_hist_csr.new_attribute15 := l_new_relship_rec.attribute15;
3837: END IF;
3838: --
3839:

Line 3842: p_relationship_id => fnd_api.g_miss_num ,

3838: --
3839:
3840: csi_ii_relationships_h_pkg.update_row(
3841: p_relationship_history_id => l_rel_hist_id ,
3842: p_relationship_id => fnd_api.g_miss_num ,
3843: p_transaction_id => fnd_api.g_miss_num ,
3844: p_old_subject_id => l_rel_hist_csr.old_subject_id ,
3845: p_new_subject_id => l_rel_hist_csr.new_subject_id ,
3846: p_old_position_reference => l_rel_hist_csr.old_position_reference,

Line 3843: p_transaction_id => fnd_api.g_miss_num ,

3839:
3840: csi_ii_relationships_h_pkg.update_row(
3841: p_relationship_history_id => l_rel_hist_id ,
3842: p_relationship_id => fnd_api.g_miss_num ,
3843: p_transaction_id => fnd_api.g_miss_num ,
3844: p_old_subject_id => l_rel_hist_csr.old_subject_id ,
3845: p_new_subject_id => l_rel_hist_csr.new_subject_id ,
3846: p_old_position_reference => l_rel_hist_csr.old_position_reference,
3847: p_new_position_reference => l_rel_hist_csr.new_position_reference,

Line 3886: p_full_dump_flag => fnd_api.g_miss_char ,

3882: p_old_attribute14 => l_rel_hist_csr.old_attribute14 ,
3883: p_new_attribute14 => l_rel_hist_csr.new_attribute14 ,
3884: p_old_attribute15 => l_rel_hist_csr.old_attribute15 ,
3885: p_new_attribute15 => l_rel_hist_csr.new_attribute15 ,
3886: p_full_dump_flag => fnd_api.g_miss_char ,
3887: p_created_by => fnd_api.g_miss_num ,
3888: p_creation_date => fnd_api.g_miss_date ,
3889: p_last_updated_by => fnd_global.user_id ,
3890: p_last_update_date => SYSDATE ,

Line 3887: p_created_by => fnd_api.g_miss_num ,

3883: p_new_attribute14 => l_rel_hist_csr.new_attribute14 ,
3884: p_old_attribute15 => l_rel_hist_csr.old_attribute15 ,
3885: p_new_attribute15 => l_rel_hist_csr.new_attribute15 ,
3886: p_full_dump_flag => fnd_api.g_miss_char ,
3887: p_created_by => fnd_api.g_miss_num ,
3888: p_creation_date => fnd_api.g_miss_date ,
3889: p_last_updated_by => fnd_global.user_id ,
3890: p_last_update_date => SYSDATE ,
3891: p_last_update_login => fnd_global.conc_login_id ,

Line 3888: p_creation_date => fnd_api.g_miss_date ,

3884: p_old_attribute15 => l_rel_hist_csr.old_attribute15 ,
3885: p_new_attribute15 => l_rel_hist_csr.new_attribute15 ,
3886: p_full_dump_flag => fnd_api.g_miss_char ,
3887: p_created_by => fnd_api.g_miss_num ,
3888: p_creation_date => fnd_api.g_miss_date ,
3889: p_last_updated_by => fnd_global.user_id ,
3890: p_last_update_date => SYSDATE ,
3891: p_last_update_login => fnd_global.conc_login_id ,
3892: p_object_version_number => fnd_api.g_miss_num );

Line 3892: p_object_version_number => fnd_api.g_miss_num );

3888: p_creation_date => fnd_api.g_miss_date ,
3889: p_last_updated_by => fnd_global.user_id ,
3890: p_last_update_date => SYSDATE ,
3891: p_last_update_login => fnd_global.conc_login_id ,
3892: p_object_version_number => fnd_api.g_miss_num );
3893: END IF;
3894:
3895: EXCEPTION
3896: WHEN NO_DATA_FOUND THEN

Line 3955: IF (l_new_relship_rec.subject_id = fnd_api.g_miss_num) OR

3951: p_object_version_number => 1);
3952:
3953: ELSE
3954:
3955: IF (l_new_relship_rec.subject_id = fnd_api.g_miss_num) OR
3956: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) = NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN
3957: l_relship_hist_rec.old_subject_id := NULL;
3958: l_relship_hist_rec.new_subject_id := NULL;
3959: ELSIF

Line 3956: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) = NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN

3952:
3953: ELSE
3954:
3955: IF (l_new_relship_rec.subject_id = fnd_api.g_miss_num) OR
3956: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) = NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN
3957: l_relship_hist_rec.old_subject_id := NULL;
3958: l_relship_hist_rec.new_subject_id := NULL;
3959: ELSIF
3960: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) <> NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN

Line 3960: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) <> NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN

3956: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) = NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN
3957: l_relship_hist_rec.old_subject_id := NULL;
3958: l_relship_hist_rec.new_subject_id := NULL;
3959: ELSIF
3960: NVL(l_old_relship_rec.subject_id,fnd_api.g_miss_num) <> NVL(l_new_relship_rec.subject_id,fnd_api.g_miss_num) THEN
3961: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id ;
3962: l_relship_hist_rec.new_subject_id := l_new_relship_rec.subject_id ;
3963: END IF;
3964: --

Line 3965: IF (l_new_relship_rec.position_reference = fnd_api.g_miss_char) OR

3961: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id ;
3962: l_relship_hist_rec.new_subject_id := l_new_relship_rec.subject_id ;
3963: END IF;
3964: --
3965: IF (l_new_relship_rec.position_reference = fnd_api.g_miss_char) OR
3966: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) = NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN
3967: l_relship_hist_rec.old_position_reference := NULL;
3968: l_relship_hist_rec.new_position_reference := NULL;
3969: ELSIF

Line 3966: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) = NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN

3962: l_relship_hist_rec.new_subject_id := l_new_relship_rec.subject_id ;
3963: END IF;
3964: --
3965: IF (l_new_relship_rec.position_reference = fnd_api.g_miss_char) OR
3966: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) = NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN
3967: l_relship_hist_rec.old_position_reference := NULL;
3968: l_relship_hist_rec.new_position_reference := NULL;
3969: ELSIF
3970: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN

Line 3970: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN

3966: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) = NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN
3967: l_relship_hist_rec.old_position_reference := NULL;
3968: l_relship_hist_rec.new_position_reference := NULL;
3969: ELSIF
3970: NVL(l_old_relship_rec.position_reference,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.position_reference,fnd_api.g_miss_char) THEN
3971: l_relship_hist_rec.old_position_reference := l_old_relship_rec.position_reference ;
3972: l_relship_hist_rec.new_position_reference := l_new_relship_rec.position_reference ;
3973: END IF;
3974: --

Line 3975: IF (l_new_relship_rec.active_start_date = fnd_api.g_miss_date) OR

3971: l_relship_hist_rec.old_position_reference := l_old_relship_rec.position_reference ;
3972: l_relship_hist_rec.new_position_reference := l_new_relship_rec.position_reference ;
3973: END IF;
3974: --
3975: IF (l_new_relship_rec.active_start_date = fnd_api.g_miss_date) OR
3976: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN
3977: l_relship_hist_rec.old_active_start_date := NULL;
3978: l_relship_hist_rec.new_active_start_date := NULL;
3979: ELSIF

Line 3976: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN

3972: l_relship_hist_rec.new_position_reference := l_new_relship_rec.position_reference ;
3973: END IF;
3974: --
3975: IF (l_new_relship_rec.active_start_date = fnd_api.g_miss_date) OR
3976: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN
3977: l_relship_hist_rec.old_active_start_date := NULL;
3978: l_relship_hist_rec.new_active_start_date := NULL;
3979: ELSIF
3980: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) <> NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN

Line 3980: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) <> NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN

3976: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN
3977: l_relship_hist_rec.old_active_start_date := NULL;
3978: l_relship_hist_rec.new_active_start_date := NULL;
3979: ELSIF
3980: NVL(l_old_relship_rec.active_start_date,fnd_api.g_miss_date) <> NVL(l_new_relship_rec.active_start_date,fnd_api.g_miss_date) THEN
3981: l_relship_hist_rec.old_active_start_date := l_old_relship_rec.active_start_date ;
3982: l_relship_hist_rec.new_active_start_date := l_new_relship_rec.active_start_date ;
3983: END IF;
3984: --

Line 3985: IF (l_new_relship_rec.active_end_date = fnd_api.g_miss_date) OR

3981: l_relship_hist_rec.old_active_start_date := l_old_relship_rec.active_start_date ;
3982: l_relship_hist_rec.new_active_start_date := l_new_relship_rec.active_start_date ;
3983: END IF;
3984: --
3985: IF (l_new_relship_rec.active_end_date = fnd_api.g_miss_date) OR
3986: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN
3987: l_relship_hist_rec.old_active_end_date := NULL;
3988: l_relship_hist_rec.new_active_end_date := NULL;
3989: ELSIF

Line 3986: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN

3982: l_relship_hist_rec.new_active_start_date := l_new_relship_rec.active_start_date ;
3983: END IF;
3984: --
3985: IF (l_new_relship_rec.active_end_date = fnd_api.g_miss_date) OR
3986: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN
3987: l_relship_hist_rec.old_active_end_date := NULL;
3988: l_relship_hist_rec.new_active_end_date := NULL;
3989: ELSIF
3990: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) <> NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN

Line 3990: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) <> NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN

3986: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) = NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN
3987: l_relship_hist_rec.old_active_end_date := NULL;
3988: l_relship_hist_rec.new_active_end_date := NULL;
3989: ELSIF
3990: NVL(l_old_relship_rec.active_end_date,fnd_api.g_miss_date) <> NVL(l_new_relship_rec.active_end_date,fnd_api.g_miss_date) THEN
3991: l_relship_hist_rec.old_active_end_date := l_old_relship_rec.active_end_date ;
3992: l_relship_hist_rec.new_active_end_date := l_new_relship_rec.active_end_date ;
3993: END IF;
3994: --

Line 3995: IF (l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char) OR

3991: l_relship_hist_rec.old_active_end_date := l_old_relship_rec.active_end_date ;
3992: l_relship_hist_rec.new_active_end_date := l_new_relship_rec.active_end_date ;
3993: END IF;
3994: --
3995: IF (l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char) OR
3996: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) = NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN
3997: l_relship_hist_rec.old_mandatory_flag := NULL;
3998: l_relship_hist_rec.new_mandatory_flag := NULL;
3999: ELSIF

Line 3996: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) = NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN

3992: l_relship_hist_rec.new_active_end_date := l_new_relship_rec.active_end_date ;
3993: END IF;
3994: --
3995: IF (l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char) OR
3996: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) = NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN
3997: l_relship_hist_rec.old_mandatory_flag := NULL;
3998: l_relship_hist_rec.new_mandatory_flag := NULL;
3999: ELSIF
4000: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN

Line 4000: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN

3996: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) = NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN
3997: l_relship_hist_rec.old_mandatory_flag := NULL;
3998: l_relship_hist_rec.new_mandatory_flag := NULL;
3999: ELSIF
4000: NVL(l_old_relship_rec.mandatory_flag,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.mandatory_flag,fnd_api.g_miss_char) THEN
4001: l_relship_hist_rec.old_mandatory_flag := l_old_relship_rec.mandatory_flag ;
4002: l_relship_hist_rec.new_mandatory_flag := l_new_relship_rec.mandatory_flag ;
4003: END IF;
4004: --

Line 4005: IF (l_new_relship_rec.context = fnd_api.g_miss_char) OR

4001: l_relship_hist_rec.old_mandatory_flag := l_old_relship_rec.mandatory_flag ;
4002: l_relship_hist_rec.new_mandatory_flag := l_new_relship_rec.mandatory_flag ;
4003: END IF;
4004: --
4005: IF (l_new_relship_rec.context = fnd_api.g_miss_char) OR
4006: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) = NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN
4007: l_relship_hist_rec.old_context := NULL;
4008: l_relship_hist_rec.new_context := NULL;
4009: ELSIF

Line 4006: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) = NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN

4002: l_relship_hist_rec.new_mandatory_flag := l_new_relship_rec.mandatory_flag ;
4003: END IF;
4004: --
4005: IF (l_new_relship_rec.context = fnd_api.g_miss_char) OR
4006: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) = NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN
4007: l_relship_hist_rec.old_context := NULL;
4008: l_relship_hist_rec.new_context := NULL;
4009: ELSIF
4010: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN

Line 4010: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN

4006: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) = NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN
4007: l_relship_hist_rec.old_context := NULL;
4008: l_relship_hist_rec.new_context := NULL;
4009: ELSIF
4010: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN
4011: l_relship_hist_rec.old_context := l_old_relship_rec.context ;
4012: l_relship_hist_rec.new_context := l_new_relship_rec.context ;
4013: END IF;
4014: --

Line 4015: IF (l_new_relship_rec.attribute1 = fnd_api.g_miss_char) OR

4011: l_relship_hist_rec.old_context := l_old_relship_rec.context ;
4012: l_relship_hist_rec.new_context := l_new_relship_rec.context ;
4013: END IF;
4014: --
4015: IF (l_new_relship_rec.attribute1 = fnd_api.g_miss_char) OR
4016: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4017: l_relship_hist_rec.old_attribute1 := NULL;
4018: l_relship_hist_rec.new_attribute1 := NULL;
4019: ELSIF

Line 4016: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN

4012: l_relship_hist_rec.new_context := l_new_relship_rec.context ;
4013: END IF;
4014: --
4015: IF (l_new_relship_rec.attribute1 = fnd_api.g_miss_char) OR
4016: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4017: l_relship_hist_rec.old_attribute1 := NULL;
4018: l_relship_hist_rec.new_attribute1 := NULL;
4019: ELSIF
4020: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN

Line 4020: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN

4016: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4017: l_relship_hist_rec.old_attribute1 := NULL;
4018: l_relship_hist_rec.new_attribute1 := NULL;
4019: ELSIF
4020: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4021: l_relship_hist_rec.old_attribute1 := l_old_relship_rec.attribute1 ;
4022: l_relship_hist_rec.new_attribute1 := l_new_relship_rec.attribute1 ;
4023: END IF;
4024: --

Line 4025: IF (l_new_relship_rec.attribute2 = fnd_api.g_miss_char) OR

4021: l_relship_hist_rec.old_attribute1 := l_old_relship_rec.attribute1 ;
4022: l_relship_hist_rec.new_attribute1 := l_new_relship_rec.attribute1 ;
4023: END IF;
4024: --
4025: IF (l_new_relship_rec.attribute2 = fnd_api.g_miss_char) OR
4026: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4027: l_relship_hist_rec.old_attribute2 := NULL;
4028: l_relship_hist_rec.new_attribute2 := NULL;
4029: ELSIF

Line 4026: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN

4022: l_relship_hist_rec.new_attribute1 := l_new_relship_rec.attribute1 ;
4023: END IF;
4024: --
4025: IF (l_new_relship_rec.attribute2 = fnd_api.g_miss_char) OR
4026: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4027: l_relship_hist_rec.old_attribute2 := NULL;
4028: l_relship_hist_rec.new_attribute2 := NULL;
4029: ELSIF
4030: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN

Line 4030: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN

4026: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4027: l_relship_hist_rec.old_attribute2 := NULL;
4028: l_relship_hist_rec.new_attribute2 := NULL;
4029: ELSIF
4030: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4031: l_relship_hist_rec.old_attribute2 := l_old_relship_rec.attribute2 ;
4032: l_relship_hist_rec.new_attribute2 := l_new_relship_rec.attribute2 ;
4033: END IF;
4034: --

Line 4035: IF (l_new_relship_rec.attribute3 = fnd_api.g_miss_char) OR

4031: l_relship_hist_rec.old_attribute2 := l_old_relship_rec.attribute2 ;
4032: l_relship_hist_rec.new_attribute2 := l_new_relship_rec.attribute2 ;
4033: END IF;
4034: --
4035: IF (l_new_relship_rec.attribute3 = fnd_api.g_miss_char) OR
4036: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4037: l_relship_hist_rec.old_attribute3 := NULL;
4038: l_relship_hist_rec.new_attribute3 := NULL;
4039: ELSIF

Line 4036: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN

4032: l_relship_hist_rec.new_attribute2 := l_new_relship_rec.attribute2 ;
4033: END IF;
4034: --
4035: IF (l_new_relship_rec.attribute3 = fnd_api.g_miss_char) OR
4036: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4037: l_relship_hist_rec.old_attribute3 := NULL;
4038: l_relship_hist_rec.new_attribute3 := NULL;
4039: ELSIF
4040: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN

Line 4040: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN

4036: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4037: l_relship_hist_rec.old_attribute3 := NULL;
4038: l_relship_hist_rec.new_attribute3 := NULL;
4039: ELSIF
4040: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4041: l_relship_hist_rec.old_attribute3 := l_old_relship_rec.attribute3 ;
4042: l_relship_hist_rec.new_attribute3 := l_new_relship_rec.attribute3 ;
4043: END IF;
4044: --

Line 4045: IF (l_new_relship_rec.attribute4 = fnd_api.g_miss_char) OR

4041: l_relship_hist_rec.old_attribute3 := l_old_relship_rec.attribute3 ;
4042: l_relship_hist_rec.new_attribute3 := l_new_relship_rec.attribute3 ;
4043: END IF;
4044: --
4045: IF (l_new_relship_rec.attribute4 = fnd_api.g_miss_char) OR
4046: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4047: l_relship_hist_rec.old_attribute4 := NULL;
4048: l_relship_hist_rec.new_attribute4 := NULL;
4049: ELSIF

Line 4046: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN

4042: l_relship_hist_rec.new_attribute3 := l_new_relship_rec.attribute3 ;
4043: END IF;
4044: --
4045: IF (l_new_relship_rec.attribute4 = fnd_api.g_miss_char) OR
4046: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4047: l_relship_hist_rec.old_attribute4 := NULL;
4048: l_relship_hist_rec.new_attribute4 := NULL;
4049: ELSIF
4050: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN

Line 4050: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN

4046: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4047: l_relship_hist_rec.old_attribute4 := NULL;
4048: l_relship_hist_rec.new_attribute4 := NULL;
4049: ELSIF
4050: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4051: l_relship_hist_rec.old_attribute4 := l_old_relship_rec.attribute4 ;
4052: l_relship_hist_rec.new_attribute4 := l_new_relship_rec.attribute4 ;
4053: END IF;
4054: --

Line 4055: IF (l_new_relship_rec.attribute5 = fnd_api.g_miss_char) OR

4051: l_relship_hist_rec.old_attribute4 := l_old_relship_rec.attribute4 ;
4052: l_relship_hist_rec.new_attribute4 := l_new_relship_rec.attribute4 ;
4053: END IF;
4054: --
4055: IF (l_new_relship_rec.attribute5 = fnd_api.g_miss_char) OR
4056: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4057: l_relship_hist_rec.old_attribute5 := NULL;
4058: l_relship_hist_rec.new_attribute5 := NULL;
4059: ELSIF

Line 4056: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN

4052: l_relship_hist_rec.new_attribute4 := l_new_relship_rec.attribute4 ;
4053: END IF;
4054: --
4055: IF (l_new_relship_rec.attribute5 = fnd_api.g_miss_char) OR
4056: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4057: l_relship_hist_rec.old_attribute5 := NULL;
4058: l_relship_hist_rec.new_attribute5 := NULL;
4059: ELSIF
4060: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN

Line 4060: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN

4056: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4057: l_relship_hist_rec.old_attribute5 := NULL;
4058: l_relship_hist_rec.new_attribute5 := NULL;
4059: ELSIF
4060: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4061: l_relship_hist_rec.old_attribute5 := l_old_relship_rec.attribute5 ;
4062: l_relship_hist_rec.new_attribute5 := l_new_relship_rec.attribute5 ;
4063: END IF;
4064: --

Line 4065: IF (l_new_relship_rec.attribute6 = fnd_api.g_miss_char) OR

4061: l_relship_hist_rec.old_attribute5 := l_old_relship_rec.attribute5 ;
4062: l_relship_hist_rec.new_attribute5 := l_new_relship_rec.attribute5 ;
4063: END IF;
4064: --
4065: IF (l_new_relship_rec.attribute6 = fnd_api.g_miss_char) OR
4066: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4067: l_relship_hist_rec.old_attribute6 := NULL;
4068: l_relship_hist_rec.new_attribute6 := NULL;
4069: ELSIF

Line 4066: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN

4062: l_relship_hist_rec.new_attribute5 := l_new_relship_rec.attribute5 ;
4063: END IF;
4064: --
4065: IF (l_new_relship_rec.attribute6 = fnd_api.g_miss_char) OR
4066: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4067: l_relship_hist_rec.old_attribute6 := NULL;
4068: l_relship_hist_rec.new_attribute6 := NULL;
4069: ELSIF
4070: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN

Line 4070: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN

4066: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4067: l_relship_hist_rec.old_attribute6 := NULL;
4068: l_relship_hist_rec.new_attribute6 := NULL;
4069: ELSIF
4070: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4071: l_relship_hist_rec.old_attribute6 := l_old_relship_rec.attribute6 ;
4072: l_relship_hist_rec.new_attribute6 := l_new_relship_rec.attribute6 ;
4073: END IF;
4074: --

Line 4075: IF (l_new_relship_rec.attribute7 = fnd_api.g_miss_char) OR

4071: l_relship_hist_rec.old_attribute6 := l_old_relship_rec.attribute6 ;
4072: l_relship_hist_rec.new_attribute6 := l_new_relship_rec.attribute6 ;
4073: END IF;
4074: --
4075: IF (l_new_relship_rec.attribute7 = fnd_api.g_miss_char) OR
4076: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4077: l_relship_hist_rec.old_attribute7 := NULL;
4078: l_relship_hist_rec.new_attribute7 := NULL;
4079: ELSIF

Line 4076: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN

4072: l_relship_hist_rec.new_attribute6 := l_new_relship_rec.attribute6 ;
4073: END IF;
4074: --
4075: IF (l_new_relship_rec.attribute7 = fnd_api.g_miss_char) OR
4076: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4077: l_relship_hist_rec.old_attribute7 := NULL;
4078: l_relship_hist_rec.new_attribute7 := NULL;
4079: ELSIF
4080: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN

Line 4080: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN

4076: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4077: l_relship_hist_rec.old_attribute7 := NULL;
4078: l_relship_hist_rec.new_attribute7 := NULL;
4079: ELSIF
4080: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4081: l_relship_hist_rec.old_attribute7 := l_old_relship_rec.attribute7 ;
4082: l_relship_hist_rec.new_attribute7 := l_new_relship_rec.attribute7 ;
4083: END IF;
4084: --

Line 4085: IF (l_new_relship_rec.attribute8 = fnd_api.g_miss_char) OR

4081: l_relship_hist_rec.old_attribute7 := l_old_relship_rec.attribute7 ;
4082: l_relship_hist_rec.new_attribute7 := l_new_relship_rec.attribute7 ;
4083: END IF;
4084: --
4085: IF (l_new_relship_rec.attribute8 = fnd_api.g_miss_char) OR
4086: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4087: l_relship_hist_rec.old_attribute8 := NULL;
4088: l_relship_hist_rec.new_attribute8 := NULL;
4089: ELSIF

Line 4086: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN

4082: l_relship_hist_rec.new_attribute7 := l_new_relship_rec.attribute7 ;
4083: END IF;
4084: --
4085: IF (l_new_relship_rec.attribute8 = fnd_api.g_miss_char) OR
4086: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4087: l_relship_hist_rec.old_attribute8 := NULL;
4088: l_relship_hist_rec.new_attribute8 := NULL;
4089: ELSIF
4090: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN

Line 4090: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN

4086: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4087: l_relship_hist_rec.old_attribute8 := NULL;
4088: l_relship_hist_rec.new_attribute8 := NULL;
4089: ELSIF
4090: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4091: l_relship_hist_rec.old_attribute8 := l_old_relship_rec.attribute8 ;
4092: l_relship_hist_rec.new_attribute8 := l_new_relship_rec.attribute8 ;
4093: END IF;
4094: --

Line 4095: IF (l_new_relship_rec.attribute9 = fnd_api.g_miss_char) OR

4091: l_relship_hist_rec.old_attribute8 := l_old_relship_rec.attribute8 ;
4092: l_relship_hist_rec.new_attribute8 := l_new_relship_rec.attribute8 ;
4093: END IF;
4094: --
4095: IF (l_new_relship_rec.attribute9 = fnd_api.g_miss_char) OR
4096: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4097: l_relship_hist_rec.old_attribute9 := NULL;
4098: l_relship_hist_rec.new_attribute9 := NULL;
4099: ELSIF

Line 4096: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN

4092: l_relship_hist_rec.new_attribute8 := l_new_relship_rec.attribute8 ;
4093: END IF;
4094: --
4095: IF (l_new_relship_rec.attribute9 = fnd_api.g_miss_char) OR
4096: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4097: l_relship_hist_rec.old_attribute9 := NULL;
4098: l_relship_hist_rec.new_attribute9 := NULL;
4099: ELSIF
4100: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN

Line 4100: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN

4096: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4097: l_relship_hist_rec.old_attribute9 := NULL;
4098: l_relship_hist_rec.new_attribute9 := NULL;
4099: ELSIF
4100: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4101: l_relship_hist_rec.old_attribute9 := l_old_relship_rec.attribute9 ;
4102: l_relship_hist_rec.new_attribute9 := l_new_relship_rec.attribute9 ;
4103: END IF;
4104: --

Line 4105: IF (l_new_relship_rec.attribute10 = fnd_api.g_miss_char) OR

4101: l_relship_hist_rec.old_attribute9 := l_old_relship_rec.attribute9 ;
4102: l_relship_hist_rec.new_attribute9 := l_new_relship_rec.attribute9 ;
4103: END IF;
4104: --
4105: IF (l_new_relship_rec.attribute10 = fnd_api.g_miss_char) OR
4106: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4107: l_relship_hist_rec.old_attribute10 := NULL;
4108: l_relship_hist_rec.new_attribute10 := NULL;
4109: ELSIF

Line 4106: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN

4102: l_relship_hist_rec.new_attribute9 := l_new_relship_rec.attribute9 ;
4103: END IF;
4104: --
4105: IF (l_new_relship_rec.attribute10 = fnd_api.g_miss_char) OR
4106: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4107: l_relship_hist_rec.old_attribute10 := NULL;
4108: l_relship_hist_rec.new_attribute10 := NULL;
4109: ELSIF
4110: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN

Line 4110: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN

4106: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4107: l_relship_hist_rec.old_attribute10 := NULL;
4108: l_relship_hist_rec.new_attribute10 := NULL;
4109: ELSIF
4110: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4111: l_relship_hist_rec.old_attribute10 := l_old_relship_rec.attribute10 ;
4112: l_relship_hist_rec.new_attribute10 := l_new_relship_rec.attribute10 ;
4113: END IF;
4114: --

Line 4115: IF (l_new_relship_rec.attribute11 = fnd_api.g_miss_char) OR

4111: l_relship_hist_rec.old_attribute10 := l_old_relship_rec.attribute10 ;
4112: l_relship_hist_rec.new_attribute10 := l_new_relship_rec.attribute10 ;
4113: END IF;
4114: --
4115: IF (l_new_relship_rec.attribute11 = fnd_api.g_miss_char) OR
4116: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4117: l_relship_hist_rec.old_attribute11 := NULL;
4118: l_relship_hist_rec.new_attribute11 := NULL;
4119: ELSIF

Line 4116: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN

4112: l_relship_hist_rec.new_attribute10 := l_new_relship_rec.attribute10 ;
4113: END IF;
4114: --
4115: IF (l_new_relship_rec.attribute11 = fnd_api.g_miss_char) OR
4116: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4117: l_relship_hist_rec.old_attribute11 := NULL;
4118: l_relship_hist_rec.new_attribute11 := NULL;
4119: ELSIF
4120: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN

Line 4120: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN

4116: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4117: l_relship_hist_rec.old_attribute11 := NULL;
4118: l_relship_hist_rec.new_attribute11 := NULL;
4119: ELSIF
4120: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4121: l_relship_hist_rec.old_attribute11 := l_old_relship_rec.attribute11 ;
4122: l_relship_hist_rec.new_attribute11 := l_new_relship_rec.attribute11 ;
4123: END IF;
4124: --

Line 4125: IF (l_new_relship_rec.attribute12 = fnd_api.g_miss_char) OR

4121: l_relship_hist_rec.old_attribute11 := l_old_relship_rec.attribute11 ;
4122: l_relship_hist_rec.new_attribute11 := l_new_relship_rec.attribute11 ;
4123: END IF;
4124: --
4125: IF (l_new_relship_rec.attribute12 = fnd_api.g_miss_char) OR
4126: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4127: l_relship_hist_rec.old_attribute12 := NULL;
4128: l_relship_hist_rec.new_attribute12 := NULL;
4129: ELSIF

Line 4126: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN

4122: l_relship_hist_rec.new_attribute11 := l_new_relship_rec.attribute11 ;
4123: END IF;
4124: --
4125: IF (l_new_relship_rec.attribute12 = fnd_api.g_miss_char) OR
4126: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4127: l_relship_hist_rec.old_attribute12 := NULL;
4128: l_relship_hist_rec.new_attribute12 := NULL;
4129: ELSIF
4130: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN

Line 4130: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN

4126: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4127: l_relship_hist_rec.old_attribute12 := NULL;
4128: l_relship_hist_rec.new_attribute12 := NULL;
4129: ELSIF
4130: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4131: l_relship_hist_rec.old_attribute12 := l_old_relship_rec.attribute12 ;
4132: l_relship_hist_rec.new_attribute12 := l_new_relship_rec.attribute12 ;
4133: END IF;
4134: --

Line 4135: IF (l_new_relship_rec.attribute13 = fnd_api.g_miss_char) OR

4131: l_relship_hist_rec.old_attribute12 := l_old_relship_rec.attribute12 ;
4132: l_relship_hist_rec.new_attribute12 := l_new_relship_rec.attribute12 ;
4133: END IF;
4134: --
4135: IF (l_new_relship_rec.attribute13 = fnd_api.g_miss_char) OR
4136: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4137: l_relship_hist_rec.old_attribute13 := NULL;
4138: l_relship_hist_rec.new_attribute13 := NULL;
4139: ELSIF

Line 4136: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN

4132: l_relship_hist_rec.new_attribute12 := l_new_relship_rec.attribute12 ;
4133: END IF;
4134: --
4135: IF (l_new_relship_rec.attribute13 = fnd_api.g_miss_char) OR
4136: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4137: l_relship_hist_rec.old_attribute13 := NULL;
4138: l_relship_hist_rec.new_attribute13 := NULL;
4139: ELSIF
4140: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN

Line 4140: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN

4136: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4137: l_relship_hist_rec.old_attribute13 := NULL;
4138: l_relship_hist_rec.new_attribute13 := NULL;
4139: ELSIF
4140: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4141: l_relship_hist_rec.old_attribute13 := l_old_relship_rec.attribute13 ;
4142: l_relship_hist_rec.new_attribute13 := l_new_relship_rec.attribute13 ;
4143: END IF;
4144: --

Line 4145: IF (l_new_relship_rec.attribute14 = fnd_api.g_miss_char) OR

4141: l_relship_hist_rec.old_attribute13 := l_old_relship_rec.attribute13 ;
4142: l_relship_hist_rec.new_attribute13 := l_new_relship_rec.attribute13 ;
4143: END IF;
4144: --
4145: IF (l_new_relship_rec.attribute14 = fnd_api.g_miss_char) OR
4146: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4147: l_relship_hist_rec.old_attribute14 := NULL;
4148: l_relship_hist_rec.new_attribute14 := NULL;
4149: ELSIF

Line 4146: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN

4142: l_relship_hist_rec.new_attribute13 := l_new_relship_rec.attribute13 ;
4143: END IF;
4144: --
4145: IF (l_new_relship_rec.attribute14 = fnd_api.g_miss_char) OR
4146: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4147: l_relship_hist_rec.old_attribute14 := NULL;
4148: l_relship_hist_rec.new_attribute14 := NULL;
4149: ELSIF
4150: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN

Line 4150: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN

4146: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4147: l_relship_hist_rec.old_attribute14 := NULL;
4148: l_relship_hist_rec.new_attribute14 := NULL;
4149: ELSIF
4150: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4151: l_relship_hist_rec.old_attribute14 := l_old_relship_rec.attribute14 ;
4152: l_relship_hist_rec.new_attribute14 := l_new_relship_rec.attribute14 ;
4153: END IF;
4154: --

Line 4155: IF (l_new_relship_rec.attribute15 = fnd_api.g_miss_char) OR

4151: l_relship_hist_rec.old_attribute14 := l_old_relship_rec.attribute14 ;
4152: l_relship_hist_rec.new_attribute14 := l_new_relship_rec.attribute14 ;
4153: END IF;
4154: --
4155: IF (l_new_relship_rec.attribute15 = fnd_api.g_miss_char) OR
4156: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4157: l_relship_hist_rec.old_attribute15 := NULL;
4158: l_relship_hist_rec.new_attribute15 := NULL;
4159: ELSIF

Line 4156: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN

4152: l_relship_hist_rec.new_attribute14 := l_new_relship_rec.attribute14 ;
4153: END IF;
4154: --
4155: IF (l_new_relship_rec.attribute15 = fnd_api.g_miss_char) OR
4156: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4157: l_relship_hist_rec.old_attribute15 := NULL;
4158: l_relship_hist_rec.new_attribute15 := NULL;
4159: ELSIF
4160: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN

Line 4160: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN

4156: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4157: l_relship_hist_rec.old_attribute15 := NULL;
4158: l_relship_hist_rec.new_attribute15 := NULL;
4159: ELSIF
4160: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4161: l_relship_hist_rec.old_attribute15 := l_old_relship_rec.attribute15 ;
4162: l_relship_hist_rec.new_attribute15 := l_new_relship_rec.attribute15 ;
4163: END IF;
4164: --

Line 4228: x_return_status := fnd_api.g_ret_sts_error;

4224: END;
4225: -- End of modifications for Bug#2547034 on 09/20/02 - rtalluri
4226: EXCEPTION
4227: WHEN OTHERS THEN
4228: x_return_status := fnd_api.g_ret_sts_error;
4229: END;
4230: /* ----------------------------------------------------------------------------------------------------------+
4231: | Case1. Create/Update Relationship |
4232: | Only 'COMPONENT-OF' If subject_id not null and subject_id's creation_complete_flag |

Line 4295: x_return_status := fnd_api.g_ret_sts_success;

4291: -- End Add Code for Siebel Genesis Project
4292:
4293: BEGIN
4294:
4295: x_return_status := fnd_api.g_ret_sts_success;
4296: l_ii_relationship_rec := p_ii_relationship_rec;
4297: --
4298: IF l_ii_relationship_rec.relationship_id IS NOT NULL AND
4299: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN

Line 4299: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN

4295: x_return_status := fnd_api.g_ret_sts_success;
4296: l_ii_relationship_rec := p_ii_relationship_rec;
4297: --
4298: IF l_ii_relationship_rec.relationship_id IS NOT NULL AND
4299: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN
4300: IF l_ii_relationship_rec.subject_id IS NULL OR
4301: l_ii_relationship_rec.subject_id = FND_API.G_MISS_NUM THEN
4302: Begin
4303: select subject_id

Line 4301: l_ii_relationship_rec.subject_id = FND_API.G_MISS_NUM THEN

4297: --
4298: IF l_ii_relationship_rec.relationship_id IS NOT NULL AND
4299: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN
4300: IF l_ii_relationship_rec.subject_id IS NULL OR
4301: l_ii_relationship_rec.subject_id = FND_API.G_MISS_NUM THEN
4302: Begin
4303: select subject_id
4304: into l_ii_relationship_rec.subject_id
4305: from CSI_II_RELATIONSHIPS

Line 4311: l_ii_relationship_rec.object_id = FND_API.G_MISS_NUM THEN

4307: End;
4308: END IF;
4309: --
4310: IF l_ii_relationship_rec.object_id IS NULL OR
4311: l_ii_relationship_rec.object_id = FND_API.G_MISS_NUM THEN
4312: Begin
4313: select object_id
4314: into l_ii_relationship_rec.object_id
4315: from CSI_II_RELATIONSHIPS

Line 4411: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

4407: ,p_child_inst_tbl => px_child_inst_tbl
4408: );*/
4409: -- End Add Code for Siebel Genesis Project
4410:
4411: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4412: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4413: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4414: fnd_msg_pub.add;
4415: RAISE fnd_api.g_exc_error;

Line 4415: RAISE fnd_api.g_exc_error;

4411: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4412: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4413: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4414: fnd_msg_pub.add;
4415: RAISE fnd_api.g_exc_error;
4416: END IF;
4417:
4418: EXCEPTION
4419: WHEN OTHERS THEN

Line 4462: IF nvl(l_dummy,fnd_api.g_miss_num) > 0 THEN

4458: AND relationship_type_code='COMPONENT-OF'
4459: )
4460: AND creation_complete_flag = 'N';
4461:
4462: IF nvl(l_dummy,fnd_api.g_miss_num) > 0 THEN
4463: EXIT;
4464: ELSE
4465: SELECT object_version_number,
4466: config_inst_hdr_id, --added

Line 4501: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

4497: ,p_oks_txn_inst_tbl => px_oks_txn_inst_tbl
4498: ,p_child_inst_tbl => px_child_inst_tbl
4499: );
4500:
4501: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4502: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4503: fnd_message.set_token('instance_id',l_instance_rec1.instance_id);
4504: fnd_msg_pub.add;
4505: RAISE fnd_api.g_exc_error;

Line 4505: RAISE fnd_api.g_exc_error;

4501: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4502: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4503: fnd_message.set_token('instance_id',l_instance_rec1.instance_id);
4504: fnd_msg_pub.add;
4505: RAISE fnd_api.g_exc_error;
4506: END IF;
4507:
4508: END IF;
4509: END IF;

Line 4545: l_record_found VARCHAR2(1):= fnd_api.g_true;

4541: l_asset_assignment_tbl csi_datastructures_pub.instance_asset_tbl;
4542: l_instance_id_lst csi_datastructures_pub.id_tbl;
4543: l_instance_rec csi_datastructures_pub.instance_rec;
4544: l_subject_id NUMBER;
4545: l_record_found VARCHAR2(1):= fnd_api.g_true;
4546: BEGIN
4547: IF p_ii_relationship_rec.relationship_type_code='COMPONENT-OF' THEN
4548:
4549: BEGIN

Line 4572: l_record_found := fnd_api.g_false;

4568: AND (cp.active_end_date IS NULL OR cp.active_end_date > SYSDATE)
4569: AND (ca.active_end_date IS NULL OR ca.active_end_date > SYSDATE);
4570: EXCEPTION
4571: WHEN OTHERS THEN
4572: l_record_found := fnd_api.g_false;
4573: END;
4574:
4575: BEGIN
4576: SELECT instance_party_id

Line 4589: IF l_record_found = fnd_api.g_true

4585: WHEN OTHERS THEN
4586: NULL;
4587: END;
4588:
4589: IF l_record_found = fnd_api.g_true
4590: THEN
4591: BEGIN
4592: SELECT instance_id
4593: ,object_version_number

Line 4603: l_record_found := fnd_api.g_false;

4599: l_party_tbl(1).instance_id := p_ii_relationship_rec.subject_id;
4600: l_account_tbl(1).parent_tbl_index := 1;
4601: EXCEPTION
4602: WHEN OTHERS THEN
4603: l_record_found := fnd_api.g_false;
4604: END;
4605: END IF;
4606:
4607:

Line 4608: IF l_record_found = fnd_api.g_true

4604: END;
4605: END IF;
4606:
4607:
4608: IF l_record_found = fnd_api.g_true
4609: THEN
4610: csi_item_instance_pub.update_item_instance
4611: ( p_api_version => p_api_version
4612: ,p_commit => p_commit

Line 4629: IF NOT(x_return_status = fnd_api.g_ret_sts_success)

4625: ,x_msg_count => x_msg_count
4626: ,x_msg_data => x_msg_data
4627: );
4628:
4629: IF NOT(x_return_status = fnd_api.g_ret_sts_success)
4630: THEN
4631: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4632: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4633: fnd_msg_pub.add;

Line 4634: RAISE fnd_api.g_exc_error;

4630: THEN
4631: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4632: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4633: fnd_msg_pub.add;
4634: RAISE fnd_api.g_exc_error;
4635: END IF;
4636: END IF;
4637: END IF;
4638: END update_party_account;

Line 4691: IF NOT fnd_api.compatible_api_call ( l_api_version,

4687: -- standard start of api savepoint
4688: SAVEPOINT create_relationship_pvt;
4689:
4690: -- standard call to check for call compatibility.
4691: IF NOT fnd_api.compatible_api_call ( l_api_version,
4692: p_api_version,
4693: l_api_name,
4694: g_pkg_name)
4695: THEN

Line 4696: RAISE fnd_api.g_exc_unexpected_error;

4692: p_api_version,
4693: l_api_name,
4694: g_pkg_name)
4695: THEN
4696: RAISE fnd_api.g_exc_unexpected_error;
4697: END IF;
4698:
4699:
4700: -- initialize message list if p_init_msg_list is set to true.

Line 4701: IF fnd_api.to_boolean( p_init_msg_list )

4697: END IF;
4698:
4699:
4700: -- initialize message list if p_init_msg_list is set to true.
4701: IF fnd_api.to_boolean( p_init_msg_list )
4702: THEN
4703: fnd_msg_pub.initialize;
4704: END IF;
4705:

Line 4707: x_return_status := fnd_api.g_ret_sts_success;

4703: fnd_msg_pub.initialize;
4704: END IF;
4705:
4706: -- initialize api return status to success
4707: x_return_status := fnd_api.g_ret_sts_success;
4708:
4709: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
4710: IF (l_debug_level > 0) THEN
4711: CSI_gen_utility_pvt.put_line( 'create_relationship');

Line 4730: p_init_msg_list => fnd_api.g_false,

4726: END IF;
4727:
4728: -- invoke validation procedures
4729: validate_ii_relationships(
4730: p_init_msg_list => fnd_api.g_false,
4731: p_validation_level => p_validation_level,
4732: p_validation_mode => 'CREATE',
4733: p_ii_relationship_tbl => p_relationship_tbl,
4734: x_return_status => x_return_status,

Line 4739: IF x_return_status<>fnd_api.g_ret_sts_success THEN

4735: x_msg_count => x_msg_count,
4736: x_msg_data => x_msg_data);
4737:
4738:
4739: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4740: RAISE fnd_api.g_exc_error;
4741: END IF;
4742:
4743:

Line 4740: RAISE fnd_api.g_exc_error;

4736: x_msg_data => x_msg_data);
4737:
4738:
4739: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4740: RAISE fnd_api.g_exc_error;
4741: END IF;
4742:
4743:
4744:

Line 4749: (p_relationship_tbl(l_count).mandatory_flag = fnd_api.g_miss_char) ) THEN

4745: l_line_count := p_relationship_tbl.count;
4746:
4747: FOR l_count IN 1..l_line_count LOOP
4748: IF ( (p_relationship_tbl(l_count).mandatory_flag IS NULL) OR
4749: (p_relationship_tbl(l_count).mandatory_flag = fnd_api.g_miss_char) ) THEN
4750: p_relationship_tbl(l_count).mandatory_flag:='N';
4751: END IF;
4752:
4753: --Added for MACD lock functionality

Line 4755: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num

4751: END IF;
4752:
4753: --Added for MACD lock functionality
4754: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
4755: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
4756: THEN
4757: IF csi_item_instance_pvt.check_item_instance_lock
4758: ( p_instance_id => p_relationship_tbl(l_count).object_id)
4759: THEN

Line 4765: RAISE FND_API.G_EXC_ERROR;

4761: THEN
4762: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
4763: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
4764: FND_MSG_PUB.ADD;
4765: RAISE FND_API.G_EXC_ERROR;
4766: END IF;
4767: END IF;
4768: END IF;
4769: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND

Line 4770: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num

4766: END IF;
4767: END IF;
4768: END IF;
4769: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND
4770: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num
4771: THEN
4772: IF csi_item_instance_pvt.check_item_instance_lock
4773: ( p_instance_id => p_relationship_tbl(l_count).subject_id)
4774: THEN

Line 4780: RAISE FND_API.G_EXC_ERROR;

4776: THEN
4777: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
4778: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).subject_id);
4779: FND_MSG_PUB.ADD;
4780: RAISE FND_API.G_EXC_ERROR;
4781: END IF;
4782: END IF;
4783: END IF;
4784: -- End addition for MACD lock functionality

Line 4795: x_return_status:=fnd_api.g_ret_sts_success;

4791: p_relship_type_code => p_relationship_tbl(l_count).relationship_type_code,
4792: p_relationship_id => Null,
4793: p_mode => 'CREATE' )
4794: THEN
4795: x_return_status:=fnd_api.g_ret_sts_success;
4796: ELSE
4797: x_return_status:=fnd_api.g_ret_sts_error;
4798: RAISE fnd_api.g_exc_error;
4799: END IF;

Line 4797: x_return_status:=fnd_api.g_ret_sts_error;

4793: p_mode => 'CREATE' )
4794: THEN
4795: x_return_status:=fnd_api.g_ret_sts_success;
4796: ELSE
4797: x_return_status:=fnd_api.g_ret_sts_error;
4798: RAISE fnd_api.g_exc_error;
4799: END IF;
4800:
4801: IF ((x_return_status=fnd_api.g_ret_sts_success) AND

Line 4798: RAISE fnd_api.g_exc_error;

4794: THEN
4795: x_return_status:=fnd_api.g_ret_sts_success;
4796: ELSE
4797: x_return_status:=fnd_api.g_ret_sts_error;
4798: RAISE fnd_api.g_exc_error;
4799: END IF;
4800:
4801: IF ((x_return_status=fnd_api.g_ret_sts_success) AND
4802: (p_relationship_tbl(l_count).object_id IS NOT NULL) ) THEN

Line 4801: IF ((x_return_status=fnd_api.g_ret_sts_success) AND

4797: x_return_status:=fnd_api.g_ret_sts_error;
4798: RAISE fnd_api.g_exc_error;
4799: END IF;
4800:
4801: IF ((x_return_status=fnd_api.g_ret_sts_success) AND
4802: (p_relationship_tbl(l_count).object_id IS NOT NULL) ) THEN
4803: csi_ii_relationships_pvt.check_for_object
4804: (p_subject_id =>p_relationship_tbl(l_count).subject_id,
4805: p_object_id =>p_relationship_tbl(l_count).object_id,

Line 4811: IF x_return_status<>fnd_api.g_ret_sts_success THEN

4807: x_return_status =>x_return_status,
4808: x_msg_count =>x_msg_count,
4809: x_msg_data =>x_msg_data
4810: );
4811: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4812: RAISE fnd_api.g_exc_error;
4813: END IF;
4814: END IF;
4815: END IF; /* end of additional for cyclic relationship */

Line 4812: RAISE fnd_api.g_exc_error;

4808: x_msg_count =>x_msg_count,
4809: x_msg_data =>x_msg_data
4810: );
4811: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4812: RAISE fnd_api.g_exc_error;
4813: END IF;
4814: END IF;
4815: END IF; /* end of additional for cyclic relationship */
4816: /* Another one for cyclic relationship */

Line 4823: fnd_api.g_miss_num)

4819: IF relationship_not_exists(p_relationship_tbl(l_count).subject_id,
4820: p_relationship_tbl(l_count).object_id,
4821: p_relationship_tbl(l_count).relationship_type_code,
4822: 'CREATE',
4823: fnd_api.g_miss_num)
4824: THEN
4825: x_return_status:=fnd_api.g_ret_sts_success;
4826: ELSE
4827: x_return_status:=fnd_api.g_ret_sts_error;

Line 4825: x_return_status:=fnd_api.g_ret_sts_success;

4821: p_relationship_tbl(l_count).relationship_type_code,
4822: 'CREATE',
4823: fnd_api.g_miss_num)
4824: THEN
4825: x_return_status:=fnd_api.g_ret_sts_success;
4826: ELSE
4827: x_return_status:=fnd_api.g_ret_sts_error;
4828: RAISE fnd_api.g_exc_error;
4829: END IF;

Line 4827: x_return_status:=fnd_api.g_ret_sts_error;

4823: fnd_api.g_miss_num)
4824: THEN
4825: x_return_status:=fnd_api.g_ret_sts_success;
4826: ELSE
4827: x_return_status:=fnd_api.g_ret_sts_error;
4828: RAISE fnd_api.g_exc_error;
4829: END IF;
4830: -- Start of att enhancements by sguthiva
4831: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => p_relationship_tbl(l_count).object_id )

Line 4828: RAISE fnd_api.g_exc_error;

4824: THEN
4825: x_return_status:=fnd_api.g_ret_sts_success;
4826: ELSE
4827: x_return_status:=fnd_api.g_ret_sts_error;
4828: RAISE fnd_api.g_exc_error;
4829: END IF;
4830: -- Start of att enhancements by sguthiva
4831: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => p_relationship_tbl(l_count).object_id )
4832: THEN

Line 4841: RAISE fnd_api.g_exc_error;

4837: THEN
4838: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
4839: fnd_message.set_token('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
4840: fnd_msg_pub.add;
4841: RAISE fnd_api.g_exc_error;
4842: END IF;
4843: END IF;
4844:
4845: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => p_relationship_tbl(l_count).subject_id )

Line 4855: RAISE fnd_api.g_exc_error;

4851: THEN
4852: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
4853: fnd_message.set_token('INSTANCE_ID',p_relationship_tbl(l_count).subject_id);
4854: fnd_msg_pub.add;
4855: RAISE fnd_api.g_exc_error;
4856: END IF;
4857: END IF;
4858: -- End of att enhancements by sguthiva
4859: END IF;

Line 4864: (p_relationship_tbl(l_count).active_start_date = FND_API.G_MISS_DATE))

4860:
4861: /* end of cyclic relationship */
4862:
4863: IF ((p_relationship_tbl(l_count).active_start_date IS NULL) OR
4864: (p_relationship_tbl(l_count).active_start_date = FND_API.G_MISS_DATE))
4865: THEN
4866: p_relationship_tbl(l_count).active_start_date := SYSDATE;
4867: END IF;
4868:

Line 4869: IF x_return_status=fnd_api.g_ret_sts_success THEN

4865: THEN
4866: p_relationship_tbl(l_count).active_start_date := SYSDATE;
4867: END IF;
4868:
4869: IF x_return_status=fnd_api.g_ret_sts_success THEN
4870: -- srramakr Moved the Update_instance call before the table handler Bug # 3296009
4871: update_instance
4872: ( p_api_version => p_api_version,
4873: p_commit => fnd_api.g_false,

Line 4873: p_commit => fnd_api.g_false,

4869: IF x_return_status=fnd_api.g_ret_sts_success THEN
4870: -- srramakr Moved the Update_instance call before the table handler Bug # 3296009
4871: update_instance
4872: ( p_api_version => p_api_version,
4873: p_commit => fnd_api.g_false,
4874: p_init_msg_list => p_init_msg_list,
4875: p_validation_level => p_validation_level,
4876: p_ii_relationship_rec => p_relationship_tbl(l_count),
4877: p_txn_rec => p_txn_rec,

Line 4883: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN

4879: x_return_status => x_return_status,
4880: x_msg_count => x_msg_count,
4881: x_msg_data => x_msg_data);
4882: -- Added by sguthiva for bug 2373109
4883: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
4884: l_msg_index := 1;
4885: l_msg_count := x_msg_count;
4886: WHILE l_msg_count > 0
4887: LOOP

Line 4890: FND_API.G_FALSE );

4886: WHILE l_msg_count > 0
4887: LOOP
4888: x_msg_data := FND_MSG_PUB.GET
4889: ( l_msg_index,
4890: FND_API.G_FALSE );
4891: csi_gen_utility_pvt.put_line( ' Error from CSI_II_RELATIONSHIPS_PVT.CREATE_RELATIONSHIP');
4892: csi_gen_utility_pvt.put_line( ' Call to update_instance has errored ....');
4893: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
4894: l_msg_index := l_msg_index + 1;

Line 4897: RAISE FND_API.G_EXC_ERROR;

4893: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
4894: l_msg_index := l_msg_index + 1;
4895: l_msg_count := l_msg_count - 1;
4896: END LOOP;
4897: RAISE FND_API.G_EXC_ERROR;
4898: END IF;
4899: -- End of addition by sguthiva for bug 2373109
4900:
4901:

Line 4941: IF x_return_status <> fnd_api.g_ret_sts_success THEN

4937: -- hint: primary key should be returned.
4938: -- x_relationship_id := px_relationship_id;
4939: END IF;
4940:
4941: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4942: RAISE fnd_api.g_exc_error;
4943: END IF;
4944:
4945: csi_transactions_pvt.create_transaction

Line 4942: RAISE fnd_api.g_exc_error;

4938: -- x_relationship_id := px_relationship_id;
4939: END IF;
4940:
4941: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4942: RAISE fnd_api.g_exc_error;
4943: END IF;
4944:
4945: csi_transactions_pvt.create_transaction
4946: (

Line 4958: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

4954: ,x_msg_count => x_msg_count
4955: ,x_msg_data => x_msg_data
4956: );
4957:
4958: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4959: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
4960: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
4961: fnd_msg_pub.add;
4962: RAISE fnd_api.g_exc_error;

Line 4962: RAISE fnd_api.g_exc_error;

4958: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4959: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
4960: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
4961: fnd_msg_pub.add;
4962: RAISE fnd_api.g_exc_error;
4963: ROLLBACK TO create_relationship_pvt;
4964: END IF;
4965:
4966: -- The following code has been commented by sguthiva

Line 4973: p_commit => fnd_api.g_false,

4969: -- any changes to the ownership.
4970: /*
4971: update_party_account
4972: ( p_api_version => p_api_version,
4973: p_commit => fnd_api.g_false,
4974: p_init_msg_list => p_init_msg_list,
4975: p_validation_level => p_validation_level,
4976: p_ii_relationship_rec => p_relationship_tbl(l_count),
4977: p_txn_rec => p_txn_rec,

Line 4984: IF x_return_status = fnd_api.g_ret_sts_success THEN

4980: x_msg_data => x_msg_data);
4981: */
4982: -- End addition by sk for bug 2304221
4983:
4984: IF x_return_status = fnd_api.g_ret_sts_success THEN
4985:
4986: l_relship_history_id := NULL;
4987:
4988: csi_ii_relationships_h_pkg.insert_row(

Line 5060: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num

5056: l_org_assignments_tbl.delete;
5057: l_instance_id_lst.delete;
5058:
5059: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
5060: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
5061: THEN
5062: l_instance_rec.instance_id:=p_relationship_tbl(l_count).object_id;
5063: END IF;
5064:

Line 5078: RAISE fnd_api.g_exc_error;

5074: WHEN OTHERS
5075: THEN
5076: csi_gen_utility_pvt.put_line( 'Error from create relationship API.');
5077: csi_gen_utility_pvt.put_line( 'The object_id, which you are trying to cascade its ownership, is not found or expired in csi_item_instances table. ');
5078: RAISE fnd_api.g_exc_error;
5079: END;
5080:
5081: csi_item_instance_pub.update_item_instance
5082: ( p_api_version => p_api_version

Line 5100: IF NOT(x_return_status = fnd_api.g_ret_sts_success)

5096: ,x_msg_count => x_msg_count
5097: ,x_msg_data => x_msg_data
5098: );
5099:
5100: IF NOT(x_return_status = fnd_api.g_ret_sts_success)
5101: THEN
5102: csi_gen_utility_pvt.put_line( 'Error from create relationship API.');
5103: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
5104: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');

Line 5107: RAISE fnd_api.g_exc_error;

5103: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
5104: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
5105: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
5106: fnd_msg_pub.add;
5107: RAISE fnd_api.g_exc_error;
5108: END IF;
5109: END IF;
5110:
5111: -- End of cascade ownership changes bug 2972082

Line 5114: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5110:
5111: -- End of cascade ownership changes bug 2972082
5112:
5113: END LOOP;
5114: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5115: RAISE fnd_api.g_exc_error;
5116: END IF;
5117: --
5118: -- END of API BODY

Line 5115: RAISE fnd_api.g_exc_error;

5111: -- End of cascade ownership changes bug 2972082
5112:
5113: END LOOP;
5114: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5115: RAISE fnd_api.g_exc_error;
5116: END IF;
5117: --
5118: -- END of API BODY
5119: --

Line 5122: IF fnd_api.to_boolean( p_commit )

5118: -- END of API BODY
5119: --
5120:
5121: -- standard check for p_commit
5122: IF fnd_api.to_boolean( p_commit )
5123: THEN
5124: COMMIT WORK;
5125: END IF;
5126:

Line 5134: WHEN fnd_api.g_exc_error THEN

5130: p_data => x_msg_data
5131: );
5132:
5133: EXCEPTION
5134: WHEN fnd_api.g_exc_error THEN
5135: ROLLBACK TO create_relationship_pvt;
5136: x_return_status := fnd_api.g_ret_sts_error ;
5137: fnd_msg_pub.count_AND_get
5138: (p_count => x_msg_count ,

Line 5136: x_return_status := fnd_api.g_ret_sts_error ;

5132:
5133: EXCEPTION
5134: WHEN fnd_api.g_exc_error THEN
5135: ROLLBACK TO create_relationship_pvt;
5136: x_return_status := fnd_api.g_ret_sts_error ;
5137: fnd_msg_pub.count_AND_get
5138: (p_count => x_msg_count ,
5139: p_data => x_msg_data
5140: );

Line 5142: WHEN fnd_api.g_exc_unexpected_error THEN

5138: (p_count => x_msg_count ,
5139: p_data => x_msg_data
5140: );
5141:
5142: WHEN fnd_api.g_exc_unexpected_error THEN
5143: ROLLBACK TO create_relationship_pvt;
5144: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5145: fnd_msg_pub.count_AND_get
5146: (p_count => x_msg_count ,

Line 5144: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5140: );
5141:
5142: WHEN fnd_api.g_exc_unexpected_error THEN
5143: ROLLBACK TO create_relationship_pvt;
5144: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5145: fnd_msg_pub.count_AND_get
5146: (p_count => x_msg_count ,
5147: p_data => x_msg_data
5148: );

Line 5152: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5148: );
5149:
5150: WHEN OTHERS THEN
5151: ROLLBACK TO create_relationship_pvt;
5152: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5153: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
5154: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
5155: END IF;
5156: fnd_msg_pub.count_AND_get

Line 5267: IF NOT fnd_api.compatible_api_call ( l_api_version,

5263: BEGIN
5264: -- standard start of api savepoint
5265: SAVEPOINT update_relationship_pvt;
5266: -- standard call to check for call compatibility.
5267: IF NOT fnd_api.compatible_api_call ( l_api_version,
5268: p_api_version,
5269: l_api_name,
5270: g_pkg_name)
5271: THEN

Line 5272: RAISE fnd_api.g_exc_unexpected_error;

5268: p_api_version,
5269: l_api_name,
5270: g_pkg_name)
5271: THEN
5272: RAISE fnd_api.g_exc_unexpected_error;
5273: END IF;
5274:
5275:
5276: -- initialize message list IF p_init_msg_list IS set TO true.

Line 5277: IF fnd_api.to_boolean( p_init_msg_list )

5273: END IF;
5274:
5275:
5276: -- initialize message list IF p_init_msg_list IS set TO true.
5277: IF fnd_api.to_boolean( p_init_msg_list )
5278: THEN
5279: fnd_msg_pub.initialize;
5280: END IF;
5281:

Line 5284: x_return_status := fnd_api.g_ret_sts_success;

5280: END IF;
5281:
5282:
5283: -- initialize api return status to success
5284: x_return_status := fnd_api.g_ret_sts_success;
5285:
5286:
5287: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
5288: IF (l_debug_level > 0) THEN

Line 5308: p_init_msg_list => fnd_api.g_false,

5304: END IF;
5305:
5306:
5307: validate_ii_relationships(
5308: p_init_msg_list => fnd_api.g_false,
5309: p_validation_level => p_validation_level,
5310: p_validation_mode => 'UPDATE',
5311: p_ii_relationship_tbl => p_relationship_tbl,
5312: x_return_status => x_return_status,

Line 5316: IF x_return_status<>fnd_api.g_ret_sts_success THEN

5312: x_return_status => x_return_status,
5313: x_msg_count => x_msg_count,
5314: x_msg_data => x_msg_data);
5315:
5316: IF x_return_status<>fnd_api.g_ret_sts_success THEN
5317: RAISE fnd_api.g_exc_error;
5318: END IF;
5319:
5320: l_line_count := p_relationship_tbl.count;

Line 5317: RAISE fnd_api.g_exc_error;

5313: x_msg_count => x_msg_count,
5314: x_msg_data => x_msg_data);
5315:
5316: IF x_return_status<>fnd_api.g_ret_sts_success THEN
5317: RAISE fnd_api.g_exc_error;
5318: END IF;
5319:
5320: l_line_count := p_relationship_tbl.count;
5321:

Line 5334: RAISE fnd_api.g_exc_error;

5330: p_subject_id => p_relationship_tbl(l_count).subject_id )
5331: THEN
5332: fnd_message.set_name('CSI','CSI_API_INVALID_PARAMETERS');
5333: fnd_msg_pub.add;
5334: RAISE fnd_api.g_exc_error;
5335: END IF;
5336:
5337: --Added for MACD lock functionality
5338: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND

Line 5339: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num

5335: END IF;
5336:
5337: --Added for MACD lock functionality
5338: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
5339: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
5340: THEN
5341: IF csi_item_instance_pvt.check_item_instance_lock
5342: ( p_instance_id => p_relationship_tbl(l_count).object_id)
5343: THEN

Line 5349: RAISE FND_API.G_EXC_ERROR;

5345: THEN
5346: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
5347: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
5348: FND_MSG_PUB.ADD;
5349: RAISE FND_API.G_EXC_ERROR;
5350: END IF;
5351: END IF;
5352: END IF;
5353: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND

Line 5354: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num

5350: END IF;
5351: END IF;
5352: END IF;
5353: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5354: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num
5355: THEN
5356: IF csi_item_instance_pvt.check_item_instance_lock
5357: ( p_instance_id => p_relationship_tbl(l_count).subject_id)
5358: THEN

Line 5364: RAISE FND_API.G_EXC_ERROR;

5360: THEN
5361: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
5362: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).subject_id);
5363: FND_MSG_PUB.ADD;
5364: RAISE FND_API.G_EXC_ERROR;
5365: END IF;
5366: END IF;
5367: ELSE
5368: l_subject_lock:=NULL;

Line 5382: RAISE FND_API.G_EXC_ERROR;

5378: THEN
5379: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
5380: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',l_subject_lock);
5381: FND_MSG_PUB.ADD;
5382: RAISE FND_API.G_EXC_ERROR;
5383: END IF;
5384: END IF;
5385: EXCEPTION
5386: WHEN NO_DATA_FOUND THEN

Line 5397: AND (p_relationship_tbl(l_count).object_version_number <> fnd_api.g_miss_num) ) THEN

5393: l_new_relship_rec:=p_relationship_tbl(l_count);
5394: OPEN relship_csr (p_relationship_tbl(l_count).relationship_id);
5395: FETCH relship_csr INTO l_relship_csr;
5396: IF ( (l_relship_csr.object_version_number<>p_relationship_tbl(l_count).object_version_number)
5397: AND (p_relationship_tbl(l_count).object_version_number <> fnd_api.g_miss_num) ) THEN
5398: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
5399: fnd_msg_pub.add;
5400: RAISE fnd_api.g_exc_error;
5401: END IF;

Line 5400: RAISE fnd_api.g_exc_error;

5396: IF ( (l_relship_csr.object_version_number<>p_relationship_tbl(l_count).object_version_number)
5397: AND (p_relationship_tbl(l_count).object_version_number <> fnd_api.g_miss_num) ) THEN
5398: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
5399: fnd_msg_pub.add;
5400: RAISE fnd_api.g_exc_error;
5401: END IF;
5402: CLOSE relship_csr;
5403:
5404: /* Cyclic relationship */

Line 5409: RAISE fnd_api.g_exc_error;

5405: /* added this call to check configurator_id */
5406: /* IF config_set
5407: (p_relationship_id=>p_relationship_tbl(l_count).relationship_id)
5408: THEN
5409: RAISE fnd_api.g_exc_error;
5410: END IF;
5411: */
5412: /* added this to skip this validation ,in case subject and object_id are null */
5413: IF ((p_relationship_tbl(l_count).relationship_id IS NOT NULL

Line 5414: AND p_relationship_tbl(l_count).relationship_id <> fnd_api.g_miss_num)

5410: END IF;
5411: */
5412: /* added this to skip this validation ,in case subject and object_id are null */
5413: IF ((p_relationship_tbl(l_count).relationship_id IS NOT NULL
5414: AND p_relationship_tbl(l_count).relationship_id <> fnd_api.g_miss_num)
5415: AND ( p_relationship_tbl(l_count).object_id IS NOT NULL
5416: AND p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num))
5417: THEN
5418: /* End cyclic relationship */

Line 5416: AND p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num))

5412: /* added this to skip this validation ,in case subject and object_id are null */
5413: IF ((p_relationship_tbl(l_count).relationship_id IS NOT NULL
5414: AND p_relationship_tbl(l_count).relationship_id <> fnd_api.g_miss_num)
5415: AND ( p_relationship_tbl(l_count).object_id IS NOT NULL
5416: AND p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num))
5417: THEN
5418: /* End cyclic relationship */
5419: IF object_relship_exists(p_relationship_tbl(l_count).relationship_id,
5420: p_relationship_tbl(l_count).object_id,

Line 5423: x_return_status := fnd_api.g_ret_sts_success;

5419: IF object_relship_exists(p_relationship_tbl(l_count).relationship_id,
5420: p_relationship_tbl(l_count).object_id,
5421: p_relationship_tbl(l_count).relationship_type_code)
5422: THEN
5423: x_return_status := fnd_api.g_ret_sts_success;
5424: ELSE
5425: x_return_status := fnd_api.g_ret_sts_error;
5426: RAISE fnd_api.g_exc_error;
5427: END IF;

Line 5425: x_return_status := fnd_api.g_ret_sts_error;

5421: p_relationship_tbl(l_count).relationship_type_code)
5422: THEN
5423: x_return_status := fnd_api.g_ret_sts_success;
5424: ELSE
5425: x_return_status := fnd_api.g_ret_sts_error;
5426: RAISE fnd_api.g_exc_error;
5427: END IF;
5428: END IF;
5429:

Line 5426: RAISE fnd_api.g_exc_error;

5422: THEN
5423: x_return_status := fnd_api.g_ret_sts_success;
5424: ELSE
5425: x_return_status := fnd_api.g_ret_sts_error;
5426: RAISE fnd_api.g_exc_error;
5427: END IF;
5428: END IF;
5429:
5430: /* Cyclic relationship -- added the condition to skip the validation for 'CONNECTED-TO' relationship */

Line 5438: x_return_status:=fnd_api.g_ret_sts_success;

5434: p_relship_type_code => p_relationship_tbl(l_count).relationship_type_code,
5435: p_relationship_id => p_relationship_tbl(l_count).relationship_id,
5436: p_mode => 'UPDATE')
5437: THEN
5438: x_return_status:=fnd_api.g_ret_sts_success;
5439: ELSE
5440: x_return_status:=fnd_api.g_ret_sts_error;
5441: RAISE fnd_api.g_exc_error;
5442: END IF;

Line 5440: x_return_status:=fnd_api.g_ret_sts_error;

5436: p_mode => 'UPDATE')
5437: THEN
5438: x_return_status:=fnd_api.g_ret_sts_success;
5439: ELSE
5440: x_return_status:=fnd_api.g_ret_sts_error;
5441: RAISE fnd_api.g_exc_error;
5442: END IF;
5443: --
5444: -- check whether the Inverse Active Relationship exists

Line 5441: RAISE fnd_api.g_exc_error;

5437: THEN
5438: x_return_status:=fnd_api.g_ret_sts_success;
5439: ELSE
5440: x_return_status:=fnd_api.g_ret_sts_error;
5441: RAISE fnd_api.g_exc_error;
5442: END IF;
5443: --
5444: -- check whether the Inverse Active Relationship exists
5445: Begin

Line 5449: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,

5445: Begin
5446: select 'x'
5447: into l_exists
5448: from csi_ii_relationships
5449: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,
5450: p_relationship_tbl(l_count).subject_id)
5451: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,
5452: p_relationship_tbl(l_count).object_id)
5453: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,

Line 5451: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,

5447: into l_exists
5448: from csi_ii_relationships
5449: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,
5450: p_relationship_tbl(l_count).subject_id)
5451: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,
5452: p_relationship_tbl(l_count).object_id)
5453: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,
5454: l_relship_csr.relationship_type_code,
5455: p_relationship_tbl(l_count).relationship_type_code)

Line 5453: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,

5449: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,
5450: p_relationship_tbl(l_count).subject_id)
5451: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,
5452: p_relationship_tbl(l_count).object_id)
5453: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,
5454: l_relship_csr.relationship_type_code,
5455: p_relationship_tbl(l_count).relationship_type_code)
5456: and ((active_end_date is null) or (active_end_date > sysdate))
5457: and relationship_id <> p_relationship_tbl(l_count).relationship_id;

Line 5461: x_return_status := fnd_api.g_ret_sts_error;

5457: and relationship_id <> p_relationship_tbl(l_count).relationship_id;
5458: --
5459: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');
5460: fnd_msg_pub.add;
5461: x_return_status := fnd_api.g_ret_sts_error;
5462: RAISE fnd_api.g_exc_error;
5463: Exception
5464: when no_data_found then
5465: null;

Line 5462: RAISE fnd_api.g_exc_error;

5458: --
5459: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');
5460: fnd_msg_pub.add;
5461: x_return_status := fnd_api.g_ret_sts_error;
5462: RAISE fnd_api.g_exc_error;
5463: Exception
5464: when no_data_found then
5465: null;
5466: End;

Line 5472: p_relationship_tbl(l_count).object_id=fnd_api.g_miss_num

5468: -- Start of att enhancements by sguthiva
5469: ELSIF p_relationship_tbl(l_count).relationship_type_code = 'CONNECTED-TO'
5470: THEN
5471: IF p_relationship_tbl(l_count).object_id IS NULL OR
5472: p_relationship_tbl(l_count).object_id=fnd_api.g_miss_num
5473: THEN
5474: l_obj_id:=NULL;
5475: BEGIN
5476: SELECT object_id

Line 5489: p_relationship_tbl(l_count).subject_id=fnd_api.g_miss_num

5485: l_obj_id := p_relationship_tbl(l_count).object_id;
5486: END IF;
5487: --
5488: IF p_relationship_tbl(l_count).subject_id IS NULL OR
5489: p_relationship_tbl(l_count).subject_id=fnd_api.g_miss_num
5490: THEN
5491: l_sub_id:=NULL;
5492: BEGIN
5493: SELECT subject_id

Line 5515: RAISE fnd_api.g_exc_error;

5511: THEN
5512: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
5513: fnd_message.set_token('INSTANCE_ID',l_obj_id);
5514: fnd_msg_pub.add;
5515: RAISE fnd_api.g_exc_error;
5516: END IF;
5517: END IF;
5518: --
5519: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => l_sub_id )

Line 5529: RAISE fnd_api.g_exc_error;

5525: THEN
5526: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
5527: fnd_message.set_token('INSTANCE_ID',l_sub_id);
5528: fnd_msg_pub.add;
5529: RAISE fnd_api.g_exc_error;
5530: END IF;
5531: END IF;
5532: -- End of att enhancements by sguthiva
5533: END IF;

Line 5536: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND

5532: -- End of att enhancements by sguthiva
5533: END IF;
5534: --
5535: IF (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5536: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5537: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id
5538: AND ( (p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5539: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5540: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF'

Line 5539: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND

5535: IF (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5536: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5537: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id
5538: AND ( (p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5539: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5540: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF'
5541: )
5542: OR (p_relationship_tbl(l_count).relationship_type_code = fnd_api.g_miss_char AND
5543: l_relship_csr.relationship_type_code = 'COMPONENT-OF'

Line 5542: OR (p_relationship_tbl(l_count).relationship_type_code = fnd_api.g_miss_char AND

5538: AND ( (p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5539: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5540: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF'
5541: )
5542: OR (p_relationship_tbl(l_count).relationship_type_code = fnd_api.g_miss_char AND
5543: l_relship_csr.relationship_type_code = 'COMPONENT-OF'
5544: )
5545: )
5546: )

Line 5550: p_relationship_tbl(l_count).ACTIVE_END_DATE <> fnd_api.g_miss_date AND

5546: )
5547: OR
5548: (l_relship_csr.relationship_type_code = 'COMPONENT-OF' AND
5549: p_relationship_tbl(l_count).ACTIVE_END_DATE <= SYSDATE AND
5550: p_relationship_tbl(l_count).ACTIVE_END_DATE <> fnd_api.g_miss_date AND
5551: p_relationship_tbl(l_count).ACTIVE_END_DATE IS NOT NULL
5552: )
5553: THEN
5554: l_object_id := NULL;

Line 5628: x_return_status:=fnd_api.g_ret_sts_success;

5624: p_relationship_tbl(l_count).relationship_type_code,
5625: 'UPDATE',
5626: p_relationship_tbl(l_count).relationship_id)
5627: THEN
5628: x_return_status:=fnd_api.g_ret_sts_success;
5629: ELSE
5630: x_return_status:=fnd_api.g_ret_sts_error;
5631: RAISE fnd_api.g_exc_error;
5632: END IF;

Line 5630: x_return_status:=fnd_api.g_ret_sts_error;

5626: p_relationship_tbl(l_count).relationship_id)
5627: THEN
5628: x_return_status:=fnd_api.g_ret_sts_success;
5629: ELSE
5630: x_return_status:=fnd_api.g_ret_sts_error;
5631: RAISE fnd_api.g_exc_error;
5632: END IF;
5633: END IF;
5634:

Line 5631: RAISE fnd_api.g_exc_error;

5627: THEN
5628: x_return_status:=fnd_api.g_ret_sts_success;
5629: ELSE
5630: x_return_status:=fnd_api.g_ret_sts_error;
5631: RAISE fnd_api.g_exc_error;
5632: END IF;
5633: END IF;
5634:
5635: IF x_return_status = fnd_api.g_ret_sts_success THEN

Line 5635: IF x_return_status = fnd_api.g_ret_sts_success THEN

5631: RAISE fnd_api.g_exc_error;
5632: END IF;
5633: END IF;
5634:
5635: IF x_return_status = fnd_api.g_ret_sts_success THEN
5636: -- Update for the New subject only if the subject or relationship type is changing
5637: -- OR during Un-expiry
5638: IF (( (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5639: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND

Line 5639: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND

5635: IF x_return_status = fnd_api.g_ret_sts_success THEN
5636: -- Update for the New subject only if the subject or relationship type is changing
5637: -- OR during Un-expiry
5638: IF (( (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5639: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5640: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id) OR
5641: ( p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5642: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5643: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF' AND

Line 5642: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND

5638: IF (( (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5639: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5640: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id) OR
5641: ( p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5642: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5643: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF' AND
5644: l_relship_csr.relationship_type_code <> p_relationship_tbl(l_count).relationship_type_code) )
5645: OR
5646: ( (p_relationship_tbl(l_count).active_end_date IS NULL AND

Line 5648: (p_relationship_tbl(l_count).subject_id = FND_API.G_MISS_NUM OR

5644: l_relship_csr.relationship_type_code <> p_relationship_tbl(l_count).relationship_type_code) )
5645: OR
5646: ( (p_relationship_tbl(l_count).active_end_date IS NULL AND
5647: nvl(l_relship_csr.active_end_date,(sysdate+1)) <= SYSDATE) AND
5648: (p_relationship_tbl(l_count).subject_id = FND_API.G_MISS_NUM OR
5649: p_relationship_tbl(l_count).subject_id = l_relship_csr.subject_id) )
5650: )
5651: THEN
5652: csi_gen_utility_pvt.put_line('Calling Update_Instance..');

Line 5655: p_commit => fnd_api.g_false,--p_commit,

5651: THEN
5652: csi_gen_utility_pvt.put_line('Calling Update_Instance..');
5653: update_instance
5654: ( p_api_version => p_api_version,
5655: p_commit => fnd_api.g_false,--p_commit,
5656: p_init_msg_list => p_init_msg_list,
5657: p_validation_level => p_validation_level,
5658: p_ii_relationship_rec => p_relationship_tbl(l_count),
5659: p_txn_rec => p_txn_rec,

Line 5664: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN

5660: p_mode => 'UPDATE',
5661: x_return_status => x_return_status,
5662: x_msg_count => x_msg_count,
5663: x_msg_data => x_msg_data);
5664: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
5665: l_msg_index := 1;
5666: l_msg_count := x_msg_count;
5667: WHILE l_msg_count > 0
5668: LOOP

Line 5671: FND_API.G_FALSE );

5667: WHILE l_msg_count > 0
5668: LOOP
5669: x_msg_data := FND_MSG_PUB.GET
5670: ( l_msg_index,
5671: FND_API.G_FALSE );
5672: csi_gen_utility_pvt.put_line( ' Error from CSI_II_RELATIONSHIPS_PVT.UPDATE_RELATIONSHIP');
5673: csi_gen_utility_pvt.put_line( ' Call to update_instance has errored ....');
5674: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
5675: l_msg_index := l_msg_index + 1;

Line 5678: RAISE FND_API.G_EXC_ERROR;

5674: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
5675: l_msg_index := l_msg_index + 1;
5676: l_msg_count := l_msg_count - 1;
5677: END LOOP;
5678: RAISE FND_API.G_EXC_ERROR;
5679: END IF;
5680: END IF;
5681: --
5682: csi_ii_relationships_pkg.update_row(

Line 5688: p_active_start_date => fnd_api.g_miss_date, -- p_relationship_tbl(l_count).active_start_date,

5684: p_relationship_type_code => p_relationship_tbl(l_count).relationship_type_code,
5685: p_object_id => p_relationship_tbl(l_count).object_id,
5686: p_subject_id => p_relationship_tbl(l_count).subject_id,
5687: p_position_reference => p_relationship_tbl(l_count).position_reference,
5688: p_active_start_date => fnd_api.g_miss_date, -- p_relationship_tbl(l_count).active_start_date,
5689: p_active_end_date => p_relationship_tbl(l_count).active_end_date,
5690: p_display_order => p_relationship_tbl(l_count).display_order,
5691: p_mandatory_flag => p_relationship_tbl(l_count).mandatory_flag,
5692: p_context => p_relationship_tbl(l_count).context,

Line 5708: p_created_by => fnd_api.g_miss_num,

5704: p_attribute12 => p_relationship_tbl(l_count).attribute12,
5705: p_attribute13 => p_relationship_tbl(l_count).attribute13,
5706: p_attribute14 => p_relationship_tbl(l_count).attribute14,
5707: p_attribute15 => p_relationship_tbl(l_count).attribute15,
5708: p_created_by => fnd_api.g_miss_num,
5709: p_creation_date => fnd_api.g_miss_date,
5710: p_last_updated_by => fnd_global.user_id,
5711: p_last_update_date => SYSDATE,
5712: p_last_update_login => fnd_global.conc_login_id,

Line 5709: p_creation_date => fnd_api.g_miss_date,

5705: p_attribute13 => p_relationship_tbl(l_count).attribute13,
5706: p_attribute14 => p_relationship_tbl(l_count).attribute14,
5707: p_attribute15 => p_relationship_tbl(l_count).attribute15,
5708: p_created_by => fnd_api.g_miss_num,
5709: p_creation_date => fnd_api.g_miss_date,
5710: p_last_updated_by => fnd_global.user_id,
5711: p_last_update_date => SYSDATE,
5712: p_last_update_login => fnd_global.conc_login_id,
5713: p_object_version_number => p_relationship_tbl(l_count).object_version_number);

Line 5714: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5710: p_last_updated_by => fnd_global.user_id,
5711: p_last_update_date => SYSDATE,
5712: p_last_update_login => fnd_global.conc_login_id,
5713: p_object_version_number => p_relationship_tbl(l_count).object_version_number);
5714: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5715: RAISE fnd_api.g_exc_error;
5716: END IF;
5717:
5718: /*

Line 5715: RAISE fnd_api.g_exc_error;

5711: p_last_update_date => SYSDATE,
5712: p_last_update_login => fnd_global.conc_login_id,
5713: p_object_version_number => p_relationship_tbl(l_count).object_version_number);
5714: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5715: RAISE fnd_api.g_exc_error;
5716: END IF;
5717:
5718: /*
5719: ELSE

Line 5722: p_commit => fnd_api.g_false,

5718: /*
5719: ELSE
5720: csi_ii_relationships_pvt.expire_relationship
5721: (p_api_version => p_api_version,
5722: p_commit => fnd_api.g_false,
5723: p_init_msg_list => p_init_msg_list,
5724: p_validation_level => p_validation_level,
5725: p_relationship_rec => p_relationship_tbl(l_count),
5726: p_txn_rec => p_txn_rec,

Line 5733: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5729: x_msg_count => x_msg_count,
5730: x_msg_data => x_msg_data);
5731:
5732:
5733: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5734: RAISE fnd_api.g_exc_error;
5735: END IF;
5736:
5737: l_relationship_tbl(1).relationship_type_code := p_relationship_tbl(l_count).relationship_type_code; --'CONNECTED-TO' ;

Line 5734: RAISE fnd_api.g_exc_error;

5730: x_msg_data => x_msg_data);
5731:
5732:
5733: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5734: RAISE fnd_api.g_exc_error;
5735: END IF;
5736:
5737: l_relationship_tbl(1).relationship_type_code := p_relationship_tbl(l_count).relationship_type_code; --'CONNECTED-TO' ;
5738: l_relationship_tbl(1).object_id := p_relationship_tbl(l_count).object_id;

Line 5746: p_commit => fnd_api.g_false,

5742: l_relationship_tbl(1).object_version_number:=1;
5743:
5744: csi_ii_relationships_pvt.create_relationship(
5745: p_api_version => p_api_version,
5746: p_commit => fnd_api.g_false,
5747: p_init_msg_list => p_init_msg_list,
5748: p_validation_level => p_validation_level,
5749: p_relationship_tbl => l_relationship_tbl,
5750: p_txn_rec => p_txn_rec,

Line 5755: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5751: x_return_status => x_return_status,
5752: x_msg_count => x_msg_count,
5753: x_msg_data => x_msg_data);
5754:
5755: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5756: RAISE fnd_api.g_exc_error;
5757: END IF;
5758: -- END IF;
5759: */

Line 5756: RAISE fnd_api.g_exc_error;

5752: x_msg_count => x_msg_count,
5753: x_msg_data => x_msg_data);
5754:
5755: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5756: RAISE fnd_api.g_exc_error;
5757: END IF;
5758: -- END IF;
5759: */
5760: -- END IF;

Line 5763: /* IF x_return_status <> fnd_api.g_ret_sts_success THEN

5759: */
5760: -- END IF;
5761: END IF;
5762:
5763: /* IF x_return_status <> fnd_api.g_ret_sts_success THEN
5764: RAISE fnd_api.g_exc_error;
5765: END IF;*/
5766: csi_transactions_pvt.create_transaction
5767: (

Line 5764: RAISE fnd_api.g_exc_error;

5760: -- END IF;
5761: END IF;
5762:
5763: /* IF x_return_status <> fnd_api.g_ret_sts_success THEN
5764: RAISE fnd_api.g_exc_error;
5765: END IF;*/
5766: csi_transactions_pvt.create_transaction
5767: (
5768: p_api_version => p_api_version

Line 5779: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

5775: ,x_msg_count => x_msg_count
5776: ,x_msg_data => x_msg_data
5777: );
5778:
5779: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5780: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
5781: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
5782: fnd_msg_pub.add;
5783: RAISE fnd_api.g_exc_error;

Line 5783: RAISE fnd_api.g_exc_error;

5779: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5780: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
5781: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
5782: fnd_msg_pub.add;
5783: RAISE fnd_api.g_exc_error;
5784: ROLLBACK TO create_relationship_pvt;
5785: END IF;
5786: --
5787: l_instance_rec:=l_temp_ins_rec;

Line 5803: nvl(p_replace_flag,fnd_api.g_false)<> fnd_api.g_true

5799: l_instance_rec.object_version_number IS NOT NULL AND
5800: l_found
5801: THEN
5802: IF l_relship_csr.subject_id = l_instance_rec.instance_id AND
5803: nvl(p_replace_flag,fnd_api.g_false)<> fnd_api.g_true
5804: THEN
5805: csi_gen_utility_pvt.put_line('Calling update_item_instance..');
5806: csi_gen_utility_pvt.put_line('Parameter p_called_from_rel set to true..');
5807: csi_item_instance_pvt.update_item_instance

Line 5823: ,p_called_from_rel => fnd_api.g_true

5819: ,p_location_tbl => l_location_tbl
5820: ,p_generic_id_tbl => l_generic_id_tbl
5821: ,p_lookup_tbl => l_lookup_tbl
5822: ,p_ins_count_rec => l_ins_count_rec
5823: ,p_called_from_rel => fnd_api.g_true
5824: ,p_oks_txn_inst_tbl => px_oks_txn_inst_tbl
5825: ,p_child_inst_tbl => px_child_inst_tbl
5826: );
5827: END IF;

Line 5829: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

5825: ,p_child_inst_tbl => px_child_inst_tbl
5826: );
5827: END IF;
5828:
5829: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5830: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
5831: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
5832: fnd_msg_pub.add;
5833: RAISE fnd_api.g_exc_error;

Line 5833: RAISE fnd_api.g_exc_error;

5829: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5830: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
5831: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
5832: fnd_msg_pub.add;
5833: RAISE fnd_api.g_exc_error;
5834: END IF;
5835: END IF;
5836: --
5837: l_old_relship_rec.relationship_id := l_relship_csr.relationship_id;

Line 5890: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num

5886: l_org_assignments_tbl.delete;
5887: l_inst_id_lst.delete;
5888:
5889: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
5890: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
5891: THEN
5892: l_inst_rec.instance_id:=p_relationship_tbl(l_count).object_id;
5893: ELSE
5894: BEGIN

Line 5904: RAISE fnd_api.g_exc_error;

5900: WHEN OTHERS
5901: THEN
5902: csi_gen_utility_pvt.put_line( 'Error from update relationship API.');
5903: csi_gen_utility_pvt.put_line( 'Object_id not found in csi_ii_relationships to cascade ownership');
5904: RAISE fnd_api.g_exc_error;
5905: END;
5906: END IF;
5907:
5908: BEGIN

Line 5921: RAISE fnd_api.g_exc_error;

5917: WHEN OTHERS
5918: THEN
5919: csi_gen_utility_pvt.put_line( 'Error from update relationship API.');
5920: csi_gen_utility_pvt.put_line( 'The object_id, which you are trying to cascade its ownership, is not found or expired in csi_item_instances table. ');
5921: RAISE fnd_api.g_exc_error;
5922: END;
5923:
5924: csi_item_instance_pub.update_item_instance
5925: ( p_api_version => p_api_version

Line 5943: IF NOT(x_return_status = fnd_api.g_ret_sts_success)

5939: ,x_msg_count => x_msg_count
5940: ,x_msg_data => x_msg_data
5941: );
5942:
5943: IF NOT(x_return_status = fnd_api.g_ret_sts_success)
5944: THEN
5945: csi_gen_utility_pvt.put_line( 'Error from update relationship API.');
5946: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
5947: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');

Line 5950: RAISE fnd_api.g_exc_error;

5946: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
5947: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
5948: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
5949: fnd_msg_pub.add;
5950: RAISE fnd_api.g_exc_error;
5951: END IF;
5952: END IF;
5953:
5954: -- End of cascade ownership changes bug 2972082

Line 5962: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5958: --
5959: -- END of API body.
5960: --
5961:
5962: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5963: RAISE fnd_api.g_exc_error;
5964: END IF;
5965:
5966: -- standard check for p_commit

Line 5963: RAISE fnd_api.g_exc_error;

5959: -- END of API body.
5960: --
5961:
5962: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5963: RAISE fnd_api.g_exc_error;
5964: END IF;
5965:
5966: -- standard check for p_commit
5967: IF fnd_api.to_boolean( p_commit )

Line 5967: IF fnd_api.to_boolean( p_commit )

5963: RAISE fnd_api.g_exc_error;
5964: END IF;
5965:
5966: -- standard check for p_commit
5967: IF fnd_api.to_boolean( p_commit )
5968: THEN
5969: COMMIT WORK;
5970: END IF;
5971:

Line 5982: WHEN fnd_api.g_exc_error THEN

5978: p_data => x_msg_data
5979: );
5980:
5981: EXCEPTION
5982: WHEN fnd_api.g_exc_error THEN
5983: ROLLBACK TO update_relationship_pvt;
5984: x_return_status := fnd_api.g_ret_sts_error ;
5985: fnd_msg_pub.count_AND_get
5986: (p_count => x_msg_count ,

Line 5984: x_return_status := fnd_api.g_ret_sts_error ;

5980:
5981: EXCEPTION
5982: WHEN fnd_api.g_exc_error THEN
5983: ROLLBACK TO update_relationship_pvt;
5984: x_return_status := fnd_api.g_ret_sts_error ;
5985: fnd_msg_pub.count_AND_get
5986: (p_count => x_msg_count ,
5987: p_data => x_msg_data
5988: );

Line 5990: WHEN fnd_api.g_exc_unexpected_error THEN

5986: (p_count => x_msg_count ,
5987: p_data => x_msg_data
5988: );
5989:
5990: WHEN fnd_api.g_exc_unexpected_error THEN
5991: ROLLBACK TO update_relationship_pvt;
5992: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5993: fnd_msg_pub.count_AND_get
5994: (p_count => x_msg_count ,

Line 5992: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5988: );
5989:
5990: WHEN fnd_api.g_exc_unexpected_error THEN
5991: ROLLBACK TO update_relationship_pvt;
5992: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5993: fnd_msg_pub.count_AND_get
5994: (p_count => x_msg_count ,
5995: p_data => x_msg_data
5996: );

Line 6000: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5996: );
5997:
5998: WHEN OTHERS THEN
5999: ROLLBACK TO update_relationship_pvt;
6000: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6001: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6002: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
6003: END IF;
6004: fnd_msg_pub.count_AND_get

Line 6088: IF NOT fnd_api.compatible_api_call ( l_api_version,

6084: -- standard start of api savepoint
6085: SAVEPOINT expire_relationship_pvt;
6086:
6087: -- standard call to check for call compatibility.
6088: IF NOT fnd_api.compatible_api_call ( l_api_version,
6089: p_api_version,
6090: l_api_name,
6091: g_pkg_name)
6092: THEN

Line 6093: RAISE fnd_api.g_exc_unexpected_error;

6089: p_api_version,
6090: l_api_name,
6091: g_pkg_name)
6092: THEN
6093: RAISE fnd_api.g_exc_unexpected_error;
6094: END IF;
6095:
6096: -- initialize message list if p_init_msg_list is set to true.
6097: IF fnd_api.to_boolean( p_init_msg_list )

Line 6097: IF fnd_api.to_boolean( p_init_msg_list )

6093: RAISE fnd_api.g_exc_unexpected_error;
6094: END IF;
6095:
6096: -- initialize message list if p_init_msg_list is set to true.
6097: IF fnd_api.to_boolean( p_init_msg_list )
6098: THEN
6099: fnd_msg_pub.initialize;
6100: END IF;
6101:

Line 6103: x_return_status := fnd_api.g_ret_sts_success;

6099: fnd_msg_pub.initialize;
6100: END IF;
6101:
6102: -- initialize api return status to success
6103: x_return_status := fnd_api.g_ret_sts_success;
6104:
6105: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
6106: IF (l_debug_level > 0) THEN
6107: CSI_gen_utility_pvt.put_line( 'expire_relationship');

Line 6131: AND (p_relationship_rec.object_version_number <> fnd_api.g_miss_num) ) THEN

6127: --
6128: OPEN relship_csr (p_relationship_rec.relationship_id);
6129: FETCH relship_csr INTO l_relship_csr;
6130: IF ( (l_relship_csr.object_version_number<>p_relationship_rec.object_version_number)
6131: AND (p_relationship_rec.object_version_number <> fnd_api.g_miss_num) ) THEN
6132: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
6133: fnd_msg_pub.add;
6134: RAISE fnd_api.g_exc_error;
6135: END IF;

Line 6134: RAISE fnd_api.g_exc_error;

6130: IF ( (l_relship_csr.object_version_number<>p_relationship_rec.object_version_number)
6131: AND (p_relationship_rec.object_version_number <> fnd_api.g_miss_num) ) THEN
6132: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
6133: fnd_msg_pub.add;
6134: RAISE fnd_api.g_exc_error;
6135: END IF;
6136: CLOSE relship_csr;
6137:
6138: l_ii_relationship_tbl(1) := p_relationship_rec;

Line 6140: p_init_msg_list => fnd_api.g_false,

6136: CLOSE relship_csr;
6137:
6138: l_ii_relationship_tbl(1) := p_relationship_rec;
6139: validate_ii_relationships(
6140: p_init_msg_list => fnd_api.g_false,
6141: p_validation_level => p_validation_level,
6142: p_validation_mode => 'EXPIRE',
6143: p_ii_relationship_tbl => l_ii_relationship_tbl,
6144: x_return_status => x_return_status,

Line 6148: IF x_return_status<>fnd_api.g_ret_sts_success THEN

6144: x_return_status => x_return_status,
6145: x_msg_count => x_msg_count,
6146: x_msg_data => x_msg_data);
6147:
6148: IF x_return_status<>fnd_api.g_ret_sts_success THEN
6149: RAISE fnd_api.g_exc_error;
6150: END IF;
6151: IF l_relship_csr.relationship_type_code = 'COMPONENT-OF'
6152: THEN

Line 6149: RAISE fnd_api.g_exc_error;

6145: x_msg_count => x_msg_count,
6146: x_msg_data => x_msg_data);
6147:
6148: IF x_return_status<>fnd_api.g_ret_sts_success THEN
6149: RAISE fnd_api.g_exc_error;
6150: END IF;
6151: IF l_relship_csr.relationship_type_code = 'COMPONENT-OF'
6152: THEN
6153: BEGIN

Line 6223: l_relship_csr.object_id <> fnd_api.g_miss_num

6219:
6220:
6221: --Added for MACD lock functionality
6222: IF l_relship_csr.object_id IS NOT NULL AND
6223: l_relship_csr.object_id <> fnd_api.g_miss_num
6224: THEN
6225: IF csi_item_instance_pvt.check_item_instance_lock
6226: ( p_instance_id => l_relship_csr.object_id)
6227: THEN

Line 6234: RAISE FND_API.G_EXC_ERROR;

6230: THEN
6231: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
6232: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',l_relship_csr.object_id);
6233: FND_MSG_PUB.ADD;
6234: RAISE FND_API.G_EXC_ERROR;
6235: END IF;
6236: END IF;
6237: END IF;
6238:

Line 6240: l_relship_csr.subject_id <> fnd_api.g_miss_num

6236: END IF;
6237: END IF;
6238:
6239: IF l_relship_csr.subject_id IS NOT NULL AND
6240: l_relship_csr.subject_id <> fnd_api.g_miss_num
6241: THEN
6242: IF csi_item_instance_pvt.check_item_instance_lock
6243: ( p_instance_id => l_relship_csr.subject_id)
6244: THEN

Line 6248: RAISE FND_API.G_EXC_ERROR;

6244: THEN
6245: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
6246: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',l_relship_csr.subject_id);
6247: FND_MSG_PUB.ADD;
6248: RAISE FND_API.G_EXC_ERROR;
6249: END IF;
6250: END IF;
6251: -- End addition for MACD lock functionality
6252:

Line 6257: p_relationship_type_code => fnd_api.g_miss_char,

6253:
6254:
6255: csi_ii_relationships_pkg.update_row(
6256: p_relationship_id => p_relationship_rec.relationship_id,
6257: p_relationship_type_code => fnd_api.g_miss_char,
6258: p_object_id => fnd_api.g_miss_num,
6259: p_subject_id => fnd_api.g_miss_num,
6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,

Line 6258: p_object_id => fnd_api.g_miss_num,

6254:
6255: csi_ii_relationships_pkg.update_row(
6256: p_relationship_id => p_relationship_rec.relationship_id,
6257: p_relationship_type_code => fnd_api.g_miss_char,
6258: p_object_id => fnd_api.g_miss_num,
6259: p_subject_id => fnd_api.g_miss_num,
6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,

Line 6259: p_subject_id => fnd_api.g_miss_num,

6255: csi_ii_relationships_pkg.update_row(
6256: p_relationship_id => p_relationship_rec.relationship_id,
6257: p_relationship_type_code => fnd_api.g_miss_char,
6258: p_object_id => fnd_api.g_miss_num,
6259: p_subject_id => fnd_api.g_miss_num,
6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,

Line 6260: p_position_reference => fnd_api.g_miss_char,

6256: p_relationship_id => p_relationship_rec.relationship_id,
6257: p_relationship_type_code => fnd_api.g_miss_char,
6258: p_object_id => fnd_api.g_miss_num,
6259: p_subject_id => fnd_api.g_miss_num,
6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,

Line 6261: p_active_start_date => fnd_api.g_miss_date,

6257: p_relationship_type_code => fnd_api.g_miss_char,
6258: p_object_id => fnd_api.g_miss_num,
6259: p_subject_id => fnd_api.g_miss_num,
6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,

Line 6263: p_display_order => fnd_api.g_miss_num,

6259: p_subject_id => fnd_api.g_miss_num,
6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,

Line 6264: p_mandatory_flag => fnd_api.g_miss_char,

6260: p_position_reference => fnd_api.g_miss_char,
6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,

Line 6265: p_context => fnd_api.g_miss_char,

6261: p_active_start_date => fnd_api.g_miss_date,
6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,

Line 6266: p_attribute1 => fnd_api.g_miss_char,

6262: p_active_end_date => l_sysdate,
6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,

Line 6267: p_attribute2 => fnd_api.g_miss_char,

6263: p_display_order => fnd_api.g_miss_num,
6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,

Line 6268: p_attribute3 => fnd_api.g_miss_char,

6264: p_mandatory_flag => fnd_api.g_miss_char,
6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,

Line 6269: p_attribute4 => fnd_api.g_miss_char,

6265: p_context => fnd_api.g_miss_char,
6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,

Line 6270: p_attribute5 => fnd_api.g_miss_char,

6266: p_attribute1 => fnd_api.g_miss_char,
6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,

Line 6271: p_attribute6 => fnd_api.g_miss_char,

6267: p_attribute2 => fnd_api.g_miss_char,
6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,

Line 6272: p_attribute7 => fnd_api.g_miss_char,

6268: p_attribute3 => fnd_api.g_miss_char,
6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,

Line 6273: p_attribute8 => fnd_api.g_miss_char,

6269: p_attribute4 => fnd_api.g_miss_char,
6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,

Line 6274: p_attribute9 => fnd_api.g_miss_char,

6270: p_attribute5 => fnd_api.g_miss_char,
6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,

Line 6275: p_attribute10 => fnd_api.g_miss_char,

6271: p_attribute6 => fnd_api.g_miss_char,
6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,

Line 6276: p_attribute11 => fnd_api.g_miss_char,

6272: p_attribute7 => fnd_api.g_miss_char,
6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,

Line 6277: p_attribute12 => fnd_api.g_miss_char,

6273: p_attribute8 => fnd_api.g_miss_char,
6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,
6281: p_created_by => fnd_api.g_miss_num,

Line 6278: p_attribute13 => fnd_api.g_miss_char,

6274: p_attribute9 => fnd_api.g_miss_char,
6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,
6281: p_created_by => fnd_api.g_miss_num,
6282: p_creation_date => fnd_api.g_miss_date,

Line 6279: p_attribute14 => fnd_api.g_miss_char,

6275: p_attribute10 => fnd_api.g_miss_char,
6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,
6281: p_created_by => fnd_api.g_miss_num,
6282: p_creation_date => fnd_api.g_miss_date,
6283: p_last_updated_by => fnd_global.user_id,

Line 6280: p_attribute15 => fnd_api.g_miss_char,

6276: p_attribute11 => fnd_api.g_miss_char,
6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,
6281: p_created_by => fnd_api.g_miss_num,
6282: p_creation_date => fnd_api.g_miss_date,
6283: p_last_updated_by => fnd_global.user_id,
6284: p_last_update_date => l_sysdate,

Line 6281: p_created_by => fnd_api.g_miss_num,

6277: p_attribute12 => fnd_api.g_miss_char,
6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,
6281: p_created_by => fnd_api.g_miss_num,
6282: p_creation_date => fnd_api.g_miss_date,
6283: p_last_updated_by => fnd_global.user_id,
6284: p_last_update_date => l_sysdate,
6285: p_last_update_login => fnd_global.conc_login_id,

Line 6282: p_creation_date => fnd_api.g_miss_date,

6278: p_attribute13 => fnd_api.g_miss_char,
6279: p_attribute14 => fnd_api.g_miss_char,
6280: p_attribute15 => fnd_api.g_miss_char,
6281: p_created_by => fnd_api.g_miss_num,
6282: p_creation_date => fnd_api.g_miss_date,
6283: p_last_updated_by => fnd_global.user_id,
6284: p_last_update_date => l_sysdate,
6285: p_last_update_login => fnd_global.conc_login_id,
6286: p_object_version_number => fnd_api.g_miss_num);

Line 6286: p_object_version_number => fnd_api.g_miss_num);

6282: p_creation_date => fnd_api.g_miss_date,
6283: p_last_updated_by => fnd_global.user_id,
6284: p_last_update_date => l_sysdate,
6285: p_last_update_login => fnd_global.conc_login_id,
6286: p_object_version_number => fnd_api.g_miss_num);
6287:
6288:
6289: csi_transactions_pvt.create_transaction
6290: (

Line 6302: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

6298: ,x_msg_count => x_msg_count
6299: ,x_msg_data => x_msg_data
6300: );
6301:
6302: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6303: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
6304: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
6305: fnd_msg_pub.add;
6306: RAISE fnd_api.g_exc_error;

Line 6306: RAISE fnd_api.g_exc_error;

6302: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6303: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
6304: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
6305: fnd_msg_pub.add;
6306: RAISE fnd_api.g_exc_error;
6307: ROLLBACK TO create_relationship_pvt;
6308: END IF;
6309:
6310: l_instance_rec:=l_temp_ins_rec;

Line 6341: ,p_called_from_rel => fnd_api.g_true

6337: ,p_location_tbl => l_location_tbl
6338: ,p_generic_id_tbl => l_generic_id_tbl
6339: ,p_lookup_tbl => l_lookup_tbl
6340: ,p_ins_count_rec => l_ins_count_rec
6341: ,p_called_from_rel => fnd_api.g_true
6342: ,p_oks_txn_inst_tbl => px_oks_txn_inst_tbl
6343: ,p_child_inst_tbl => px_child_inst_tbl
6344: );
6345:

Line 6347: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

6343: ,p_child_inst_tbl => px_child_inst_tbl
6344: );
6345:
6346:
6347: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6348: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6349: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6350: fnd_msg_pub.add;
6351: RAISE fnd_api.g_exc_error;

Line 6351: RAISE fnd_api.g_exc_error;

6347: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6348: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6349: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6350: fnd_msg_pub.add;
6351: RAISE fnd_api.g_exc_error;
6352: END IF;
6353: END IF;
6354:
6355: -- End Addition by sk for bug 2151750

Line 6396: IF x_return_status <> fnd_api.g_ret_sts_success THEN

6392: );
6393:
6394:
6395:
6396: IF x_return_status <> fnd_api.g_ret_sts_success THEN
6397: RAISE fnd_api.g_exc_error;
6398: END IF;
6399:
6400: -- standard check for p_commit

Line 6397: RAISE fnd_api.g_exc_error;

6393:
6394:
6395:
6396: IF x_return_status <> fnd_api.g_ret_sts_success THEN
6397: RAISE fnd_api.g_exc_error;
6398: END IF;
6399:
6400: -- standard check for p_commit
6401: IF fnd_api.to_boolean( p_commit )

Line 6401: IF fnd_api.to_boolean( p_commit )

6397: RAISE fnd_api.g_exc_error;
6398: END IF;
6399:
6400: -- standard check for p_commit
6401: IF fnd_api.to_boolean( p_commit )
6402: THEN
6403: COMMIT WORK;
6404: END IF;
6405:

Line 6413: WHEN fnd_api.g_exc_error THEN

6409: p_data => x_msg_data
6410: );
6411:
6412: EXCEPTION
6413: WHEN fnd_api.g_exc_error THEN
6414: ROLLBACK TO expire_relationship_pvt;
6415: x_return_status := fnd_api.g_ret_sts_error ;
6416: fnd_msg_pub.count_AND_get
6417: (p_count => x_msg_count ,

Line 6415: x_return_status := fnd_api.g_ret_sts_error ;

6411:
6412: EXCEPTION
6413: WHEN fnd_api.g_exc_error THEN
6414: ROLLBACK TO expire_relationship_pvt;
6415: x_return_status := fnd_api.g_ret_sts_error ;
6416: fnd_msg_pub.count_AND_get
6417: (p_count => x_msg_count ,
6418: p_data => x_msg_data
6419: );

Line 6421: WHEN fnd_api.g_exc_unexpected_error THEN

6417: (p_count => x_msg_count ,
6418: p_data => x_msg_data
6419: );
6420:
6421: WHEN fnd_api.g_exc_unexpected_error THEN
6422: ROLLBACK TO expire_relationship_pvt;
6423: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6424: fnd_msg_pub.count_AND_get
6425: (p_count => x_msg_count ,

Line 6423: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6419: );
6420:
6421: WHEN fnd_api.g_exc_unexpected_error THEN
6422: ROLLBACK TO expire_relationship_pvt;
6423: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6424: fnd_msg_pub.count_AND_get
6425: (p_count => x_msg_count ,
6426: p_data => x_msg_data
6427: );

Line 6431: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6427: );
6428:
6429: WHEN OTHERS THEN
6430: ROLLBACK TO expire_relationship_pvt;
6431: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6432: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6433: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
6434: END IF;
6435: fnd_msg_pub.count_AND_get

Line 6455: IF fnd_api.to_boolean( p_init_msg_list )

6451: l_dummy VARCHAR2(1);
6452: BEGIN
6453:
6454: -- initialize message list IF p_init_msg_list IS set TO true.
6455: IF fnd_api.to_boolean( p_init_msg_list )
6456: THEN
6457: fnd_msg_pub.initialize;
6458: END IF;
6459:

Line 6462: x_return_status := fnd_api.g_ret_sts_success;

6458: END IF;
6459:
6460:
6461: -- initialize api return status to success
6462: x_return_status := fnd_api.g_ret_sts_success;
6463: IF(p_validation_mode ='CREATE') THEN
6464: -- validate not null column
6465: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) )
6466: /* if p_relationship_id is not null check if it already exists if found return success else error*/

Line 6465: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) )

6461: -- initialize api return status to success
6462: x_return_status := fnd_api.g_ret_sts_success;
6463: IF(p_validation_mode ='CREATE') THEN
6464: -- validate not null column
6465: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) )
6466: /* if p_relationship_id is not null check if it already exists if found return success else error*/
6467: THEN
6468: BEGIN
6469: SELECT 'x'

Line 6477: x_return_status := fnd_api.g_ret_sts_error;

6473: AND ROWNUM=1;
6474: fnd_message.set_name('CSI','CSI_INVALID_RELSHIPID');
6475: fnd_message.set_token('relationship_id',p_relationship_id);
6476: fnd_msg_pub.add;
6477: x_return_status := fnd_api.g_ret_sts_error;
6478: EXCEPTION
6479: WHEN NO_DATA_FOUND THEN
6480: x_return_status := fnd_api.g_ret_sts_success;
6481:

Line 6480: x_return_status := fnd_api.g_ret_sts_success;

6476: fnd_msg_pub.add;
6477: x_return_status := fnd_api.g_ret_sts_error;
6478: EXCEPTION
6479: WHEN NO_DATA_FOUND THEN
6480: x_return_status := fnd_api.g_ret_sts_success;
6481:
6482: END;
6483:
6484: ELSE

Line 6486: x_return_status := fnd_api.g_ret_sts_success;

6482: END;
6483:
6484: ELSE
6485: /* if p_relationship_id is null then return success */
6486: x_return_status := fnd_api.g_ret_sts_success;
6487: END IF;
6488: ELSIF ( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
6489: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) ) THEN
6490: BEGIN

Line 6489: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) ) THEN

6485: /* if p_relationship_id is null then return success */
6486: x_return_status := fnd_api.g_ret_sts_success;
6487: END IF;
6488: ELSIF ( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
6489: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) ) THEN
6490: BEGIN
6491: /* Added the condition 'AND ACTIVE_END_DATE IS NULL' to avoid updating expired relationship */
6492: SELECT 'x'
6493: INTO l_dummy

Line 6500: x_return_status := fnd_api.g_ret_sts_success;

6496: -- AND ( ACTIVE_END_DATE IS NULL
6497: -- OR ACTIVE_END_DATE >SYSDATE)
6498: -- AND ROWNUM=1;
6499: -- IF SQL%FOUND THEN
6500: x_return_status := fnd_api.g_ret_sts_success;
6501: -- END IF;
6502: EXCEPTION
6503: WHEN NO_DATA_FOUND THEN
6504: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIPID');

Line 6506: x_return_status := fnd_api.g_ret_sts_error;

6502: EXCEPTION
6503: WHEN NO_DATA_FOUND THEN
6504: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIPID');
6505: fnd_msg_pub.add;
6506: x_return_status := fnd_api.g_ret_sts_error;
6507: END;
6508: ELSE
6509: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_ID_PASSED');
6510: fnd_msg_pub.add;

Line 6511: x_return_status := fnd_api.g_ret_sts_error;

6507: END;
6508: ELSE
6509: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_ID_PASSED');
6510: fnd_msg_pub.add;
6511: x_return_status := fnd_api.g_ret_sts_error;
6512: END IF;
6513: END IF;
6514:
6515:

Line 6538: IF fnd_api.to_boolean( p_init_msg_list )

6534: IS
6535: l_dummy VARCHAR2(1);
6536: BEGIN
6537: -- initialize message list if p_init_msg_list is set to true.
6538: IF fnd_api.to_boolean( p_init_msg_list )
6539: THEN
6540: fnd_msg_pub.initialize;
6541: END IF;
6542:

Line 6544: x_return_status := fnd_api.g_ret_sts_success;

6540: fnd_msg_pub.initialize;
6541: END IF;
6542:
6543: -- initialize api return status to success
6544: x_return_status := fnd_api.g_ret_sts_success;
6545: IF(p_validation_mode ='CREATE')
6546: THEN
6547: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN
6548: BEGIN

Line 6547: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN

6543: -- initialize api return status to success
6544: x_return_status := fnd_api.g_ret_sts_success;
6545: IF(p_validation_mode ='CREATE')
6546: THEN
6547: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN
6548: BEGIN
6549: SELECT 'x'
6550: INTO l_dummy
6551: FROM csi_ii_relation_types

Line 6555: x_return_status := fnd_api.g_ret_sts_success;

6551: FROM csi_ii_relation_types
6552: WHERE relationship_type_code=p_relationship_type_code;
6553:
6554: IF SQL%FOUND THEN
6555: x_return_status := fnd_api.g_ret_sts_success;
6556: END IF;
6557:
6558: EXCEPTION
6559: WHEN NO_DATA_FOUND THEN

Line 6563: x_return_status := fnd_api.g_ret_sts_error;

6559: WHEN NO_DATA_FOUND THEN
6560: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIP_CODE');
6561: fnd_message.set_token('relationship_type_code',p_relationship_type_code);
6562: fnd_msg_pub.add;
6563: x_return_status := fnd_api.g_ret_sts_error;
6564: END;
6565: ELSE
6566: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');
6567: --fnd_message.set_token('relationship_type_code',p_relationship_type_code);

Line 6569: x_return_status := fnd_api.g_ret_sts_error;

6565: ELSE
6566: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');
6567: --fnd_message.set_token('relationship_type_code',p_relationship_type_code);
6568: fnd_msg_pub.add;
6569: x_return_status := fnd_api.g_ret_sts_error;
6570:
6571: END IF;
6572: ELSIF(p_validation_mode ='UPDATE')
6573: THEN

Line 6574: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN

6570:
6571: END IF;
6572: ELSIF(p_validation_mode ='UPDATE')
6573: THEN
6574: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN
6575: BEGIN
6576: SELECT 'x'
6577: INTO l_dummy
6578: FROM csi_ii_relation_types

Line 6581: x_return_status := fnd_api.g_ret_sts_success;

6577: INTO l_dummy
6578: FROM csi_ii_relation_types
6579: WHERE relationship_type_code=p_relationship_type_code;
6580: IF SQL%FOUND THEN
6581: x_return_status := fnd_api.g_ret_sts_success;
6582: END IF;
6583: EXCEPTION
6584: WHEN NO_DATA_FOUND THEN
6585: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIP_CODE');

Line 6588: x_return_status := fnd_api.g_ret_sts_error;

6584: WHEN NO_DATA_FOUND THEN
6585: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIP_CODE');
6586: fnd_message.set_token('relationship_type_code',p_relationship_type_code);
6587: fnd_msg_pub.add;
6588: x_return_status := fnd_api.g_ret_sts_error;
6589: END;
6590: ELSIF p_relationship_type_code IS NULL -- Added for bug 2151750
6591: THEN
6592: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');

Line 6594: x_return_status := fnd_api.g_ret_sts_error;

6590: ELSIF p_relationship_type_code IS NULL -- Added for bug 2151750
6591: THEN
6592: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');
6593: fnd_msg_pub.add;
6594: x_return_status := fnd_api.g_ret_sts_error;
6595: END IF;
6596: END IF;
6597: -- standard call to get message count and if count is 1, get message info.
6598: fnd_msg_pub.count_AND_get

Line 6631: IF fnd_api.to_boolean( p_init_msg_list )

6627: l_active VARCHAR2(1);
6628: BEGIN
6629:
6630: -- initialize message list if p_init_msg_list is set to true.
6631: IF fnd_api.to_boolean( p_init_msg_list )
6632: THEN
6633: fnd_msg_pub.initialize;
6634: END IF;
6635:

Line 6638: x_return_status := fnd_api.g_ret_sts_success;

6634: END IF;
6635:
6636:
6637: -- initialize api return status to success
6638: x_return_status := fnd_api.g_ret_sts_success;
6639:
6640: -- validate not null column
6641: IF(p_validation_mode ='CREATE')
6642: THEN

Line 6643: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN

6639:
6640: -- validate not null column
6641: IF(p_validation_mode ='CREATE')
6642: THEN
6643: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN
6644: -- The following code has been added by sguthiva for bug 2416144.
6645: BEGIN
6646: SELECT 'x'
6647: INTO l_active

Line 6656: x_return_status := fnd_api.g_ret_sts_error;

6652: WHEN NO_DATA_FOUND THEN
6653: fnd_message.set_name('CSI', 'CSI_EXPIRED_OBJECT');
6654: fnd_message.set_token('object_id',p_object_id);
6655: fnd_msg_pub.add;
6656: x_return_status := fnd_api.g_ret_sts_error;
6657: RAISE fnd_api.g_exc_error;
6658: END;
6659: -- End of addition for bug 2416144.
6660:

Line 6657: RAISE fnd_api.g_exc_error;

6653: fnd_message.set_name('CSI', 'CSI_EXPIRED_OBJECT');
6654: fnd_message.set_token('object_id',p_object_id);
6655: fnd_msg_pub.add;
6656: x_return_status := fnd_api.g_ret_sts_error;
6657: RAISE fnd_api.g_exc_error;
6658: END;
6659: -- End of addition for bug 2416144.
6660:
6661: BEGIN

Line 6680: x_return_status := fnd_api.g_ret_sts_error;

6676: IF l_quantity<>1 THEN
6677: fnd_message.set_name('CSI', 'CSI_QTY_NOTEQUAL_TO_ONE');
6678: fnd_message.set_token('object_id',p_object_id);
6679: fnd_msg_pub.add;
6680: x_return_status := fnd_api.g_ret_sts_error;
6681: END IF;
6682: END IF;
6683: /* commented by sk for bug 2151750
6684: IF l_location_type_code IS NOT NULL THEN

Line 6689: x_return_status := fnd_api.g_ret_sts_error;

6685: IF UPPER(l_location_type_code) = 'INVENTORY' THEN
6686: fnd_message.set_name('CSI', 'CSI_INVALID_LOCATION_TYPE');
6687: fnd_message.set_token('object_id',p_object_id);
6688: fnd_msg_pub.add;
6689: x_return_status := fnd_api.g_ret_sts_error;
6690: END IF;
6691: END IF;
6692: */
6693: BEGIN

Line 6735: x_return_status := fnd_api.g_ret_sts_error;

6731: ELSE
6732: fnd_message.set_name('CSI', 'CSI_NON_ATO_PTO_ITEM');
6733: fnd_message.set_token('object_id',p_object_id);
6734: fnd_msg_pub.add;
6735: x_return_status := fnd_api.g_ret_sts_error;
6736: END IF;
6737:
6738: EXCEPTION
6739: WHEN OTHERS THEN

Line 6747: x_return_status := fnd_api.g_ret_sts_error;

6743: WHEN NO_DATA_FOUND THEN
6744: fnd_message.set_name('CSI', 'CSI_INVALID_OBJECT_ID');
6745: fnd_message.set_token('object_id',p_object_id);
6746: fnd_msg_pub.add;
6747: x_return_status := fnd_api.g_ret_sts_error;
6748: END;
6749: ELSE
6750: fnd_message.set_name('CSI', 'CSI_NO_OBJ_ID_PASSED');
6751: fnd_msg_pub.add;

Line 6752: x_return_status := fnd_api.g_ret_sts_error;

6748: END;
6749: ELSE
6750: fnd_message.set_name('CSI', 'CSI_NO_OBJ_ID_PASSED');
6751: fnd_msg_pub.add;
6752: x_return_status := fnd_api.g_ret_sts_error;
6753: END IF;
6754:
6755: ELSIF(p_validation_mode ='UPDATE')
6756: THEN

Line 6757: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN

6753: END IF;
6754:
6755: ELSIF(p_validation_mode ='UPDATE')
6756: THEN
6757: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN
6758: BEGIN
6759: -- Modified by sk for bug 2266166
6760: SELECT instance_id
6761: ,quantity

Line 6778: x_return_status := fnd_api.g_ret_sts_error;

6774: IF l_quantity<>1 THEN
6775: fnd_message.set_name('CSI', 'CSI_QTY_NOTEQUAL_TO_ONE');
6776: fnd_message.set_token('object_id',p_object_id);
6777: fnd_msg_pub.add;
6778: x_return_status := fnd_api.g_ret_sts_error;
6779: END IF;
6780: END IF;
6781: /* commented by sk for bug 2151750
6782: IF l_location_type_code IS NOT NULL THEN

Line 6787: x_return_status := fnd_api.g_ret_sts_error;

6783: IF UPPER(l_location_type_code) = 'INVENTORY' THEN
6784: fnd_message.set_name('CSI', 'CSI_INVALID_LOCATION_TYPE');
6785: fnd_message.set_token('object_id',p_object_id);
6786: fnd_msg_pub.add;
6787: x_return_status := fnd_api.g_ret_sts_error;
6788: END IF;
6789: END IF;
6790: */
6791: BEGIN

Line 6833: x_return_status := fnd_api.g_ret_sts_error;

6829: ELSE
6830: fnd_message.set_name('CSI', 'CSI_NON_ATO_PTO_ITEM');
6831: fnd_message.set_token('object_id',p_object_id);
6832: fnd_msg_pub.add;
6833: x_return_status := fnd_api.g_ret_sts_error;
6834: END IF;
6835:
6836: EXCEPTION
6837: WHEN OTHERS THEN

Line 6846: x_return_status := fnd_api.g_ret_sts_error;

6842: WHEN NO_DATA_FOUND THEN
6843: fnd_message.set_name('CSI', 'CSI_INVALID_OBJECT_ID');
6844: fnd_message.set_token('object_id',p_object_id);
6845: fnd_msg_pub.add;
6846: x_return_status := fnd_api.g_ret_sts_error;
6847: END;
6848: END IF;
6849: END IF;
6850:

Line 6877: IF fnd_api.to_boolean( p_init_msg_list )

6873: l_active VARCHAR2(1);
6874: BEGIN
6875:
6876: -- initialize message list if p_init_msg_list is set to true.
6877: IF fnd_api.to_boolean( p_init_msg_list )
6878: THEN
6879: fnd_msg_pub.initialize;
6880: END IF;
6881:

Line 6884: x_return_status := fnd_api.g_ret_sts_success;

6880: END IF;
6881:
6882:
6883: -- initialize API RETURN status TO success
6884: x_return_status := fnd_api.g_ret_sts_success;
6885:
6886: IF ((p_subject_id IS NOT NULL) AND (p_subject_id <> fnd_api.g_miss_num)) THEN
6887: -- The following code has been added by sguthiva for bug 2416144.
6888: IF (p_validation_mode ='CREATE')

Line 6886: IF ((p_subject_id IS NOT NULL) AND (p_subject_id <> fnd_api.g_miss_num)) THEN

6882:
6883: -- initialize API RETURN status TO success
6884: x_return_status := fnd_api.g_ret_sts_success;
6885:
6886: IF ((p_subject_id IS NOT NULL) AND (p_subject_id <> fnd_api.g_miss_num)) THEN
6887: -- The following code has been added by sguthiva for bug 2416144.
6888: IF (p_validation_mode ='CREATE')
6889: THEN
6890: BEGIN

Line 6901: x_return_status := fnd_api.g_ret_sts_error;

6897: WHEN NO_DATA_FOUND THEN
6898: fnd_message.set_name('CSI', 'CSI_EXPIRED_SUBJECT');
6899: fnd_message.set_token('subject_id',p_subject_id);
6900: fnd_msg_pub.add;
6901: x_return_status := fnd_api.g_ret_sts_error;
6902: RAISE fnd_api.g_exc_error;
6903: END;
6904: END IF;
6905: -- End of addition for bug 2416144.

Line 6902: RAISE fnd_api.g_exc_error;

6898: fnd_message.set_name('CSI', 'CSI_EXPIRED_SUBJECT');
6899: fnd_message.set_token('subject_id',p_subject_id);
6900: fnd_msg_pub.add;
6901: x_return_status := fnd_api.g_ret_sts_error;
6902: RAISE fnd_api.g_exc_error;
6903: END;
6904: END IF;
6905: -- End of addition for bug 2416144.
6906: BEGIN

Line 6917: x_return_status := fnd_api.g_ret_sts_error;

6913: IF UPPER(l_location_type_code) = 'INVENTORY' THEN
6914: fnd_message.set_name('CSI', 'CSI_INVALID_LOCATION_TYPE');
6915: fnd_message.set_token('subject_id',p_subject_id);
6916: fnd_msg_pub.add;
6917: x_return_status := fnd_api.g_ret_sts_error;
6918: END IF;
6919: END IF;
6920: */
6921: EXCEPTION

Line 6926: x_return_status := fnd_api.g_ret_sts_error;

6922: WHEN NO_DATA_FOUND THEN
6923: fnd_message.set_name('CSI', 'CSI_INVALID_SUBJECT_ID');
6924: fnd_message.set_token('subject_id',p_subject_id);
6925: fnd_msg_pub.add;
6926: x_return_status := fnd_api.g_ret_sts_error;
6927: END;
6928: END IF;
6929: -- standard call to get message count and if count is 1, get message info.
6930: fnd_msg_pub.count_AND_get

Line 6948: IF fnd_api.to_boolean( p_init_msg_list )

6944: )
6945: IS
6946: BEGIN
6947: -- initialize message list if p_init_msg_list is set to true.
6948: IF fnd_api.to_boolean( p_init_msg_list )
6949: THEN
6950: fnd_msg_pub.initialize;
6951: END IF;
6952:

Line 6955: x_return_status := fnd_api.g_ret_sts_success;

6951: END IF;
6952:
6953:
6954: -- initialize api return status to success
6955: x_return_status := fnd_api.g_ret_sts_success;
6956: IF(p_validation_mode ='CREATE') THEN
6957: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN
6958: fnd_message.set_name('CSI', 'CSI_ACTIVE_END_DATE');
6959: fnd_message.set_token('ACTIVE_END_DATE',p_active_end_date);

Line 6957: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN

6953:
6954: -- initialize api return status to success
6955: x_return_status := fnd_api.g_ret_sts_success;
6956: IF(p_validation_mode ='CREATE') THEN
6957: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN
6958: fnd_message.set_name('CSI', 'CSI_ACTIVE_END_DATE');
6959: fnd_message.set_token('ACTIVE_END_DATE',p_active_end_date);
6960: fnd_msg_pub.add;
6961: x_return_status := fnd_api.g_ret_sts_error;

Line 6961: x_return_status := fnd_api.g_ret_sts_error;

6957: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN
6958: fnd_message.set_name('CSI', 'CSI_ACTIVE_END_DATE');
6959: fnd_message.set_token('ACTIVE_END_DATE',p_active_end_date);
6960: fnd_msg_pub.add;
6961: x_return_status := fnd_api.g_ret_sts_error;
6962: END IF;
6963: END IF;
6964: -- standard call to get message count and if count is 1, get message info.
6965: fnd_msg_pub.count_AND_get

Line 6986: IF fnd_api.to_boolean( p_init_msg_list )

6982: l_dummy VARCHAR2(1);
6983: BEGIN
6984:
6985: -- initialize message list if p_init_msg_list is set to true.
6986: IF fnd_api.to_boolean( p_init_msg_list )
6987: THEN
6988: fnd_msg_pub.initialize;
6989: END IF;
6990:

Line 6993: x_return_status := fnd_api.g_ret_sts_success;

6989: END IF;
6990:
6991:
6992: -- initialize api return status to success
6993: x_return_status := fnd_api.g_ret_sts_success;
6994:
6995: -- validate not null column
6996:
6997:

Line 6999: IF ( (p_object_version_number IS NULL) OR (p_object_version_number = fnd_api.g_miss_num) ) THEN

6995: -- validate not null column
6996:
6997:
6998: IF( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
6999: IF ( (p_object_version_number IS NULL) OR (p_object_version_number = fnd_api.g_miss_num) ) THEN
7000: fnd_message.set_name('CSI', 'CSI_MISSING_OBJ_VER_NUM');
7001: fnd_msg_pub.add;
7002: x_return_status := fnd_api.g_ret_sts_error;
7003: ELSE

Line 7002: x_return_status := fnd_api.g_ret_sts_error;

6998: IF( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
6999: IF ( (p_object_version_number IS NULL) OR (p_object_version_number = fnd_api.g_miss_num) ) THEN
7000: fnd_message.set_name('CSI', 'CSI_MISSING_OBJ_VER_NUM');
7001: fnd_msg_pub.add;
7002: x_return_status := fnd_api.g_ret_sts_error;
7003: ELSE
7004: x_return_status := fnd_api.g_ret_sts_success;
7005: END IF;
7006: END IF;

Line 7004: x_return_status := fnd_api.g_ret_sts_success;

7000: fnd_message.set_name('CSI', 'CSI_MISSING_OBJ_VER_NUM');
7001: fnd_msg_pub.add;
7002: x_return_status := fnd_api.g_ret_sts_error;
7003: ELSE
7004: x_return_status := fnd_api.g_ret_sts_success;
7005: END IF;
7006: END IF;
7007:
7008: -- standard call to get message count and if count is 1, get message info.

Line 7033: x_return_status := fnd_api.g_ret_sts_success;

7029:
7030:
7031:
7032: -- initialize api return status to success
7033: x_return_status := fnd_api.g_ret_sts_success;
7034:
7035: l_ct := p_ii_relationship_tbl.count;
7036: FOR l_count IN 1..l_ct LOOP
7037:

Line 7039: -- IF (p_validation_level >= fnd_api.g_valid_level_full) THEN

7035: l_ct := p_ii_relationship_tbl.count;
7036: FOR l_count IN 1..l_ct LOOP
7037:
7038: -- The following IF statement has been commented out for Bug: 3271806
7039: -- IF (p_validation_level >= fnd_api.g_valid_level_full) THEN
7040:
7041: validate_relationship_id(
7042: p_init_msg_list => fnd_api.g_false,
7043: p_validation_mode => p_validation_mode,

Line 7042: p_init_msg_list => fnd_api.g_false,

7038: -- The following IF statement has been commented out for Bug: 3271806
7039: -- IF (p_validation_level >= fnd_api.g_valid_level_full) THEN
7040:
7041: validate_relationship_id(
7042: p_init_msg_list => fnd_api.g_false,
7043: p_validation_mode => p_validation_mode,
7044: p_relationship_id => p_ii_relationship_tbl(l_count).relationship_id,
7045: x_return_status => x_return_status,
7046: x_msg_count => x_msg_count,

Line 7048: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7044: p_relationship_id => p_ii_relationship_tbl(l_count).relationship_id,
7045: x_return_status => x_return_status,
7046: x_msg_count => x_msg_count,
7047: x_msg_data => x_msg_data);
7048: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7049: RAISE fnd_api.g_exc_error;
7050: END IF;
7051:
7052: validate_rel_type_code(

Line 7049: RAISE fnd_api.g_exc_error;

7045: x_return_status => x_return_status,
7046: x_msg_count => x_msg_count,
7047: x_msg_data => x_msg_data);
7048: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7049: RAISE fnd_api.g_exc_error;
7050: END IF;
7051:
7052: validate_rel_type_code(
7053: p_init_msg_list => fnd_api.g_false,

Line 7053: p_init_msg_list => fnd_api.g_false,

7049: RAISE fnd_api.g_exc_error;
7050: END IF;
7051:
7052: validate_rel_type_code(
7053: p_init_msg_list => fnd_api.g_false,
7054: p_validation_mode => p_validation_mode,
7055: p_relationship_type_code => p_ii_relationship_tbl(l_count).relationship_type_code,
7056: x_return_status => x_return_status,
7057: x_msg_count => x_msg_count,

Line 7059: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7055: p_relationship_type_code => p_ii_relationship_tbl(l_count).relationship_type_code,
7056: x_return_status => x_return_status,
7057: x_msg_count => x_msg_count,
7058: x_msg_data => x_msg_data);
7059: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7060: RAISE fnd_api.g_exc_error;
7061: END IF;
7062:
7063: validate_object_id(

Line 7060: RAISE fnd_api.g_exc_error;

7056: x_return_status => x_return_status,
7057: x_msg_count => x_msg_count,
7058: x_msg_data => x_msg_data);
7059: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7060: RAISE fnd_api.g_exc_error;
7061: END IF;
7062:
7063: validate_object_id(
7064: p_init_msg_list => fnd_api.g_false,

Line 7064: p_init_msg_list => fnd_api.g_false,

7060: RAISE fnd_api.g_exc_error;
7061: END IF;
7062:
7063: validate_object_id(
7064: p_init_msg_list => fnd_api.g_false,
7065: p_validation_mode => p_validation_mode,
7066: p_object_id => p_ii_relationship_tbl(l_count).object_id,
7067: x_return_status => x_return_status,
7068: x_msg_count => x_msg_count,

Line 7070: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7066: p_object_id => p_ii_relationship_tbl(l_count).object_id,
7067: x_return_status => x_return_status,
7068: x_msg_count => x_msg_count,
7069: x_msg_data => x_msg_data);
7070: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7071: RAISE fnd_api.g_exc_error;
7072: END IF;
7073:
7074: validate_subject_id(

Line 7071: RAISE fnd_api.g_exc_error;

7067: x_return_status => x_return_status,
7068: x_msg_count => x_msg_count,
7069: x_msg_data => x_msg_data);
7070: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7071: RAISE fnd_api.g_exc_error;
7072: END IF;
7073:
7074: validate_subject_id(
7075: p_init_msg_list => fnd_api.g_false,

Line 7075: p_init_msg_list => fnd_api.g_false,

7071: RAISE fnd_api.g_exc_error;
7072: END IF;
7073:
7074: validate_subject_id(
7075: p_init_msg_list => fnd_api.g_false,
7076: p_validation_mode => p_validation_mode,
7077: p_subject_id => p_ii_relationship_tbl(l_count).subject_id,
7078: x_return_status => x_return_status,
7079: x_msg_count => x_msg_count,

Line 7081: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7077: p_subject_id => p_ii_relationship_tbl(l_count).subject_id,
7078: x_return_status => x_return_status,
7079: x_msg_count => x_msg_count,
7080: x_msg_data => x_msg_data);
7081: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7082: RAISE fnd_api.g_exc_error;
7083: END IF;
7084:
7085: validate_active_end_date(

Line 7082: RAISE fnd_api.g_exc_error;

7078: x_return_status => x_return_status,
7079: x_msg_count => x_msg_count,
7080: x_msg_data => x_msg_data);
7081: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7082: RAISE fnd_api.g_exc_error;
7083: END IF;
7084:
7085: validate_active_end_date(
7086: p_init_msg_list => fnd_api.g_false,

Line 7086: p_init_msg_list => fnd_api.g_false,

7082: RAISE fnd_api.g_exc_error;
7083: END IF;
7084:
7085: validate_active_end_date(
7086: p_init_msg_list => fnd_api.g_false,
7087: p_validation_mode => p_validation_mode,
7088: p_active_end_date => p_ii_relationship_tbl(l_count).active_end_date,
7089: x_return_status => x_return_status,
7090: x_msg_count => x_msg_count,

Line 7092: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7088: p_active_end_date => p_ii_relationship_tbl(l_count).active_end_date,
7089: x_return_status => x_return_status,
7090: x_msg_count => x_msg_count,
7091: x_msg_data => x_msg_data);
7092: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7093: RAISE fnd_api.g_exc_error;
7094: END IF;
7095:
7096: validate_object_version_num (

Line 7093: RAISE fnd_api.g_exc_error;

7089: x_return_status => x_return_status,
7090: x_msg_count => x_msg_count,
7091: x_msg_data => x_msg_data);
7092: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7093: RAISE fnd_api.g_exc_error;
7094: END IF;
7095:
7096: validate_object_version_num (
7097: p_init_msg_list => fnd_api.g_false,

Line 7097: p_init_msg_list => fnd_api.g_false,

7093: RAISE fnd_api.g_exc_error;
7094: END IF;
7095:
7096: validate_object_version_num (
7097: p_init_msg_list => fnd_api.g_false,
7098: p_validation_mode => p_validation_mode,
7099: p_object_version_number => p_ii_relationship_tbl(l_count).object_version_number,
7100: x_return_status => x_return_status,
7101: x_msg_count => x_msg_count,

Line 7104: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7100: x_return_status => x_return_status,
7101: x_msg_count => x_msg_count,
7102: x_msg_data => x_msg_data);
7103:
7104: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7105: RAISE fnd_api.g_exc_error;
7106: END IF;
7107:
7108: -- END IF;

Line 7105: RAISE fnd_api.g_exc_error;

7101: x_msg_count => x_msg_count,
7102: x_msg_data => x_msg_data);
7103:
7104: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7105: RAISE fnd_api.g_exc_error;
7106: END IF;
7107:
7108: -- END IF;
7109: END LOOP;

Line 7130: (p_rel_history_tbl(tab_row).relationship_type_code <> FND_API.G_MISS_CHAR) ) THEN

7126: FOR tab_row in p_rel_history_tbl.FIRST..p_rel_history_tbl.LAST
7127: LOOP
7128: IF p_rel_history_tbl.EXISTS(tab_row) THEN
7129: IF ( (p_rel_history_tbl(tab_row).relationship_type_code IS NOT NULL) AND
7130: (p_rel_history_tbl(tab_row).relationship_type_code <> FND_API.G_MISS_CHAR) ) THEN
7131: BEGIN
7132: SELECT name
7133: INTO p_rel_history_tbl(tab_row).relationship_type
7134: FROM csi_ii_relation_types

Line 7143: (p_rel_history_tbl(tab_row).OLD_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN

7139: END;
7140: END IF;
7141:
7142: IF ( (p_rel_history_tbl(tab_row).OLD_SUBJECT_ID IS NOT NULL) AND
7143: (p_rel_history_tbl(tab_row).OLD_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN
7144: BEGIN
7145: SELECT instance_number
7146: INTO p_rel_history_tbl(tab_row).old_subject_number
7147: FROM csi_item_instances

Line 7156: (p_rel_history_tbl(tab_row).NEW_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN

7152: END;
7153: END IF;
7154:
7155: IF ( (p_rel_history_tbl(tab_row).NEW_SUBJECT_ID IS NOT NULL) AND
7156: (p_rel_history_tbl(tab_row).NEW_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN
7157: BEGIN
7158: SELECT instance_number
7159: INTO p_rel_history_tbl(tab_row).new_subject_number
7160: FROM csi_item_instances

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

7177: /*------------------------------------------------------------*/
7178:
7179: PROCEDURE get_inst_relationship_hist
7180: ( p_api_version IN NUMBER
7181: ,p_commit IN VARCHAR2 := fnd_api.g_false
7182: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
7183: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
7184: ,p_transaction_id IN NUMBER
7185: ,x_rel_history_tbl OUT NOCOPY csi_datastructures_pub.relationship_history_tbl

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

7178:
7179: PROCEDURE get_inst_relationship_hist
7180: ( p_api_version IN NUMBER
7181: ,p_commit IN VARCHAR2 := fnd_api.g_false
7182: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
7183: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
7184: ,p_transaction_id IN NUMBER
7185: ,x_rel_history_tbl OUT NOCOPY csi_datastructures_pub.relationship_history_tbl
7186: ,x_return_status OUT NOCOPY VARCHAR2

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

7179: PROCEDURE get_inst_relationship_hist
7180: ( p_api_version IN NUMBER
7181: ,p_commit IN VARCHAR2 := fnd_api.g_false
7182: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
7183: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
7184: ,p_transaction_id IN NUMBER
7185: ,x_rel_history_tbl OUT NOCOPY csi_datastructures_pub.relationship_history_tbl
7186: ,x_return_status OUT NOCOPY VARCHAR2
7187: ,x_msg_count OUT NOCOPY NUMBER

Line 7263: IF NOT FND_API.Compatible_API_Call ( l_api_version ,

7259: -- Standard Start of API savepoint
7260: --SAVEPOINT get_inst_relationship_hist;
7261:
7262: -- Standard call to check for call compatibility.
7263: IF NOT FND_API.Compatible_API_Call ( l_api_version ,
7264: p_api_version ,
7265: l_api_name ,
7266: g_pkg_name )
7267: THEN

Line 7268: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

7264: p_api_version ,
7265: l_api_name ,
7266: g_pkg_name )
7267: THEN
7268: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
7269: END IF;
7270:
7271: -- Initialize message list if p_init_msg_list is set to TRUE.
7272: IF FND_API.to_Boolean( p_init_msg_list ) THEN

Line 7272: IF FND_API.to_Boolean( p_init_msg_list ) THEN

7268: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
7269: END IF;
7270:
7271: -- Initialize message list if p_init_msg_list is set to TRUE.
7272: IF FND_API.to_Boolean( p_init_msg_list ) THEN
7273: FND_MSG_PUB.initialize;
7274: END IF;
7275:
7276: -- Initialize API return status to success

Line 7277: x_return_status := FND_API.G_RET_STS_SUCCESS;

7273: FND_MSG_PUB.initialize;
7274: END IF;
7275:
7276: -- Initialize API return status to success
7277: x_return_status := FND_API.G_RET_STS_SUCCESS;
7278:
7279: -- Check the profile option CSI_DEBUG_LEVEL for debug message reporting
7280: l_csi_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
7281:

Line 7362: OR (x_rel_history_tbl(i).new_subject_id = FND_API.G_MISS_NUM)

7358:
7359:
7360: IF (
7361: (x_rel_history_tbl(i).new_subject_id IS NULL)
7362: OR (x_rel_history_tbl(i).new_subject_id = FND_API.G_MISS_NUM)
7363: )
7364: THEN
7365:
7366: l_relationship_query_rec.relationship_id := x_rel_history_tbl(i).relationship_id;

Line 7372: p_commit => fnd_api.g_false,

7368:
7369: get_relationships
7370: (
7371: p_api_version => 1.0,
7372: p_commit => fnd_api.g_false,
7373: p_init_msg_list => fnd_api.g_false,
7374: p_validation_level => fnd_api.g_valid_level_full,
7375: p_relationship_query_rec => l_relationship_query_rec,
7376: p_depth => NULL,

Line 7373: p_init_msg_list => fnd_api.g_false,

7369: get_relationships
7370: (
7371: p_api_version => 1.0,
7372: p_commit => fnd_api.g_false,
7373: p_init_msg_list => fnd_api.g_false,
7374: p_validation_level => fnd_api.g_valid_level_full,
7375: p_relationship_query_rec => l_relationship_query_rec,
7376: p_depth => NULL,
7377: p_time_stamp => l_time_stamp,

Line 7374: p_validation_level => fnd_api.g_valid_level_full,

7370: (
7371: p_api_version => 1.0,
7372: p_commit => fnd_api.g_false,
7373: p_init_msg_list => fnd_api.g_false,
7374: p_validation_level => fnd_api.g_valid_level_full,
7375: p_relationship_query_rec => l_relationship_query_rec,
7376: p_depth => NULL,
7377: p_time_stamp => l_time_stamp,
7378: p_active_relationship_only => fnd_api.g_false,

Line 7378: p_active_relationship_only => fnd_api.g_false,

7374: p_validation_level => fnd_api.g_valid_level_full,
7375: p_relationship_query_rec => l_relationship_query_rec,
7376: p_depth => NULL,
7377: p_time_stamp => l_time_stamp,
7378: p_active_relationship_only => fnd_api.g_false,
7379: x_relationship_tbl => l_ii_relationship_tbl,
7380: x_return_status => x_return_status,
7381: x_msg_count => x_msg_count,
7382: x_msg_data => x_msg_data

Line 7385: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN

7381: x_msg_count => x_msg_count,
7382: x_msg_data => x_msg_data
7383: );
7384:
7385: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
7386: RAISE fnd_api.g_exc_error;
7387: END IF;
7388: --
7389: IF l_ii_relationship_tbl.count > 0 THEN

Line 7386: RAISE fnd_api.g_exc_error;

7382: x_msg_data => x_msg_data
7383: );
7384:
7385: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
7386: RAISE fnd_api.g_exc_error;
7387: END IF;
7388: --
7389: IF l_ii_relationship_tbl.count > 0 THEN
7390: x_rel_history_tbl(i).new_subject_id := l_ii_relationship_tbl(1).subject_id;

Line 7408: IF FND_API.To_Boolean( p_commit ) THEN

7404: -- End of API body
7405:
7406: -- Standard check of p_commit.
7407: /*
7408: IF FND_API.To_Boolean( p_commit ) THEN
7409: COMMIT WORK;
7410: END IF;
7411: */
7412:

Line 7428: WHEN FND_API.G_EXC_ERROR THEN

7424: p_data => x_msg_data );
7425:
7426: EXCEPTION
7427:
7428: WHEN FND_API.G_EXC_ERROR THEN
7429: -- ROLLBACK TO get_inst_relationship_hist;
7430: x_return_status := FND_API.G_RET_STS_ERROR ;
7431: FND_MSG_PUB.Count_And_Get
7432: ( p_count => x_msg_count,

Line 7430: x_return_status := FND_API.G_RET_STS_ERROR ;

7426: EXCEPTION
7427:
7428: WHEN FND_API.G_EXC_ERROR THEN
7429: -- ROLLBACK TO get_inst_relationship_hist;
7430: x_return_status := FND_API.G_RET_STS_ERROR ;
7431: FND_MSG_PUB.Count_And_Get
7432: ( p_count => x_msg_count,
7433: p_data => x_msg_data );
7434: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

Line 7434: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

7430: x_return_status := FND_API.G_RET_STS_ERROR ;
7431: FND_MSG_PUB.Count_And_Get
7432: ( p_count => x_msg_count,
7433: p_data => x_msg_data );
7434: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7435: -- ROLLBACK TO get_inst_relationship_hist;
7436: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7437: FND_MSG_PUB.Count_And_Get
7438: ( p_count => x_msg_count,

Line 7436: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

7432: ( p_count => x_msg_count,
7433: p_data => x_msg_data );
7434: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7435: -- ROLLBACK TO get_inst_relationship_hist;
7436: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7437: FND_MSG_PUB.Count_And_Get
7438: ( p_count => x_msg_count,
7439: p_data => x_msg_data );
7440: WHEN OTHERS THEN

Line 7442: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

7438: ( p_count => x_msg_count,
7439: p_data => x_msg_data );
7440: WHEN OTHERS THEN
7441: -- ROLLBACK TO get_inst_relationship_hist;
7442: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7443: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
7444: FND_MSG_PUB.Add_Exc_Msg
7445: ( g_pkg_name ,
7446: l_api_name );

Line 7494: x_return_status := fnd_api.g_ret_sts_success;

7490: l_rel_color_ctr NUMBER := 0;
7491: --
7492: COMP_ERROR EXCEPTION;
7493: BEGIN
7494: x_return_status := fnd_api.g_ret_sts_success;
7495: p_cyclic_node := NULL;
7496: l_instance_id := p_instance_id;
7497: --
7498: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');

Line 7505: p_commit => fnd_api.g_false,

7501: END IF;
7502: --
7503: csi_ii_relationships_pvt.get_cyclic_relationships(
7504: p_api_version => 1.0,
7505: p_commit => fnd_api.g_false,
7506: p_init_msg_list => fnd_api.g_true,
7507: p_validation_level => fnd_api.g_valid_level_full,
7508: p_instance_id => l_instance_id,
7509: p_depth => NULL ,

Line 7506: p_init_msg_list => fnd_api.g_true,

7502: --
7503: csi_ii_relationships_pvt.get_cyclic_relationships(
7504: p_api_version => 1.0,
7505: p_commit => fnd_api.g_false,
7506: p_init_msg_list => fnd_api.g_true,
7507: p_validation_level => fnd_api.g_valid_level_full,
7508: p_instance_id => l_instance_id,
7509: p_depth => NULL ,
7510: p_time_stamp => fnd_api.g_miss_date,

Line 7507: p_validation_level => fnd_api.g_valid_level_full,

7503: csi_ii_relationships_pvt.get_cyclic_relationships(
7504: p_api_version => 1.0,
7505: p_commit => fnd_api.g_false,
7506: p_init_msg_list => fnd_api.g_true,
7507: p_validation_level => fnd_api.g_valid_level_full,
7508: p_instance_id => l_instance_id,
7509: p_depth => NULL ,
7510: p_time_stamp => fnd_api.g_miss_date,
7511: p_active_relationship_only => fnd_api.g_true,

Line 7510: p_time_stamp => fnd_api.g_miss_date,

7506: p_init_msg_list => fnd_api.g_true,
7507: p_validation_level => fnd_api.g_valid_level_full,
7508: p_instance_id => l_instance_id,
7509: p_depth => NULL ,
7510: p_time_stamp => fnd_api.g_miss_date,
7511: p_active_relationship_only => fnd_api.g_true,
7512: x_relationship_tbl => p_rel_tbl,
7513: x_return_status => x_return_status,
7514: x_msg_count => x_msg_count,

Line 7511: p_active_relationship_only => fnd_api.g_true,

7507: p_validation_level => fnd_api.g_valid_level_full,
7508: p_instance_id => l_instance_id,
7509: p_depth => NULL ,
7510: p_time_stamp => fnd_api.g_miss_date,
7511: p_active_relationship_only => fnd_api.g_true,
7512: x_relationship_tbl => p_rel_tbl,
7513: x_return_status => x_return_status,
7514: x_msg_count => x_msg_count,
7515: x_msg_data => x_msg_data

Line 7518: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN

7514: x_msg_count => x_msg_count,
7515: x_msg_data => x_msg_data
7516: );
7517: --
7518: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
7519: l_msg_index := 1;
7520: l_msg_count := x_msg_count;
7521: WHILE l_msg_count > 0 LOOP
7522: x_msg_data := FND_MSG_PUB.GET

Line 7524: FND_API.G_FALSE );

7520: l_msg_count := x_msg_count;
7521: WHILE l_msg_count > 0 LOOP
7522: x_msg_data := FND_MSG_PUB.GET
7523: ( l_msg_index,
7524: FND_API.G_FALSE );
7525: csi_gen_utility_pvt.put_line( ' Error from Get_cyclic_relationships.. ');
7526: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
7527: l_msg_index := l_msg_index + 1;
7528: l_msg_count := l_msg_count - 1;

Line 7530: RAISE FND_API.G_EXC_ERROR;

7526: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
7527: l_msg_index := l_msg_index + 1;
7528: l_msg_count := l_msg_count - 1;
7529: END LOOP;
7530: RAISE FND_API.G_EXC_ERROR;
7531: END IF;
7532: --
7533: csi_gen_utility_pvt.put_line('p_rel_tbl count after get_cyclic_relationships is '
7534: ||to_char(p_rel_tbl.count));

Line 7606: IF nvl(p_stop_at_cyclic,fnd_api.g_true) = fnd_api.g_true THEN

7602: FOR color_rec in l_rel_color_tbl.FIRST .. l_rel_color_tbl.LAST LOOP
7603: IF l_rel_color_tbl(color_rec).node_id = l_temp_id AND -- adjacent node
7604: l_rel_color_tbl(color_rec).color_code = 'R' THEN
7605: p_cyclic_node := l_temp_id;
7606: IF nvl(p_stop_at_cyclic,fnd_api.g_true) = fnd_api.g_true THEN
7607: csi_gen_utility_pvt.put_line('Cycle exists at '||to_char(p_cyclic_node));
7608: Raise COMP_ERROR;
7609: END IF;
7610: END IF;

Line 7653: Raise FND_API.G_EXC_UNEXPECTED_ERROR;

7649: --
7650: csi_gen_utility_pvt.put_line('Adjacent Node is '||l_temp_id);
7651: IF l_temp_id = -9999 THEN
7652: csi_gen_utility_pvt.put_line('Unable to get the Adjacent Node.. Exiting...');
7653: Raise FND_API.G_EXC_UNEXPECTED_ERROR;
7654: END IF;
7655: END IF; -- l_found = 0 check
7656: END LOOP;
7657: END IF;

Line 7662: WHEN FND_API.G_EXC_ERROR THEN

7658: csi_gen_utility_pvt.put_line('End of Get_Cyclic_Node...');
7659: EXCEPTION
7660: WHEN COMP_ERROR THEN
7661: null;
7662: WHEN FND_API.G_EXC_ERROR THEN
7663: x_return_status := fnd_api.g_ret_sts_error ;
7664: fnd_msg_pub.count_AND_get
7665: (p_count => x_msg_count ,
7666: p_data => x_msg_data

Line 7663: x_return_status := fnd_api.g_ret_sts_error ;

7659: EXCEPTION
7660: WHEN COMP_ERROR THEN
7661: null;
7662: WHEN FND_API.G_EXC_ERROR THEN
7663: x_return_status := fnd_api.g_ret_sts_error ;
7664: fnd_msg_pub.count_AND_get
7665: (p_count => x_msg_count ,
7666: p_data => x_msg_data
7667: );

Line 7669: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

7665: (p_count => x_msg_count ,
7666: p_data => x_msg_data
7667: );
7668:
7669: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7670: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7671: fnd_msg_pub.count_AND_get
7672: (p_count => x_msg_count ,
7673: p_data => x_msg_data

Line 7670: x_return_status := fnd_api.g_ret_sts_unexp_error ;

7666: p_data => x_msg_data
7667: );
7668:
7669: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7670: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7671: fnd_msg_pub.count_AND_get
7672: (p_count => x_msg_count ,
7673: p_data => x_msg_data
7674: );

Line 7677: x_return_status := fnd_api.g_ret_sts_unexp_error ;

7673: p_data => x_msg_data
7674: );
7675:
7676: WHEN OTHERS THEN
7677: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7678: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
7679: fnd_msg_pub.add_exc_msg(g_pkg_name,l_api_name);
7680: END IF;
7681: fnd_msg_pub.count_AND_get