DBA Data[Home] [Help]

APPS.CSI_II_RELATIONSHIPS_PVT dependencies on FND_API

Line 69: IF NOT fnd_api.compatible_api_call ( l_api_version,

65: -- standard start of api savepoint
66: --SAVEPOINT get_cylic_relationships_pvt;
67:
68: -- standard call to check for call compatibility.
69: IF NOT fnd_api.compatible_api_call ( l_api_version,
70: p_api_version,
71: l_api_name,
72: g_pkg_name)
73: THEN

Line 74: RAISE fnd_api.g_exc_unexpected_error;

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

Line 78: IF fnd_api.to_boolean( p_init_msg_list )

74: RAISE fnd_api.g_exc_unexpected_error;
75: END IF;
76:
77: -- initialize message list if p_init_msg_list is set to true.
78: IF fnd_api.to_boolean( p_init_msg_list )
79: THEN
80: fnd_msg_pub.initialize;
81: END IF;
82:

Line 84: x_return_status := fnd_api.g_ret_sts_success;

80: fnd_msg_pub.initialize;
81: END IF;
82:
83: -- initialize api return status to success
84: x_return_status := fnd_api.g_ret_sts_success;
85: l_debug_level := fnd_profile.value('CSI_DEBUG_LEVEL');
86:
87: IF (l_debug_level > 0) THEN
88: CSI_gen_utility_pvt.put_line( 'get_cyclic_relationships');

Line 114: x_return_status := fnd_api.g_ret_sts_error;

110: IF p_instance_id IS NULL
111: THEN
112: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
113: fnd_msg_pub.add;
114: x_return_status := fnd_api.g_ret_sts_error;
115: RAISE fnd_api.g_exc_error;
116: END IF;
117:
118: select to_char(sysdate,'YY-MON-DD HH:MI:SS')

Line 115: RAISE fnd_api.g_exc_error;

111: THEN
112: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
113: fnd_msg_pub.add;
114: x_return_status := fnd_api.g_ret_sts_error;
115: RAISE fnd_api.g_exc_error;
116: END IF;
117:
118: select to_char(sysdate,'YY-MON-DD HH:MI:SS')
119: into l_start_time

Line 234: WHEN fnd_api.g_exc_unexpected_error THEN

230: into l_end_time
231: from dual ;
232:
233: EXCEPTION
234: WHEN fnd_api.g_exc_unexpected_error THEN
235: --ROLLBACK TO get_cylic_relationships_pvt;
236: x_return_status := fnd_api.g_ret_sts_unexp_error ;
237: fnd_msg_pub.count_AND_get
238: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 236: x_return_status := fnd_api.g_ret_sts_unexp_error ;

232:
233: EXCEPTION
234: WHEN fnd_api.g_exc_unexpected_error THEN
235: --ROLLBACK TO get_cylic_relationships_pvt;
236: x_return_status := fnd_api.g_ret_sts_unexp_error ;
237: fnd_msg_pub.count_AND_get
238: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
239: p_count => x_msg_count ,
240: p_data => x_msg_data);

Line 238: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

234: WHEN fnd_api.g_exc_unexpected_error THEN
235: --ROLLBACK TO get_cylic_relationships_pvt;
236: x_return_status := fnd_api.g_ret_sts_unexp_error ;
237: fnd_msg_pub.count_AND_get
238: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
239: p_count => x_msg_count ,
240: p_data => x_msg_data);
241:
242: WHEN OTHERS THEN

Line 244: x_return_status := fnd_api.g_ret_sts_unexp_error ;

240: p_data => x_msg_data);
241:
242: WHEN OTHERS THEN
243: --ROLLBACK TO get_cylic_relationships_pvt;
244: x_return_status := fnd_api.g_ret_sts_unexp_error ;
245: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
246: THEN
247: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
248: END IF;

Line 250: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

246: THEN
247: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
248: END IF;
249: fnd_msg_pub.count_AND_get
250: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
251: p_count => x_msg_count ,
252: p_data => x_msg_data);
253: END get_cyclic_relationships;
254:

Line 304: 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) ;

300: FROM csi_ii_relationships
301: WHERE (subject_id = p_instance_id OR object_id = p_instance_id )
302: AND relationship_type_code = 'CONNECTED-TO'
303: AND nvl(active_start_date,creation_date) <= NVL(l_time_stamp,nvl(active_start_date,creation_date))
304: 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) ;
305:
306: BEGIN
307: i:= 0;
308: SELECT SYSDATE

Line 313: IF p_time_stamp = FND_API.G_MISS_DATE THEN

309: INTO l_sysdate
310: FROM dual;
311: --
312: -- srramakr Bug # 2882876
313: IF p_time_stamp = FND_API.G_MISS_DATE THEN
314: l_time_stamp := null;
315: ELSE
316: l_time_stamp := p_time_stamp;
317: END IF;

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: UNION ALL
414: SELECT object_id instance_id
415: FROM csi_ii_relationships
416: WHERE (subject_id = p_instance_id OR object_id = p_instance_id)

Line 419: 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) ;

415: FROM csi_ii_relationships
416: WHERE (subject_id = p_instance_id OR object_id = p_instance_id)
417: AND relationship_type_code = 'CONNECTED-TO'
418: AND nvl(active_start_date,creation_date) <= NVL(l_time_stamp,nvl(active_start_date,creation_date))
419: 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) ;
420:
421: BEGIN
422: SELECT SYSDATE
423: INTO l_sysdate

Line 427: IF p_time_stamp = FND_API.G_MISS_DATE THEN

423: INTO l_sysdate
424: FROM DUAL;
425: --
426: -- srramakr Bug # 2882876
427: IF p_time_stamp = FND_API.G_MISS_DATE THEN
428: l_time_stamp := null;
429: ELSE
430: l_time_stamp := p_time_stamp;
431: END IF;

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

455:
456: /* End of Cyclic Relationships */
457:
458: PROCEDURE validate_ii_relationships(
459: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
460: p_validation_level IN NUMBER := fnd_api.g_valid_level_full,
461: p_validation_mode IN VARCHAR2,
462: p_ii_relationship_tbl IN csi_datastructures_pub.ii_relationship_tbl,
463: x_return_status OUT NOCOPY VARCHAR2,

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

456: /* End of Cyclic Relationships */
457:
458: PROCEDURE validate_ii_relationships(
459: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
460: p_validation_level IN NUMBER := fnd_api.g_valid_level_full,
461: p_validation_mode IN VARCHAR2,
462: p_ii_relationship_tbl IN csi_datastructures_pub.ii_relationship_tbl,
463: x_return_status OUT NOCOPY VARCHAR2,
464: x_msg_count OUT NOCOPY NUMBER,

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

465: x_msg_data OUT NOCOPY VARCHAR2
466: );
467:
468: PROCEDURE validate_relationship_id (
469: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
470: p_validation_mode IN VARCHAR2,
471: p_relationship_id IN NUMBER,
472: x_return_status OUT NOCOPY VARCHAR2,
473: x_msg_count OUT NOCOPY NUMBER,

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

474: x_msg_data OUT NOCOPY VARCHAR2
475: );
476:
477: PROCEDURE validate_rel_type_code (
478: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
479: p_validation_mode IN VARCHAR2,
480: p_relationship_type_code IN VARCHAR2,
481: x_return_status OUT NOCOPY VARCHAR2,
482: x_msg_count OUT NOCOPY NUMBER,

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

484: );
485:
486:
487: PROCEDURE validate_object_id (
488: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
489: p_validation_mode IN VARCHAR2,
490: p_object_id IN NUMBER,
491: x_return_status OUT NOCOPY VARCHAR2,
492: x_msg_count OUT NOCOPY NUMBER,

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

494: );
495:
496:
497: PROCEDURE validate_subject_id (
498: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
499: p_validation_mode IN VARCHAR2,
500: p_subject_id IN NUMBER,
501: x_return_status OUT NOCOPY VARCHAR2,
502: x_msg_count OUT NOCOPY NUMBER,

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

504: );
505:
506:
507: PROCEDURE validate_active_end_date (
508: p_init_msg_list IN VARCHAR2 := fnd_api.g_false,
509: p_validation_mode IN VARCHAR2,
510: p_active_end_date IN DATE,
511: x_return_status OUT NOCOPY VARCHAR2,
512: x_msg_count OUT NOCOPY NUMBER,

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

597: )
598: IS
599: BEGIN
600:
601: IF( (p_relationship_query_rec.relationship_id IS NOT NULL) AND (p_relationship_query_rec.relationship_id <> fnd_api.g_miss_num) )
602: THEN
603: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_id', p_relationship_query_rec.relationship_id);
604: END IF;
605:

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

602: THEN
603: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_id', p_relationship_query_rec.relationship_id);
604: END IF;
605:
606: IF( (p_relationship_query_rec.relationship_type_code IS NOT NULL) AND (p_relationship_query_rec.relationship_type_code <> fnd_api.g_miss_char) )
607: THEN
608: dbms_sql.bind_variable(p_cur_get_relations, 'relationship_type_code', p_relationship_query_rec.relationship_type_code);
609: END IF;
610:

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

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

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

612: THEN
613: dbms_sql.bind_variable(p_cur_get_relations, 'object_id', p_relationship_query_rec.object_id);
614: END IF;
615:
616: IF( (p_relationship_query_rec.subject_id IS NOT NULL) AND (p_relationship_query_rec.subject_id <> fnd_api.g_miss_num) )
617: THEN
618: dbms_sql.bind_variable(p_cur_get_relations, 'subject_id', p_relationship_query_rec.subject_id);
619: END IF;
620:

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

662:
663: BEGIN
664:
665:
666: IF( (p_relship_query_rec.relationship_id IS NOT NULL) AND (p_relship_query_rec.relationship_id <> fnd_api.g_miss_num) )
667: THEN
668: l_cnt:=l_cnt+1;
669: IF(x_relations_where IS NULL) THEN
670: x_relations_where := ' WHERE ';

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

683: END IF;
684: x_relations_where := x_relations_where ||' ( active_end_date is null or active_end_date >= SYSDATE ) ';
685: END IF; **** END OF COMMENT ****/
686:
687: IF( (p_relship_query_rec.subject_id IS NOT NULL) AND (p_relship_query_rec.subject_id <> fnd_api.g_miss_num) )
688: THEN
689: l_cnt:=l_cnt+1;
690: IF(x_relations_where IS NULL) THEN
691: x_relations_where := ' WHERE ';

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

694: END IF;
695: x_relations_where := x_relations_where || 'subject_id = :subject_id';
696: END IF;
697:
698: IF( (p_relship_query_rec.relationship_type_code IS NOT NULL) AND (p_relship_query_rec.relationship_type_code <> fnd_api.g_miss_char) )
699: THEN
700: l_cnt:=l_cnt+1;
701: i:=0;
702: -- check IF item value contains '%' wildcard

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

727: END IF;
728: x_relations_where := x_relations_where || 'relationship_type_code ' || l_operator || ' :relationship_type_code';
729: END IF;
730:
731: IF( (p_relship_query_rec.object_id IS NOT NULL) AND (p_relship_query_rec.object_id <> fnd_api.g_miss_num) )
732: THEN
733: IF(x_relations_where IS NULL) THEN
734: x_relations_where := ' WHERE ';
735: ELSE

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

742: IF l_cnt>1 THEN
743: x_relations_where := x_relations_where || 'object_id = :object_id ';
744: ELSE
745: x_relations_where := x_relations_where || 'object_id = :object_id ' ||'CONNECT BY object_id = PRIOR subject_id' ;
746: IF ( (p_depth IS NOT NULL) AND (p_depth <> fnd_api.g_miss_num) ) THEN
747: x_relations_where := x_relations_where || ' AND level <= '||p_depth;
748: END IF;
749: END IF;
750: END IF;

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

775: p_time_stamp IN DATE,
776: from_time_stamp OUT NOCOPY VARCHAR2,
777: to_time_stamp OUT NOCOPY VARCHAR2)
778: IS
779: l_f_date VARCHAR2(25) := fnd_api.g_miss_char;
780: l_t_date VARCHAR2(25) := fnd_api.g_miss_char;
781: BEGIN
782:
783: SELECT max(min(to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss')))

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

776: from_time_stamp OUT NOCOPY VARCHAR2,
777: to_time_stamp OUT NOCOPY VARCHAR2)
778: IS
779: l_f_date VARCHAR2(25) := fnd_api.g_miss_char;
780: l_t_date VARCHAR2(25) := fnd_api.g_miss_char;
781: BEGIN
782:
783: SELECT max(min(to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss')))
784: INTO l_f_date

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

876: AND a.transaction_date BETWEEN to_date(p_f_time_stamp,'dd/mm/rr hh24:mi:ss')
877: AND to_date(p_t_time_stamp,'dd/mm/rr hh24:mi:ss')
878: ORDER BY to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss') ;
879:
880: l_f_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
881: l_t_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
882: l_to_date VARCHAR2(25);
883: BEGIN
884: FROM_to_tran(p_relationship_id => p_rel_rec.relationship_id,

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

877: AND to_date(p_t_time_stamp,'dd/mm/rr hh24:mi:ss')
878: ORDER BY to_char(a.transaction_date,'dd-mon-rr hh24:mi:ss') ;
879:
880: l_f_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
881: l_t_time_stamp VARCHAR2(25) :=fnd_api.g_miss_char;
882: l_to_date VARCHAR2(25);
883: BEGIN
884: FROM_to_tran(p_relationship_id => p_rel_rec.relationship_id,
885: p_time_stamp => p_time_stamp,

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

1045: p_new_rec.attribute15 := get_csr.old_attribute15;
1046: END IF;
1047:
1048: END LOOP;
1049: IF p_new_rec.display_order = fnd_api.g_miss_num THEN
1050: p_new_rec.display_order := NULL;
1051: END IF;
1052:
1053: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN

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

1049: IF p_new_rec.display_order = fnd_api.g_miss_num THEN
1050: p_new_rec.display_order := NULL;
1051: END IF;
1052:
1053: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN
1054: p_new_rec.subject_id := NULL;
1055: END IF;
1056:
1057: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN

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

1053: IF p_new_rec.subject_id = fnd_api.g_miss_num THEN
1054: p_new_rec.subject_id := NULL;
1055: END IF;
1056:
1057: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN
1058: p_new_rec.position_reference := NULL;
1059: END IF;
1060:
1061: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN

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

1057: IF p_new_rec.position_reference = fnd_api.g_miss_char THEN
1058: p_new_rec.position_reference := NULL;
1059: END IF;
1060:
1061: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN
1062: p_new_rec.active_start_date := NULL;
1063: END IF;
1064:
1065: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN

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

1061: IF p_new_rec.active_start_date = fnd_api.g_miss_date THEN
1062: p_new_rec.active_start_date := NULL;
1063: END IF;
1064:
1065: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN
1066: p_new_rec.active_end_date := NULL;
1067: END IF;
1068:
1069: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN

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

1065: IF p_new_rec.active_end_date = fnd_api.g_miss_date THEN
1066: p_new_rec.active_end_date := NULL;
1067: END IF;
1068:
1069: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN
1070: p_new_rec.mandatory_flag := NULL;
1071: END IF;
1072:
1073: IF p_new_rec.context = fnd_api.g_miss_char THEN

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

1069: IF p_new_rec.mandatory_flag = fnd_api.g_miss_char THEN
1070: p_new_rec.mandatory_flag := NULL;
1071: END IF;
1072:
1073: IF p_new_rec.context = fnd_api.g_miss_char THEN
1074: p_new_rec.context := NULL;
1075: END IF;
1076:
1077: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN

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

1073: IF p_new_rec.context = fnd_api.g_miss_char THEN
1074: p_new_rec.context := NULL;
1075: END IF;
1076:
1077: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN
1078: p_new_rec.attribute1 := NULL;
1079: END IF;
1080:
1081: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN

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

1077: IF p_new_rec.attribute1 = fnd_api.g_miss_char THEN
1078: p_new_rec.attribute1 := NULL;
1079: END IF;
1080:
1081: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN
1082: p_new_rec.attribute2 := NULL;
1083: END IF;
1084:
1085: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN

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

1081: IF p_new_rec.attribute2 = fnd_api.g_miss_char THEN
1082: p_new_rec.attribute2 := NULL;
1083: END IF;
1084:
1085: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN
1086: p_new_rec.attribute3 := NULL;
1087: END IF;
1088:
1089: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN

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

1085: IF p_new_rec.attribute3 = fnd_api.g_miss_char THEN
1086: p_new_rec.attribute3 := NULL;
1087: END IF;
1088:
1089: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN
1090: p_new_rec.attribute4 := NULL;
1091: END IF;
1092:
1093: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN

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

1089: IF p_new_rec.attribute4 = fnd_api.g_miss_char THEN
1090: p_new_rec.attribute4 := NULL;
1091: END IF;
1092:
1093: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN
1094: p_new_rec.attribute5 := NULL;
1095: END IF;
1096:
1097: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN

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

1093: IF p_new_rec.attribute5 = fnd_api.g_miss_char THEN
1094: p_new_rec.attribute5 := NULL;
1095: END IF;
1096:
1097: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN
1098: p_new_rec.attribute6 := NULL;
1099: END IF;
1100:
1101: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN

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

1097: IF p_new_rec.attribute6 = fnd_api.g_miss_char THEN
1098: p_new_rec.attribute6 := NULL;
1099: END IF;
1100:
1101: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN
1102: p_new_rec.attribute7 := NULL;
1103: END IF;
1104:
1105: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN

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

1101: IF p_new_rec.attribute7 =fnd_api.g_miss_char THEN
1102: p_new_rec.attribute7 := NULL;
1103: END IF;
1104:
1105: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN
1106: p_new_rec.attribute8 := NULL;
1107: END IF;
1108:
1109: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN

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

1105: IF p_new_rec.attribute8 = fnd_api.g_miss_char THEN
1106: p_new_rec.attribute8 := NULL;
1107: END IF;
1108:
1109: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN
1110: p_new_rec.attribute9 := NULL;
1111: END IF;
1112:
1113: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN

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

1109: IF p_new_rec.attribute9 = fnd_api.g_miss_char THEN
1110: p_new_rec.attribute9 := NULL;
1111: END IF;
1112:
1113: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN
1114: p_new_rec.attribute10 := NULL;
1115: END IF;
1116:
1117: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN

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

1113: IF p_new_rec.attribute10 = fnd_api.g_miss_char THEN
1114: p_new_rec.attribute10 := NULL;
1115: END IF;
1116:
1117: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN
1118: p_new_rec.attribute11 := NULL;
1119: END IF;
1120:
1121: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN

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

1117: IF p_new_rec.attribute11 = fnd_api.g_miss_char THEN
1118: p_new_rec.attribute11 := NULL;
1119: END IF;
1120:
1121: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN
1122: p_new_rec.attribute12 := NULL;
1123: END IF;
1124:
1125: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN

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

1121: IF p_new_rec.attribute12 = fnd_api.g_miss_char THEN
1122: p_new_rec.attribute12 := NULL;
1123: END IF;
1124:
1125: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN
1126: p_new_rec.attribute13 := NULL;
1127: END IF;
1128:
1129: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN

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

1125: IF p_new_rec.attribute13 = fnd_api.g_miss_char THEN
1126: p_new_rec.attribute13 := NULL;
1127: END IF;
1128:
1129: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN
1130: p_new_rec.attribute14 := NULL;
1131: END IF;
1132:
1133: IF p_new_rec.attribute15 = fnd_api.g_miss_char THEN

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

1129: IF p_new_rec.attribute14 =fnd_api.g_miss_char THEN
1130: p_new_rec.attribute14 := NULL;
1131: END IF;
1132:
1133: IF p_new_rec.attribute15 = fnd_api.g_miss_char THEN
1134: p_new_rec.attribute15 := NULL;
1135: END IF;
1136:
1137: p_flag :='ADD';

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

1294: object_version_number
1295: from CSI_II_RELATIONSHIPS cir
1296: where cir.object_id = p_object_id
1297: and cir.relationship_type_code = p_rel_type_code
1298: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1299: and EXISTS (select 'x'
1300: from CSI_ITEM_INSTANCES csi
1301: where csi.instance_id = cir.subject_id
1302: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

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

1298: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1299: and EXISTS (select 'x'
1300: from CSI_ITEM_INSTANCES csi
1301: where csi.instance_id = cir.subject_id
1302: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1303: --
1304: CURSOR OBJECT_CUR1(c_sysdate IN DATE) IS -- Used when Object ID and Rel Type are passed
1305: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1306: active_start_date,active_end_date,display_order,mandatory_flag,context,

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

1309: object_version_number
1310: from CSI_II_RELATIONSHIPS cir
1311: where cir.object_id = p_object_id
1312: and cir.relationship_type_code = p_rel_type_code
1313: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1314: and EXISTS (select 'x'
1315: from CSI_ITEM_INSTANCES csi
1316: where csi.instance_id = cir.subject_id
1317: and csi.config_inst_hdr_id is not null

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

1316: where csi.instance_id = cir.subject_id
1317: and csi.config_inst_hdr_id is not null
1318: and csi.config_inst_item_id is not null
1319: and csi.config_inst_rev_num is not null
1320: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1321: --
1322: CURSOR OBJECT_ONLY_CUR(c_sysdate IN DATE) IS -- Used when only Object ID is passed
1323: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1324: active_start_date,active_end_date,display_order,mandatory_flag,context,

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

1326: attribute9,attribute10,attribute11,attribute12,attribute13,attribute14,attribute15,
1327: object_version_number
1328: from CSI_II_RELATIONSHIPS cir
1329: where cir.object_id = p_object_id
1330: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1331: and EXISTS (select 'x'
1332: from CSI_ITEM_INSTANCES csi
1333: where csi.instance_id = cir.subject_id
1334: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

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

1330: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1331: and EXISTS (select 'x'
1332: from CSI_ITEM_INSTANCES csi
1333: where csi.instance_id = cir.subject_id
1334: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1335: --
1336: CURSOR SUBJECT_CUR(c_sysdate IN DATE) IS --Used when subject ID and Rel type are passed
1337: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1338: active_start_date,active_end_date,display_order,mandatory_flag,context,

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

1341: object_version_number
1342: from CSI_II_RELATIONSHIPS cir
1343: where cir.subject_id = p_subject_id
1344: and cir.relationship_type_code = p_rel_type_code
1345: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1346: and EXISTS (select 'x'
1347: from CSI_ITEM_INSTANCES csi
1348: where csi.instance_id = cir.subject_id
1349: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

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

1345: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1346: and EXISTS (select 'x'
1347: from CSI_ITEM_INSTANCES csi
1348: where csi.instance_id = cir.subject_id
1349: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1350: --
1351: CURSOR REL_ID_CUR(c_sysdate IN DATE) IS -- Used when only relationship_id is passed
1352: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1353: active_start_date,active_end_date,display_order,mandatory_flag,context,

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

1355: attribute9,attribute10,attribute11,attribute12,attribute13,attribute14,attribute15,
1356: object_version_number
1357: from CSI_II_RELATIONSHIPS cir
1358: where cir.relationship_id = p_relationship_id
1359: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1360: and EXISTS (select 'x'
1361: from CSI_ITEM_INSTANCES csi
1362: where csi.instance_id = cir.subject_id
1363: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

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

1359: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1360: and EXISTS (select 'x'
1361: from CSI_ITEM_INSTANCES csi
1362: where csi.instance_id = cir.subject_id
1363: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1364: --
1365: CURSOR OTHER_PARAM_CUR(c_sysdate IN DATE) IS
1366: select relationship_id,relationship_type_code,object_id,subject_id,position_reference,
1367: active_start_date,active_end_date,display_order,mandatory_flag,context,

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

1372: where cir.relationship_id = NVL(p_relationship_id,cir.relationship_id)
1373: and cir.object_id = NVL(p_object_id,cir.object_id)
1374: and cir.relationship_type_code = NVL(p_rel_type_code,cir.relationship_type_code)
1375: and cir.subject_id = NVL(p_subject_id,cir.subject_id)
1376: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1377: and EXISTS (select 'x'
1378: from CSI_ITEM_INSTANCES csi
1379: where csi.instance_id = cir.subject_id
1380: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);

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

1376: and DECODE(l_active_relationship_only,FND_API.G_TRUE,NVL((cir.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate
1377: and EXISTS (select 'x'
1378: from CSI_ITEM_INSTANCES csi
1379: where csi.instance_id = cir.subject_id
1380: and DECODE(l_active_instances_only,FND_API.G_TRUE,NVL((csi.active_end_date),c_sysdate+1),c_sysdate+1) > sysdate);
1381: --
1382: l_ctr NUMBER := 0;
1383: l_sysdate DATE;
1384: COMP_EXCEP EXCEPTION;

Line 1391: l_active_instances_only := FND_API.G_FALSE;

1387: into l_sysdate
1388: from dual;
1389: --
1390: IF p_time_stamp IS NOT NULL THEN
1391: l_active_instances_only := FND_API.G_FALSE;
1392: l_active_relationship_only := FND_API.G_FALSE;
1393: ELSE
1394: l_active_relationship_only := p_active_relationship_only;
1395: l_active_instances_only := p_active_instances_only;

Line 1392: l_active_relationship_only := FND_API.G_FALSE;

1388: from dual;
1389: --
1390: IF p_time_stamp IS NOT NULL THEN
1391: l_active_instances_only := FND_API.G_FALSE;
1392: l_active_relationship_only := FND_API.G_FALSE;
1393: ELSE
1394: l_active_relationship_only := p_active_relationship_only;
1395: l_active_instances_only := p_active_instances_only;
1396: END IF;

Line 1404: p_config_only = fnd_api.g_false

1400: p_subject_id IS NULL AND
1401: p_relationship_id IS NULL
1402: THEN
1403: IF p_config_only IS NULL OR
1404: p_config_only = fnd_api.g_false
1405: THEN
1406: FOR rel IN OBJECT_CUR(l_sysdate) LOOP
1407: l_ctr := l_ctr + 1;
1408: p_rel_tbl(l_ctr).relationship_id := rel.relationship_id;

Line 1448: p_config_only = fnd_api.g_true

1444: p_rel_tbl(l_ctr).subject_has_child := 'N';
1445: End;
1446: END LOOP;
1447: ELSIF p_config_only IS NOT NULL AND
1448: p_config_only = fnd_api.g_true
1449: THEN
1450: FOR rel IN OBJECT_CUR1(l_sysdate) LOOP
1451: l_ctr := l_ctr + 1;
1452: p_rel_tbl(l_ctr).relationship_id := rel.relationship_id;

Line 1797: x_return_status := FND_API.G_RET_STS_SUCCESS;

1793: l_relationship_id NUMBER;
1794: l_time_stamp DATE;
1795: l_max_count NUMBER;
1796: BEGIN
1797: x_return_status := FND_API.G_RET_STS_SUCCESS;
1798: --savepoint Get_Children;
1799: IF l_depth IS NULL OR
1800: l_depth = FND_API.G_MISS_NUM OR
1801: l_depth <= 0 THEN

Line 1800: l_depth = FND_API.G_MISS_NUM OR

1796: BEGIN
1797: x_return_status := FND_API.G_RET_STS_SUCCESS;
1798: --savepoint Get_Children;
1799: IF l_depth IS NULL OR
1800: l_depth = FND_API.G_MISS_NUM OR
1801: l_depth <= 0 THEN
1802: l_depth := 9999999;
1803: END IF;
1804: --

Line 1806: p_relationship_query_rec.object_id = FND_API.G_MISS_NUM THEN

1802: l_depth := 9999999;
1803: END IF;
1804: --
1805: IF p_relationship_query_rec.object_id IS NULL OR
1806: p_relationship_query_rec.object_id = FND_API.G_MISS_NUM THEN
1807: l_object_id := null;
1808: ELSE
1809: l_object_id := p_relationship_query_rec.object_id;
1810: END IF;

Line 1813: p_relationship_query_rec.subject_id = FND_API.G_MISS_NUM THEN

1809: l_object_id := p_relationship_query_rec.object_id;
1810: END IF;
1811: --
1812: IF p_relationship_query_rec.subject_id IS NULL OR
1813: p_relationship_query_rec.subject_id = FND_API.G_MISS_NUM THEN
1814: l_subject_id := null;
1815: ELSE
1816: l_subject_id := p_relationship_query_rec.subject_id;
1817: END IF;

Line 1820: p_relationship_query_rec.relationship_id = FND_API.G_MISS_NUM THEN

1816: l_subject_id := p_relationship_query_rec.subject_id;
1817: END IF;
1818: --
1819: IF p_relationship_query_rec.relationship_id IS NULL OR
1820: p_relationship_query_rec.relationship_id = FND_API.G_MISS_NUM THEN
1821: l_relationship_id := null;
1822: ELSE
1823: l_relationship_id := p_relationship_query_rec.relationship_id;
1824: END IF;

Line 1827: p_relationship_query_rec.relationship_type_code = FND_API.G_MISS_CHAR THEN

1823: l_relationship_id := p_relationship_query_rec.relationship_id;
1824: END IF;
1825: --
1826: IF p_relationship_query_rec.relationship_type_code IS NULL OR
1827: p_relationship_query_rec.relationship_type_code = FND_API.G_MISS_CHAR THEN
1828: l_rel_type_code := null;
1829: ELSE
1830: l_rel_type_code := p_relationship_query_rec.relationship_type_code;
1831: END IF;

Line 1839: x_return_status := fnd_api.g_ret_sts_error;

1835: l_relationship_id IS NULL AND
1836: l_rel_type_code IS NULL THEN
1837: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
1838: fnd_msg_pub.add;
1839: x_return_status := fnd_api.g_ret_sts_error;
1840: RAISE fnd_api.g_exc_error;
1841: END IF;
1842: --
1843: IF p_time_stamp IS NULL OR

Line 1840: RAISE fnd_api.g_exc_error;

1836: l_rel_type_code IS NULL THEN
1837: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
1838: fnd_msg_pub.add;
1839: x_return_status := fnd_api.g_ret_sts_error;
1840: RAISE fnd_api.g_exc_error;
1841: END IF;
1842: --
1843: IF p_time_stamp IS NULL OR
1844: p_time_stamp = FND_API.G_MISS_DATE THEN

Line 1844: p_time_stamp = FND_API.G_MISS_DATE THEN

1840: RAISE fnd_api.g_exc_error;
1841: END IF;
1842: --
1843: IF p_time_stamp IS NULL OR
1844: p_time_stamp = FND_API.G_MISS_DATE THEN
1845: l_time_stamp := NULL;
1846: ELSE
1847: l_time_stamp := p_time_stamp;
1848: END IF;

Line 1851: IF p_get_dfs = FND_API.G_FALSE OR

1847: l_time_stamp := p_time_stamp;
1848: END IF;
1849: --
1850: /* Added IF lakmohan Bug 7503134 ; forward port by Derek Chang*/
1851: IF p_get_dfs = FND_API.G_FALSE OR
1852: l_object_id IS NULL AND
1853: l_subject_id IS NOT NULL AND
1854: l_relationship_id IS NULL THEN
1855: Get_Next_Level

Line 1931: ELSIF nvl(p_get_dfs,FND_API.G_TRUE) = FND_API.G_TRUE AND -- Need to Sort if Object_id alone is passed

1927:
1928: -- The output of l_rel_tbl_final will be Breadth first search Order.
1929: -- This needs to be converted to depth-first-search order.
1930: -- The following LOOP does this.
1931: ELSIF nvl(p_get_dfs,FND_API.G_TRUE) = FND_API.G_TRUE AND -- Need to Sort if Object_id alone is passed
1932: l_object_id IS NOT NULL AND
1933: l_subject_id IS NULL AND
1934: l_relationship_id IS NULL THEN
1935: p_rel_tbl.DELETE;

Line 2011: WHEN fnd_api.g_exc_error THEN

2007: p_glbl_ctr := 0; --bug 10321217
2008: --p_rel_glbl_tbl.delete;
2009: END IF; -- p_get_dfs check
2010: EXCEPTION
2011: WHEN fnd_api.g_exc_error THEN
2012: -- ROLLBACK TO Get_Children;
2013: x_return_status := fnd_api.g_ret_sts_error ;
2014: fnd_msg_pub.count_AND_get
2015: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 2013: x_return_status := fnd_api.g_ret_sts_error ;

2009: END IF; -- p_get_dfs check
2010: EXCEPTION
2011: WHEN fnd_api.g_exc_error THEN
2012: -- ROLLBACK TO Get_Children;
2013: x_return_status := fnd_api.g_ret_sts_error ;
2014: fnd_msg_pub.count_AND_get
2015: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
2016: p_count => x_msg_count ,
2017: p_data => x_msg_data

Line 2015: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

2011: WHEN fnd_api.g_exc_error THEN
2012: -- ROLLBACK TO Get_Children;
2013: x_return_status := fnd_api.g_ret_sts_error ;
2014: fnd_msg_pub.count_AND_get
2015: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
2016: p_count => x_msg_count ,
2017: p_data => x_msg_data
2018: );
2019:

Line 2020: WHEN fnd_api.g_exc_unexpected_error THEN

2016: p_count => x_msg_count ,
2017: p_data => x_msg_data
2018: );
2019:
2020: WHEN fnd_api.g_exc_unexpected_error THEN
2021: -- ROLLBACK TO Get_Children;
2022: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2023: fnd_msg_pub.count_AND_get
2024: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 2022: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2018: );
2019:
2020: WHEN fnd_api.g_exc_unexpected_error THEN
2021: -- ROLLBACK TO Get_Children;
2022: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2023: fnd_msg_pub.count_AND_get
2024: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
2025: p_count => x_msg_count ,
2026: p_data => x_msg_data

Line 2024: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

2020: WHEN fnd_api.g_exc_unexpected_error THEN
2021: -- ROLLBACK TO Get_Children;
2022: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2023: fnd_msg_pub.count_AND_get
2024: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
2025: p_count => x_msg_count ,
2026: p_data => x_msg_data
2027: );
2028:

Line 2031: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2027: );
2028:
2029: WHEN OTHERS THEN
2030: -- ROLLBACK TO Get_Children;
2031: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2032: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2033: fnd_msg_pub.add_exc_msg('csi_relationships_pvt' ,l_api_name);
2034: END IF;
2035: fnd_msg_pub.count_AND_get

Line 2036: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

2032: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
2033: fnd_msg_pub.add_exc_msg('csi_relationships_pvt' ,l_api_name);
2034: END IF;
2035: fnd_msg_pub.count_AND_get
2036: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
2037: p_count => x_msg_count ,
2038: p_data => x_msg_data
2039: );
2040: END Get_Children;

Line 2087: p_subject_id = FND_API.G_MISS_NUM THEN

2083: l_subject_id NUMBER;
2084: l_exists VARCHAR2(1);
2085: BEGIN
2086: IF p_subject_id IS NULL OR
2087: p_subject_id = FND_API.G_MISS_NUM THEN
2088: Return;
2089: END IF;
2090: --
2091: l_subject_id := p_subject_id;

Line 2224: IF NOT fnd_api.compatible_api_call ( l_api_version,

2220: -- standard start of api savepoint
2221: -- SAVEPOINT get_relationships_pvt;
2222:
2223: -- standard call to check for call compatibility.
2224: IF NOT fnd_api.compatible_api_call ( l_api_version,
2225: p_api_version,
2226: l_api_name,
2227: g_pkg_name)
2228: THEN

Line 2229: RAISE fnd_api.g_exc_unexpected_error;

2225: p_api_version,
2226: l_api_name,
2227: g_pkg_name)
2228: THEN
2229: RAISE fnd_api.g_exc_unexpected_error;
2230: END IF;
2231:
2232:
2233: -- initialize message list if p_init_msg_list is set to true.

Line 2234: IF fnd_api.to_boolean( p_init_msg_list )

2230: END IF;
2231:
2232:
2233: -- initialize message list if p_init_msg_list is set to true.
2234: IF fnd_api.to_boolean( p_init_msg_list )
2235: THEN
2236: fnd_msg_pub.initialize;
2237: END IF;
2238:

Line 2243: x_return_status := fnd_api.g_ret_sts_success;

2239:
2240:
2241:
2242: -- initialize api return status to success
2243: x_return_status := fnd_api.g_ret_sts_success;
2244:
2245:
2246: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
2247: IF (l_debug_level > 0) THEN

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

2268: -- validate environment
2269: -- ******************************************************************
2270:
2271: IF
2272: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2273: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2274: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2275: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2276: )

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

2269: -- ******************************************************************
2270:
2271: IF
2272: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2273: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2274: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2275: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2276: )
2277: THEN

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

2270:
2271: IF
2272: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2273: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2274: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2275: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2276: )
2277: THEN
2278: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');

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

2271: IF
2272: ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2273: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char))
2274: AND ((p_relationship_query_rec.object_id IS NULL) OR (p_relationship_query_rec.object_id = fnd_api.g_miss_num))
2275: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2276: )
2277: THEN
2278: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2279: fnd_msg_pub.add;

Line 2280: x_return_status := fnd_api.g_ret_sts_error;

2276: )
2277: THEN
2278: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2279: fnd_msg_pub.add;
2280: x_return_status := fnd_api.g_ret_sts_error;
2281: RAISE fnd_api.g_exc_error;
2282: END IF;
2283:
2284: /* Cyclic Relationships */

Line 2281: RAISE fnd_api.g_exc_error;

2277: THEN
2278: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2279: fnd_msg_pub.add;
2280: x_return_status := fnd_api.g_ret_sts_error;
2281: RAISE fnd_api.g_exc_error;
2282: END IF;
2283:
2284: /* Cyclic Relationships */
2285: IF (p_relationship_query_rec.relationship_type_code = 'CONNECTED-TO')

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

2286: THEN
2287: IF ((p_relationship_query_rec.subject_id IS NULL
2288: AND p_relationship_query_rec.object_id IS NULL)
2289: OR ((p_relationship_query_rec.subject_id IS NOT NULL
2290: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num)
2291: AND (p_relationship_query_rec.object_id IS NOT NULL
2292: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))
2293: THEN
2294: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');

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

2288: AND p_relationship_query_rec.object_id IS NULL)
2289: OR ((p_relationship_query_rec.subject_id IS NOT NULL
2290: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num)
2291: AND (p_relationship_query_rec.object_id IS NOT NULL
2292: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))
2293: THEN
2294: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2295: fnd_msg_pub.add;
2296: x_return_status := fnd_api.g_ret_sts_error;

Line 2296: x_return_status := fnd_api.g_ret_sts_error;

2292: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)))
2293: THEN
2294: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2295: fnd_msg_pub.add;
2296: x_return_status := fnd_api.g_ret_sts_error;
2297: RAISE fnd_api.g_exc_error;
2298: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2299: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2300: OR (p_relationship_query_rec.object_id IS NOT NULL

Line 2297: RAISE fnd_api.g_exc_error;

2293: THEN
2294: fnd_message.set_name('CSI', 'CSI_INVALID_PARAMETERS');
2295: fnd_msg_pub.add;
2296: x_return_status := fnd_api.g_ret_sts_error;
2297: RAISE fnd_api.g_exc_error;
2298: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2299: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2300: OR (p_relationship_query_rec.object_id IS NOT NULL
2301: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)

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

2295: fnd_msg_pub.add;
2296: x_return_status := fnd_api.g_ret_sts_error;
2297: RAISE fnd_api.g_exc_error;
2298: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2299: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2300: OR (p_relationship_query_rec.object_id IS NOT NULL
2301: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)
2302: THEN
2303: IF p_relationship_query_rec.subject_id IS NOT NULL

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

2297: RAISE fnd_api.g_exc_error;
2298: ELSIF ((p_relationship_query_rec.subject_id IS NOT NULL
2299: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num))
2300: OR (p_relationship_query_rec.object_id IS NOT NULL
2301: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)
2302: THEN
2303: IF p_relationship_query_rec.subject_id IS NOT NULL
2304: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num
2305: THEN

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

2300: OR (p_relationship_query_rec.object_id IS NOT NULL
2301: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num)
2302: THEN
2303: IF p_relationship_query_rec.subject_id IS NOT NULL
2304: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num
2305: THEN
2306: l_instance_id := p_relationship_query_rec.subject_id;
2307: ELSIF p_relationship_query_rec.object_id IS NOT NULL
2308: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num

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

2304: AND p_relationship_query_rec.subject_id <> fnd_api.g_miss_num
2305: THEN
2306: l_instance_id := p_relationship_query_rec.subject_id;
2307: ELSIF p_relationship_query_rec.object_id IS NOT NULL
2308: AND p_relationship_query_rec.object_id <> fnd_api.g_miss_num
2309: THEN
2310: l_instance_id := p_relationship_query_rec.object_id;
2311: END IF;
2312: END IF;

Line 2316: p_commit => fnd_api.g_false,

2312: END IF;
2313:
2314: csi_ii_relationships_pvt.get_cyclic_relationships(
2315: p_api_version => p_api_version,
2316: p_commit => fnd_api.g_false,
2317: p_init_msg_list => p_init_msg_list,
2318: p_validation_level => p_validation_level,
2319: p_instance_id => l_instance_id,
2320: p_depth => p_depth ,

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

2347: LOOP
2348: l_rel_rec := null ;
2349: l_rel_rec := xc_relationship_tbl(i);
2350:
2351: IF ((p_time_stamp IS NOT NULL) AND (p_time_stamp <> FND_API.G_MISS_DATE))
2352: THEN
2353: IF ((l_last_purge_date IS NOT NULL) AND (p_time_stamp <= l_last_purge_date))
2354: THEN
2355: csi_gen_utility_pvt.put_line('Warning! History for this entity has already been purged for the datetime stamp passed. ' ||

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

2370: ELSE
2371: l_relationship_tbl(i) := l_rel_rec;
2372: END IF;
2373: --
2374: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date) )THEN
2375: IF l_relationship_tbl.count > 0
2376: THEN
2377: BEGIN
2378: SELECT 'Y'

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

2385: EXCEPTION
2386: WHEN OTHERS THEN
2387: --l_relationship_tbl(i).subject_has_child := 'N';
2388: IF (l_relationship_tbl(i).relationship_id IS NOT NULL --Added for bug 2999353
2389: AND l_relationship_tbl(i).relationship_id <> fnd_api.g_miss_num) --Added for bug 2999353
2390: THEN
2391: l_relationship_tbl(i).subject_has_child := 'N';
2392: END IF;
2393: END;

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

2411: END LOOP;
2412: END IF;
2413: --
2414: IF l_exists_flag <> 'Y' THEN
2415: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2416: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2417: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2418: THEN
2419: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;

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

2413: --
2414: IF l_exists_flag <> 'Y' THEN
2415: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2416: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2417: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2418: THEN
2419: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;
2420: CSI_ITEM_INSTANCE_PUB.Get_item_instance_details(
2421: 1.0,

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

2442: x_msg_count,
2443: x_msg_data
2444: );
2445: --
2446: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
2447: l_msg_index := 1;
2448: l_msg_count := x_msg_count;
2449: WHILE l_msg_count > 0 LOOP
2450: x_msg_data := FND_MSG_PUB.GET

Line 2452: FND_API.G_FALSE );

2448: l_msg_count := x_msg_count;
2449: WHILE l_msg_count > 0 LOOP
2450: x_msg_data := FND_MSG_PUB.GET
2451: ( l_msg_index,
2452: FND_API.G_FALSE );
2453: csi_gen_utility_pvt.put_line( ' Error from Get_Item_Instance_Details.. ');
2454: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2455: l_msg_index := l_msg_index + 1;
2456: l_msg_count := l_msg_count - 1;

Line 2458: RAISE FND_API.G_EXC_ERROR;

2454: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2455: l_msg_index := l_msg_index + 1;
2456: l_msg_count := l_msg_count - 1;
2457: END LOOP;
2458: RAISE FND_API.G_EXC_ERROR;
2459: END IF;
2460: IF nvl(l_instance_rec.active_end_date,(sysdate+1)) < sysdate THEN
2461: l_ctr := l_exp_inst_tbl.count;
2462: l_ctr := l_ctr + 1;

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

2506:
2507: -- End addition by sguthiva
2508: ELSE ---if not CONNECTED-TO
2509: --gen_select(l_crit_relations_rec,l_select_cl);
2510: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2511: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2512: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2513: THEN
2514: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )

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

2507: -- End addition by sguthiva
2508: ELSE ---if not CONNECTED-TO
2509: --gen_select(l_crit_relations_rec,l_select_cl);
2510: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2511: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2512: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2513: THEN
2514: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2515: THEN

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

2508: ELSE ---if not CONNECTED-TO
2509: --gen_select(l_crit_relations_rec,l_select_cl);
2510: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2511: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2512: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2513: THEN
2514: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2515: THEN
2516: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )

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

2510: IF ( ((p_relationship_query_rec.relationship_id IS NULL) OR (p_relationship_query_rec.relationship_id = fnd_api.g_miss_num))
2511: AND ((p_relationship_query_rec.subject_id IS NULL) OR (p_relationship_query_rec.subject_id = fnd_api.g_miss_num))
2512: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2513: THEN
2514: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2515: THEN
2516: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )
2517: THEN
2518: fnd_message.set_name('CSI','CSI_NO_RELCODE_PASSED');

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

2512: AND ((p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char)) )
2513: THEN
2514: IF( (p_relationship_query_rec.object_id IS NOT NULL) AND (p_relationship_query_rec.object_id <> fnd_api.g_miss_num) )
2515: THEN
2516: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )
2517: THEN
2518: fnd_message.set_name('CSI','CSI_NO_RELCODE_PASSED');
2519: fnd_msg_pub.add;
2520: RAISE fnd_api.g_exc_error;

Line 2520: RAISE fnd_api.g_exc_error;

2516: IF( (p_relationship_query_rec.relationship_type_code IS NULL) OR (p_relationship_query_rec.relationship_type_code = fnd_api.g_miss_char) )
2517: THEN
2518: fnd_message.set_name('CSI','CSI_NO_RELCODE_PASSED');
2519: fnd_msg_pub.add;
2520: RAISE fnd_api.g_exc_error;
2521: END IF;
2522: END IF;
2523: END IF;
2524: /*

Line 2541: -- fnd_api.g_false

2537:
2538: l_ignore := dbms_sql.execute(l_cur_get_relations);
2539: */
2540: -- Bug 8904684 Modified p_get_dfs to take
2541: -- fnd_api.g_false
2542: Get_Children
2543: (p_relationship_query_rec => p_relationship_query_rec,
2544: p_rel_tbl => l_rel_tbl,
2545: p_depth => p_depth,

Line 2548: p_get_dfs => fnd_api.g_false,

2544: p_rel_tbl => l_rel_tbl,
2545: p_depth => p_depth,
2546: p_active_relationship_only => p_active_relationship_only,
2547: p_time_stamp => p_time_stamp,
2548: p_get_dfs => fnd_api.g_false,
2549: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
2550: x_return_status => x_return_status,
2551: x_msg_count => x_msg_count,
2552: x_msg_data => x_msg_data

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

2550: x_return_status => x_return_status,
2551: x_msg_count => x_msg_count,
2552: x_msg_data => x_msg_data
2553: );
2554: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS)
2555: THEN
2556: l_msg_index := 1;
2557: l_msg_count := x_msg_count;
2558: WHILE l_msg_count > 0

Line 2562: FND_API.G_FALSE );

2558: WHILE l_msg_count > 0
2559: LOOP
2560: x_msg_data := FND_MSG_PUB.GET
2561: ( l_msg_index,
2562: FND_API.G_FALSE );
2563: csi_gen_utility_pvt.put_line( ' Error from Get_Chidren.. ');
2564: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2565: l_msg_index := l_msg_index + 1;
2566: l_msg_count := l_msg_count - 1;

Line 2568: RAISE FND_API.G_EXC_ERROR;

2564: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2565: l_msg_index := l_msg_index + 1;
2566: l_msg_count := l_msg_count - 1;
2567: END LOOP;
2568: RAISE FND_API.G_EXC_ERROR;
2569: END IF;
2570:
2571: --
2572: -- Get the last purge date from csi_item_instances table

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

2582: WHEN others THEN
2583: NULL;
2584: END;
2585: --
2586: IF p_time_stamp IS NULL OR p_time_stamp = fnd_api.g_miss_date
2587: THEN
2588: x_relationship_tbl:=l_rel_tbl;
2589: ELSIF l_rel_tbl.COUNT >0
2590: THEN

Line 2612: l_new_rec.relationship_id <> fnd_api.g_miss_num

2608: ,p_time_stamp => p_time_stamp);
2609: END IF;
2610: -- Added by sguthiva for bug 2373109
2611: IF l_new_rec.relationship_id IS NOT NULL AND
2612: l_new_rec.relationship_id <> fnd_api.g_miss_num
2613: THEN
2614: IF l_flag='ADD' THEN
2615: l_relationship_tbl(l_returned_rec_count) :=l_new_rec;
2616: -- Added for bug 2999353

Line 2624: p_depth <> fnd_api.g_miss_num AND

2620: --
2621: l_depth:=0;
2622: IF l_ii_relationship_level_tbl.COUNT > 0 AND
2623: p_depth IS NOT NULL AND
2624: p_depth <> fnd_api.g_miss_num AND
2625: p_depth >0
2626: THEN
2627: FOR l_lvl_csr IN l_ii_relationship_level_tbl.FIRST .. l_ii_relationship_level_tbl.LAST
2628: LOOP

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

2628: LOOP
2629: IF l_ii_relationship_level_tbl.EXISTS(l_lvl_csr)
2630: THEN
2631: IF l_ii_relationship_level_tbl(l_lvl_csr).relationship_id IS NOT NULL AND
2632: l_ii_relationship_level_tbl(l_lvl_csr).relationship_id <> fnd_api.g_miss_num AND
2633: l_ii_relationship_level_tbl(l_lvl_csr).relationship_id =l_relationship_tbl(l_returned_rec_count).relationship_id
2634: THEN
2635: l_depth:=p_depth-l_ii_relationship_level_tbl(l_lvl_csr).current_level;
2636: EXIT;

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

2641: IF l_depth>0 OR
2642: p_depth IS NULL
2643: THEN
2644: l_relationship_query_rec.object_id:=l_relationship_tbl(l_returned_rec_count).subject_id;
2645: l_relationship_query_rec.subject_id:=fnd_api.g_miss_num;
2646: csi_gen_utility_pvt.put_line('Into recurrsive call for get_relationships. ');
2647: csi_ii_relationships_pvt.get_relationships
2648: ( p_api_version => p_api_version
2649: ,p_commit => p_commit

Line 2656: ,p_recursive_flag => fnd_api.g_true

2652: ,p_relationship_query_rec => l_relationship_query_rec
2653: ,p_depth => l_depth
2654: ,p_time_stamp => p_time_stamp
2655: ,p_active_relationship_only => p_active_relationship_only
2656: ,p_recursive_flag => fnd_api.g_true
2657: ,x_relationship_tbl => x_relationship_tbl
2658: ,x_return_status => x_return_status
2659: ,x_msg_count => x_msg_count
2660: ,x_msg_data => x_msg_data

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

2659: ,x_msg_count => x_msg_count
2660: ,x_msg_data => x_msg_data
2661: );
2662:
2663: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS)
2664: THEN
2665: l_msg_index := 1;
2666: l_msg_count := x_msg_count;
2667: WHILE l_msg_count > 0

Line 2671: FND_API.G_FALSE );

2667: WHILE l_msg_count > 0
2668: LOOP
2669: x_msg_data := FND_MSG_PUB.GET
2670: ( l_msg_index,
2671: FND_API.G_FALSE );
2672: csi_gen_utility_pvt.put_line( ' Error from recursive Get_relationships.. ');
2673: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2674: l_msg_index := l_msg_index + 1;
2675: l_msg_count := l_msg_count - 1;

Line 2677: RAISE FND_API.G_EXC_ERROR;

2673: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2674: l_msg_index := l_msg_index + 1;
2675: l_msg_count := l_msg_count - 1;
2676: END LOOP;
2677: RAISE FND_API.G_EXC_ERROR;
2678: END IF;
2679:
2680: IF x_relationship_tbl.count > 0
2681: THEN

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

2683: LOOP
2684: IF x_relationship_tbl.EXISTS(i)
2685: THEN
2686: IF x_relationship_tbl(i).relationship_id IS NOT NULL AND
2687: x_relationship_tbl(i).relationship_id <> fnd_api.g_miss_num
2688: THEN
2689: l_returned_rec_count := l_returned_rec_count + 1;
2690: l_relationship_tbl(l_returned_rec_count):=x_relationship_tbl(i);
2691: END IF;

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

2712: END IF;
2713: -- End addition by sguthiva for bug 2373109
2714:
2715: --
2716: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date) )THEN
2717: IF l_relationship_tbl.count > 0
2718: THEN
2719: BEGIN
2720: SELECT 'Y'

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

2727: EXCEPTION
2728: WHEN OTHERS THEN
2729: --l_relationship_tbl(l_returned_rec_count).subject_has_child := 'N';
2730: IF (l_relationship_tbl(l_returned_rec_count).relationship_id IS NOT NULL --Added for bug 2999353
2731: AND l_relationship_tbl(l_returned_rec_count).relationship_id <> fnd_api.g_miss_num) --Added for bug 2999353
2732: THEN
2733: l_relationship_tbl(l_returned_rec_count).subject_has_child := 'N';
2734: END IF;
2735: END;

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

2756: END LOOP;
2757: END IF;
2758: --
2759: IF l_exists_flag <> 'Y' THEN
2760: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2761: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2762: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2763: THEN
2764: IF p_recursive_flag=fnd_api.g_false

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

2758: --
2759: IF l_exists_flag <> 'Y' THEN
2760: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2761: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2762: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2763: THEN
2764: IF p_recursive_flag=fnd_api.g_false
2765: THEN
2766: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;

Line 2764: IF p_recursive_flag=fnd_api.g_false

2760: IF ( (p_time_stamp IS NOT NULL) AND (p_time_stamp <> fnd_api.g_miss_date)
2761: AND (l_relationship_tbl(rel_row).relationship_id IS NOT NULL --Added for bug 2999353
2762: AND l_relationship_tbl(rel_row).relationship_id <> fnd_api.g_miss_num))--Added for bug 2999353
2763: THEN
2764: IF p_recursive_flag=fnd_api.g_false
2765: THEN
2766: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;
2767: CSI_ITEM_INSTANCE_PUB.Get_item_instance_details(
2768: 1.0,

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

2793: l_instance_rec.instance_id := l_relationship_tbl(rel_row).subject_id;
2794: l_instance_rec.active_end_date := NULL;
2795: END IF;
2796: --
2797: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
2798: l_msg_index := 1;
2799: l_msg_count := x_msg_count;
2800: WHILE l_msg_count > 0 LOOP
2801: x_msg_data := FND_MSG_PUB.GET

Line 2803: FND_API.G_FALSE );

2799: l_msg_count := x_msg_count;
2800: WHILE l_msg_count > 0 LOOP
2801: x_msg_data := FND_MSG_PUB.GET
2802: ( l_msg_index,
2803: FND_API.G_FALSE );
2804: csi_gen_utility_pvt.put_line( ' Error from Get_Item_Instance_Details.. ');
2805: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2806: l_msg_index := l_msg_index + 1;
2807: l_msg_count := l_msg_count - 1;

Line 2809: RAISE FND_API.G_EXC_ERROR;

2805: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
2806: l_msg_index := l_msg_index + 1;
2807: l_msg_count := l_msg_count - 1;
2808: END LOOP;
2809: RAISE FND_API.G_EXC_ERROR;
2810: END IF;
2811: IF nvl(l_instance_rec.active_end_date,(sysdate+1)) < sysdate THEN
2812: l_ctr := l_exp_inst_tbl.count;
2813: l_ctr := l_ctr + 1;

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

2889: LOOP
2890: IF l_temp_relationship_tbl.EXISTS(l_csr)
2891: THEN
2892: IF l_temp_relationship_tbl(l_csr).relationship_id IS NOT NULL AND
2893: l_temp_relationship_tbl(l_csr).relationship_id<> fnd_api.g_miss_num
2894: THEN
2895: IF l_temp_relationship_tbl(l_csr).relationship_type_code<>'COMPONENT-OF'
2896: THEN
2897: l_exp_count:=l_exp_count + 1;

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

2938: LOOP
2939: IF l_exp_tbl.EXISTS(l_exp_csr)
2940: THEN
2941: IF l_exp_tbl(l_exp_csr).relationship_id IS NOT NULL AND
2942: l_exp_tbl(l_exp_csr).relationship_id <> fnd_api.g_miss_num AND
2943: nvl(l_exp_tbl(l_exp_csr).attribute1,'NOT-EXPIRED')<>'EXPIRED'
2944: THEN
2945: l_exp_act_tbl.delete;
2946: -- Used the following procedure instead of a cursor which use

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

3018: IF NOT(l_found1)
3019: THEN
3020: l_fin_count1 :=l_fin_count1+1;
3021: IF l_temp_relationship_tbl(l_tot_csr).relationship_id IS NOT NULL AND
3022: l_temp_relationship_tbl(l_tot_csr).relationship_id <> fnd_api.g_miss_num
3023: THEN
3024: x_relationship_tbl(l_fin_count1):=l_temp_relationship_tbl(l_tot_csr);
3025: END IF;
3026: END IF;

Line 3042: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

3038: -- end of API body
3039: --
3040: -- standard call to get message count and if count is 1, get message info.
3041: fnd_msg_pub.count_AND_get
3042: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
3043: p_count => x_msg_count,
3044: p_data => x_msg_data
3045: );
3046: EXCEPTION

Line 3047: WHEN fnd_api.g_exc_error THEN

3043: p_count => x_msg_count,
3044: p_data => x_msg_data
3045: );
3046: EXCEPTION
3047: WHEN fnd_api.g_exc_error THEN
3048: -- ROLLBACK TO get_relationships_pvt;
3049: x_return_status := fnd_api.g_ret_sts_error ;
3050: fnd_msg_pub.count_AND_get
3051: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 3049: x_return_status := fnd_api.g_ret_sts_error ;

3045: );
3046: EXCEPTION
3047: WHEN fnd_api.g_exc_error THEN
3048: -- ROLLBACK TO get_relationships_pvt;
3049: x_return_status := fnd_api.g_ret_sts_error ;
3050: fnd_msg_pub.count_AND_get
3051: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
3052: p_count => x_msg_count ,
3053: p_data => x_msg_data

Line 3051: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

3047: WHEN fnd_api.g_exc_error THEN
3048: -- ROLLBACK TO get_relationships_pvt;
3049: x_return_status := fnd_api.g_ret_sts_error ;
3050: fnd_msg_pub.count_AND_get
3051: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
3052: p_count => x_msg_count ,
3053: p_data => x_msg_data
3054: );
3055:

Line 3056: WHEN fnd_api.g_exc_unexpected_error THEN

3052: p_count => x_msg_count ,
3053: p_data => x_msg_data
3054: );
3055:
3056: WHEN fnd_api.g_exc_unexpected_error THEN
3057: -- ROLLBACK TO get_relationships_pvt;
3058: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3059: fnd_msg_pub.count_AND_get
3060: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 3058: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3054: );
3055:
3056: WHEN fnd_api.g_exc_unexpected_error THEN
3057: -- ROLLBACK TO get_relationships_pvt;
3058: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3059: fnd_msg_pub.count_AND_get
3060: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
3061: p_count => x_msg_count ,
3062: p_data => x_msg_data

Line 3060: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

3056: WHEN fnd_api.g_exc_unexpected_error THEN
3057: -- ROLLBACK TO get_relationships_pvt;
3058: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3059: fnd_msg_pub.count_AND_get
3060: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
3061: p_count => x_msg_count ,
3062: p_data => x_msg_data
3063: );
3064:

Line 3067: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3063: );
3064:
3065: WHEN OTHERS THEN
3066: -- ROLLBACK TO get_relationships_pvt;
3067: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3068: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
3069: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
3070: END IF;
3071: fnd_msg_pub.count_AND_get

Line 3072: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

3068: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
3069: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
3070: END IF;
3071: fnd_msg_pub.count_AND_get
3072: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
3073: p_count => x_msg_count ,
3074: p_data => x_msg_data
3075: );
3076: END get_relationships;

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

3083: p_subject_id IN NUMBER
3084: ) RETURN BOOLEAN IS
3085:
3086: BEGIN
3087: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num
3088: THEN
3089: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3090: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3091: THEN

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

3085:
3086: BEGIN
3087: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num
3088: THEN
3089: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3090: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3091: THEN
3092: RETURN TRUE;
3093: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)

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

3086: BEGIN
3087: IF p_relship_id is not null AND P_relship_id <> fnd_api.g_miss_num
3088: THEN
3089: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3090: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3091: THEN
3092: RETURN TRUE;
3093: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3094: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))

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

3089: IF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3090: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3091: THEN
3092: RETURN TRUE;
3093: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3094: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
3095: THEN
3096: RETURN FALSE;
3097: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)

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

3090: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3091: THEN
3092: RETURN TRUE;
3093: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3094: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
3095: THEN
3096: RETURN FALSE;
3097: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3098: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))

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

3093: ELSIF ((p_object_id is null OR p_object_id = fnd_api.g_miss_num)
3094: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
3095: THEN
3096: RETURN FALSE;
3097: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3098: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3099: THEN
3100: RETURN TRUE;
3101: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)

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

3094: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
3095: THEN
3096: RETURN FALSE;
3097: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3098: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3099: THEN
3100: RETURN TRUE;
3101: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3102: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))

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

3097: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3098: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3099: THEN
3100: RETURN TRUE;
3101: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3102: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
3103: THEN
3104: RETURN TRUE;
3105: END IF;

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

3098: AND (p_subject_id is null OR p_subject_id = fnd_api.g_miss_num))
3099: THEN
3100: RETURN TRUE;
3101: ELSIF ((p_object_id is not null AND p_object_id <> fnd_api.g_miss_num)
3102: AND (p_subject_id is not null AND p_subject_id <> fnd_api.g_miss_num))
3103: THEN
3104: RETURN TRUE;
3105: END IF;
3106: END IF;

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

3369: l_relship_type_code VARCHAR2(30);
3370: l_dummy VARCHAR2(1) :=NULL;
3371: BEGIN
3372: IF p_relationship_id is not null
3373: AND(p_subject_id is null OR p_subject_id= fnd_api.g_miss_num)
3374: THEN
3375: RETURN TRUE;
3376: ELSE
3377: SELECT subject_id,relationship_type_code

Line 3466: x_return_status := fnd_api.g_ret_sts_success;

3462: CONNECT BY object_id = PRIOR subject_id;
3463: l_dummy VARCHAR2(1); */
3464:
3465: BEGIN
3466: x_return_status := fnd_api.g_ret_sts_success;
3467: IF p_subject_id IS NULL OR
3468: p_subject_id = FND_API.G_MISS_NUM OR
3469: p_object_id IS NULL OR
3470: p_object_id = FND_API.G_MISS_NUM THEN

Line 3468: p_subject_id = FND_API.G_MISS_NUM OR

3464:
3465: BEGIN
3466: x_return_status := fnd_api.g_ret_sts_success;
3467: IF p_subject_id IS NULL OR
3468: p_subject_id = FND_API.G_MISS_NUM OR
3469: p_object_id IS NULL OR
3470: p_object_id = FND_API.G_MISS_NUM THEN
3471: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3472: fnd_msg_pub.add;

Line 3470: p_object_id = FND_API.G_MISS_NUM THEN

3466: x_return_status := fnd_api.g_ret_sts_success;
3467: IF p_subject_id IS NULL OR
3468: p_subject_id = FND_API.G_MISS_NUM OR
3469: p_object_id IS NULL OR
3470: p_object_id = FND_API.G_MISS_NUM THEN
3471: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3472: fnd_msg_pub.add;
3473: x_return_status := fnd_api.g_ret_sts_error;
3474: RETURN;

Line 3473: x_return_status := fnd_api.g_ret_sts_error;

3469: p_object_id IS NULL OR
3470: p_object_id = FND_API.G_MISS_NUM THEN
3471: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3472: fnd_msg_pub.add;
3473: x_return_status := fnd_api.g_ret_sts_error;
3474: RETURN;
3475: END IF;
3476: --
3477: p_relationship_query_rec.object_id := p_subject_id; -- To check for Loop

Line 3485: p_active_relationship_only => FND_API.G_TRUE,

3481: csi_ii_relationships_pvt.Get_Children
3482: ( p_relationship_query_rec => p_relationship_query_rec,
3483: p_rel_tbl => l_rel_tbl,
3484: p_depth => NULL,
3485: p_active_relationship_only => FND_API.G_TRUE,
3486: p_active_instances_only => FND_API.G_FALSE,
3487: p_time_stamp => FND_API.G_MISS_DATE,
3488: p_get_dfs => FND_API.G_FALSE,
3489: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,

Line 3486: p_active_instances_only => FND_API.G_FALSE,

3482: ( p_relationship_query_rec => p_relationship_query_rec,
3483: p_rel_tbl => l_rel_tbl,
3484: p_depth => NULL,
3485: p_active_relationship_only => FND_API.G_TRUE,
3486: p_active_instances_only => FND_API.G_FALSE,
3487: p_time_stamp => FND_API.G_MISS_DATE,
3488: p_get_dfs => FND_API.G_FALSE,
3489: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
3490: x_return_status => x_return_status,

Line 3487: p_time_stamp => FND_API.G_MISS_DATE,

3483: p_rel_tbl => l_rel_tbl,
3484: p_depth => NULL,
3485: p_active_relationship_only => FND_API.G_TRUE,
3486: p_active_instances_only => FND_API.G_FALSE,
3487: p_time_stamp => FND_API.G_MISS_DATE,
3488: p_get_dfs => FND_API.G_FALSE,
3489: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
3490: x_return_status => x_return_status,
3491: x_msg_count => x_msg_count,

Line 3488: p_get_dfs => FND_API.G_FALSE,

3484: p_depth => NULL,
3485: p_active_relationship_only => FND_API.G_TRUE,
3486: p_active_instances_only => FND_API.G_FALSE,
3487: p_time_stamp => FND_API.G_MISS_DATE,
3488: p_get_dfs => FND_API.G_FALSE,
3489: p_ii_relationship_level_tbl => l_ii_relationship_level_tbl,
3490: x_return_status => x_return_status,
3491: x_msg_count => x_msg_count,
3492: x_msg_data => x_msg_data

Line 3495: IF x_return_status = FND_API.G_RET_STS_SUCCESS AND

3491: x_msg_count => x_msg_count,
3492: x_msg_data => x_msg_data
3493: );
3494: --
3495: IF x_return_status = FND_API.G_RET_STS_SUCCESS AND
3496: l_rel_tbl.count > 0 THEN
3497: FOR j in l_rel_tbl.FIRST .. l_rel_tbl.LAST LOOP
3498: IF l_rel_tbl(j).subject_id = p_object_id THEN
3499: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');

Line 3501: x_return_status := fnd_api.g_ret_sts_error;

3497: FOR j in l_rel_tbl.FIRST .. l_rel_tbl.LAST LOOP
3498: IF l_rel_tbl(j).subject_id = p_object_id THEN
3499: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');
3500: fnd_msg_pub.add;
3501: x_return_status := fnd_api.g_ret_sts_error;
3502: exit;
3503: END IF;
3504: END LOOP;
3505: END IF;

Line 3509: x_return_status := fnd_api.g_ret_sts_error;

3505: END IF;
3506: ELSE
3507: fnd_message.set_name('CSI', 'CSI_PARENT_CHILD_INVALID');
3508: fnd_msg_pub.add;
3509: x_return_status := fnd_api.g_ret_sts_error;
3510: END IF;
3511: END check_for_object;
3512:
3513: PROCEDURE validate_history(p_old_relship_rec IN csi_datastructures_pub.ii_relationship_rec,

Line 3586: x_return_status := fnd_api.g_ret_sts_success;

3582:
3583: BEGIN
3584:
3585:
3586: x_return_status := fnd_api.g_ret_sts_success;
3587: --
3588: IF csi_datastructures_pub.g_install_param_rec.fetch_flag IS NULL THEN
3589: csi_gen_utility_pvt.populate_install_param_rec;
3590: END IF;

Line 3597: RAISE FND_API.G_EXC_ERROR;

3593: --
3594: IF l_full_dump IS NULL THEN
3595: FND_MESSAGE.SET_NAME('CSI','CSI_API_GET_FULL_DUMP_FAILED');
3596: FND_MSG_PUB.ADD;
3597: RAISE FND_API.G_EXC_ERROR;
3598: END IF;
3599: --
3600: IF p_flag = 'EXPIRE' THEN
3601: l_new_relship_rec.active_end_date := p_sysdate;

Line 3619: p_relationship_id => fnd_api.g_miss_num ,

3615: IF l_rel_hist_csr.full_dump_flag = 'Y'
3616: THEN
3617: csi_ii_relationships_h_pkg.update_row(
3618: p_relationship_history_id => l_rel_hist_id ,
3619: p_relationship_id => fnd_api.g_miss_num ,
3620: p_transaction_id => fnd_api.g_miss_num ,
3621: p_old_subject_id => fnd_api.g_miss_num ,
3622: p_new_subject_id => l_new_relship_rec.subject_id ,
3623: p_old_position_reference => fnd_api.g_miss_char ,

Line 3620: p_transaction_id => fnd_api.g_miss_num ,

3616: THEN
3617: csi_ii_relationships_h_pkg.update_row(
3618: p_relationship_history_id => l_rel_hist_id ,
3619: p_relationship_id => fnd_api.g_miss_num ,
3620: p_transaction_id => fnd_api.g_miss_num ,
3621: p_old_subject_id => fnd_api.g_miss_num ,
3622: p_new_subject_id => l_new_relship_rec.subject_id ,
3623: p_old_position_reference => fnd_api.g_miss_char ,
3624: p_new_position_reference => l_new_relship_rec.position_reference,

Line 3621: p_old_subject_id => fnd_api.g_miss_num ,

3617: csi_ii_relationships_h_pkg.update_row(
3618: p_relationship_history_id => l_rel_hist_id ,
3619: p_relationship_id => fnd_api.g_miss_num ,
3620: p_transaction_id => fnd_api.g_miss_num ,
3621: p_old_subject_id => fnd_api.g_miss_num ,
3622: p_new_subject_id => l_new_relship_rec.subject_id ,
3623: p_old_position_reference => fnd_api.g_miss_char ,
3624: p_new_position_reference => l_new_relship_rec.position_reference,
3625: p_old_active_start_date => fnd_api.g_miss_date ,

Line 3623: p_old_position_reference => fnd_api.g_miss_char ,

3619: p_relationship_id => fnd_api.g_miss_num ,
3620: p_transaction_id => fnd_api.g_miss_num ,
3621: p_old_subject_id => fnd_api.g_miss_num ,
3622: p_new_subject_id => l_new_relship_rec.subject_id ,
3623: p_old_position_reference => fnd_api.g_miss_char ,
3624: p_new_position_reference => l_new_relship_rec.position_reference,
3625: p_old_active_start_date => fnd_api.g_miss_date ,
3626: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3627: p_old_active_end_date => fnd_api.g_miss_date ,

Line 3625: p_old_active_start_date => fnd_api.g_miss_date ,

3621: p_old_subject_id => fnd_api.g_miss_num ,
3622: p_new_subject_id => l_new_relship_rec.subject_id ,
3623: p_old_position_reference => fnd_api.g_miss_char ,
3624: p_new_position_reference => l_new_relship_rec.position_reference,
3625: p_old_active_start_date => fnd_api.g_miss_date ,
3626: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3627: p_old_active_end_date => fnd_api.g_miss_date ,
3628: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3629: p_old_mandatory_flag => fnd_api.g_miss_char ,

Line 3627: p_old_active_end_date => fnd_api.g_miss_date ,

3623: p_old_position_reference => fnd_api.g_miss_char ,
3624: p_new_position_reference => l_new_relship_rec.position_reference,
3625: p_old_active_start_date => fnd_api.g_miss_date ,
3626: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3627: p_old_active_end_date => fnd_api.g_miss_date ,
3628: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3629: p_old_mandatory_flag => fnd_api.g_miss_char ,
3630: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3631: p_old_context => fnd_api.g_miss_char ,

Line 3629: p_old_mandatory_flag => fnd_api.g_miss_char ,

3625: p_old_active_start_date => fnd_api.g_miss_date ,
3626: p_new_active_start_date => l_new_relship_rec.active_start_date ,
3627: p_old_active_end_date => fnd_api.g_miss_date ,
3628: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3629: p_old_mandatory_flag => fnd_api.g_miss_char ,
3630: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3631: p_old_context => fnd_api.g_miss_char ,
3632: p_new_context => l_new_relship_rec.context ,
3633: p_old_attribute1 => fnd_api.g_miss_char ,

Line 3631: p_old_context => fnd_api.g_miss_char ,

3627: p_old_active_end_date => fnd_api.g_miss_date ,
3628: p_new_active_end_date => l_new_relship_rec.active_end_date ,
3629: p_old_mandatory_flag => fnd_api.g_miss_char ,
3630: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3631: p_old_context => fnd_api.g_miss_char ,
3632: p_new_context => l_new_relship_rec.context ,
3633: p_old_attribute1 => fnd_api.g_miss_char ,
3634: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3635: p_old_attribute2 => fnd_api.g_miss_char ,

Line 3633: p_old_attribute1 => fnd_api.g_miss_char ,

3629: p_old_mandatory_flag => fnd_api.g_miss_char ,
3630: p_new_mandatory_flag => l_new_relship_rec.mandatory_flag ,
3631: p_old_context => fnd_api.g_miss_char ,
3632: p_new_context => l_new_relship_rec.context ,
3633: p_old_attribute1 => fnd_api.g_miss_char ,
3634: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3635: p_old_attribute2 => fnd_api.g_miss_char ,
3636: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3637: p_old_attribute3 => fnd_api.g_miss_char ,

Line 3635: p_old_attribute2 => fnd_api.g_miss_char ,

3631: p_old_context => fnd_api.g_miss_char ,
3632: p_new_context => l_new_relship_rec.context ,
3633: p_old_attribute1 => fnd_api.g_miss_char ,
3634: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3635: p_old_attribute2 => fnd_api.g_miss_char ,
3636: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3637: p_old_attribute3 => fnd_api.g_miss_char ,
3638: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3639: p_old_attribute4 => fnd_api.g_miss_char ,

Line 3637: p_old_attribute3 => fnd_api.g_miss_char ,

3633: p_old_attribute1 => fnd_api.g_miss_char ,
3634: p_new_attribute1 => l_new_relship_rec.attribute1 ,
3635: p_old_attribute2 => fnd_api.g_miss_char ,
3636: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3637: p_old_attribute3 => fnd_api.g_miss_char ,
3638: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3639: p_old_attribute4 => fnd_api.g_miss_char ,
3640: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3641: p_old_attribute5 => fnd_api.g_miss_char ,

Line 3639: p_old_attribute4 => fnd_api.g_miss_char ,

3635: p_old_attribute2 => fnd_api.g_miss_char ,
3636: p_new_attribute2 => l_new_relship_rec.attribute2 ,
3637: p_old_attribute3 => fnd_api.g_miss_char ,
3638: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3639: p_old_attribute4 => fnd_api.g_miss_char ,
3640: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3641: p_old_attribute5 => fnd_api.g_miss_char ,
3642: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3643: p_old_attribute6 => fnd_api.g_miss_char ,

Line 3641: p_old_attribute5 => fnd_api.g_miss_char ,

3637: p_old_attribute3 => fnd_api.g_miss_char ,
3638: p_new_attribute3 => l_new_relship_rec.attribute3 ,
3639: p_old_attribute4 => fnd_api.g_miss_char ,
3640: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3641: p_old_attribute5 => fnd_api.g_miss_char ,
3642: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3643: p_old_attribute6 => fnd_api.g_miss_char ,
3644: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3645: p_old_attribute7 => fnd_api.g_miss_char ,

Line 3643: p_old_attribute6 => fnd_api.g_miss_char ,

3639: p_old_attribute4 => fnd_api.g_miss_char ,
3640: p_new_attribute4 => l_new_relship_rec.attribute4 ,
3641: p_old_attribute5 => fnd_api.g_miss_char ,
3642: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3643: p_old_attribute6 => fnd_api.g_miss_char ,
3644: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3645: p_old_attribute7 => fnd_api.g_miss_char ,
3646: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3647: p_old_attribute8 => fnd_api.g_miss_char ,

Line 3645: p_old_attribute7 => fnd_api.g_miss_char ,

3641: p_old_attribute5 => fnd_api.g_miss_char ,
3642: p_new_attribute5 => l_new_relship_rec.attribute5 ,
3643: p_old_attribute6 => fnd_api.g_miss_char ,
3644: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3645: p_old_attribute7 => fnd_api.g_miss_char ,
3646: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3647: p_old_attribute8 => fnd_api.g_miss_char ,
3648: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3649: p_old_attribute9 => fnd_api.g_miss_char ,

Line 3647: p_old_attribute8 => fnd_api.g_miss_char ,

3643: p_old_attribute6 => fnd_api.g_miss_char ,
3644: p_new_attribute6 => l_new_relship_rec.attribute6 ,
3645: p_old_attribute7 => fnd_api.g_miss_char ,
3646: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3647: p_old_attribute8 => fnd_api.g_miss_char ,
3648: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3649: p_old_attribute9 => fnd_api.g_miss_char ,
3650: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3651: p_old_attribute10 => fnd_api.g_miss_char ,

Line 3649: p_old_attribute9 => fnd_api.g_miss_char ,

3645: p_old_attribute7 => fnd_api.g_miss_char ,
3646: p_new_attribute7 => l_new_relship_rec.attribute7 ,
3647: p_old_attribute8 => fnd_api.g_miss_char ,
3648: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3649: p_old_attribute9 => fnd_api.g_miss_char ,
3650: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3651: p_old_attribute10 => fnd_api.g_miss_char ,
3652: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3653: p_old_attribute11 => fnd_api.g_miss_char ,

Line 3651: p_old_attribute10 => fnd_api.g_miss_char ,

3647: p_old_attribute8 => fnd_api.g_miss_char ,
3648: p_new_attribute8 => l_new_relship_rec.attribute8 ,
3649: p_old_attribute9 => fnd_api.g_miss_char ,
3650: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3651: p_old_attribute10 => fnd_api.g_miss_char ,
3652: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3653: p_old_attribute11 => fnd_api.g_miss_char ,
3654: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3655: p_old_attribute12 => fnd_api.g_miss_char ,

Line 3653: p_old_attribute11 => fnd_api.g_miss_char ,

3649: p_old_attribute9 => fnd_api.g_miss_char ,
3650: p_new_attribute9 => l_new_relship_rec.attribute9 ,
3651: p_old_attribute10 => fnd_api.g_miss_char ,
3652: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3653: p_old_attribute11 => fnd_api.g_miss_char ,
3654: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3655: p_old_attribute12 => fnd_api.g_miss_char ,
3656: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3657: p_old_attribute13 => fnd_api.g_miss_char ,

Line 3655: p_old_attribute12 => fnd_api.g_miss_char ,

3651: p_old_attribute10 => fnd_api.g_miss_char ,
3652: p_new_attribute10 => l_new_relship_rec.attribute10 ,
3653: p_old_attribute11 => fnd_api.g_miss_char ,
3654: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3655: p_old_attribute12 => fnd_api.g_miss_char ,
3656: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3657: p_old_attribute13 => fnd_api.g_miss_char ,
3658: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3659: p_old_attribute14 => fnd_api.g_miss_char ,

Line 3657: p_old_attribute13 => fnd_api.g_miss_char ,

3653: p_old_attribute11 => fnd_api.g_miss_char ,
3654: p_new_attribute11 => l_new_relship_rec.attribute11 ,
3655: p_old_attribute12 => fnd_api.g_miss_char ,
3656: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3657: p_old_attribute13 => fnd_api.g_miss_char ,
3658: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3659: p_old_attribute14 => fnd_api.g_miss_char ,
3660: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3661: p_old_attribute15 => fnd_api.g_miss_char ,

Line 3659: p_old_attribute14 => fnd_api.g_miss_char ,

3655: p_old_attribute12 => fnd_api.g_miss_char ,
3656: p_new_attribute12 => l_new_relship_rec.attribute12 ,
3657: p_old_attribute13 => fnd_api.g_miss_char ,
3658: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3659: p_old_attribute14 => fnd_api.g_miss_char ,
3660: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3661: p_old_attribute15 => fnd_api.g_miss_char ,
3662: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3663: p_full_dump_flag => fnd_api.g_miss_char ,

Line 3661: p_old_attribute15 => fnd_api.g_miss_char ,

3657: p_old_attribute13 => fnd_api.g_miss_char ,
3658: p_new_attribute13 => l_new_relship_rec.attribute13 ,
3659: p_old_attribute14 => fnd_api.g_miss_char ,
3660: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3661: p_old_attribute15 => fnd_api.g_miss_char ,
3662: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3663: p_full_dump_flag => fnd_api.g_miss_char ,
3664: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3665: p_creation_date => fnd_api.g_miss_date ,

Line 3663: p_full_dump_flag => fnd_api.g_miss_char ,

3659: p_old_attribute14 => fnd_api.g_miss_char ,
3660: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3661: p_old_attribute15 => fnd_api.g_miss_char ,
3662: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3663: p_full_dump_flag => fnd_api.g_miss_char ,
3664: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3665: p_creation_date => fnd_api.g_miss_date ,
3666: p_last_updated_by => fnd_global.user_id ,
3667: p_last_update_date => SYSDATE ,

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

3660: p_new_attribute14 => l_new_relship_rec.attribute14 ,
3661: p_old_attribute15 => fnd_api.g_miss_char ,
3662: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3663: p_full_dump_flag => fnd_api.g_miss_char ,
3664: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3665: p_creation_date => fnd_api.g_miss_date ,
3666: p_last_updated_by => fnd_global.user_id ,
3667: p_last_update_date => SYSDATE ,
3668: p_last_update_login => fnd_global.conc_login_id ,

Line 3665: p_creation_date => fnd_api.g_miss_date ,

3661: p_old_attribute15 => fnd_api.g_miss_char ,
3662: p_new_attribute15 => l_new_relship_rec.attribute15 ,
3663: p_full_dump_flag => fnd_api.g_miss_char ,
3664: p_created_by => fnd_api.g_miss_num, -- fnd_global.user_id,
3665: p_creation_date => fnd_api.g_miss_date ,
3666: p_last_updated_by => fnd_global.user_id ,
3667: p_last_update_date => SYSDATE ,
3668: p_last_update_login => fnd_global.conc_login_id ,
3669: p_object_version_number => fnd_api.g_miss_num );

Line 3669: p_object_version_number => fnd_api.g_miss_num );

3665: p_creation_date => fnd_api.g_miss_date ,
3666: p_last_updated_by => fnd_global.user_id ,
3667: p_last_update_date => SYSDATE ,
3668: p_last_update_login => fnd_global.conc_login_id ,
3669: p_object_version_number => fnd_api.g_miss_num );
3670: ELSE
3671: --
3672: IF ( l_rel_hist_csr.old_subject_id IS NULL
3673: AND l_rel_hist_csr.new_subject_id IS NULL ) THEN

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

3671: --
3672: IF ( l_rel_hist_csr.old_subject_id IS NULL
3673: AND l_rel_hist_csr.new_subject_id IS NULL ) THEN
3674: IF ( l_new_relship_rec.subject_id = l_old_relship_rec.subject_id )
3675: OR ( l_new_relship_rec.subject_id = fnd_api.g_miss_num ) THEN
3676: l_rel_hist_csr.old_subject_id := NULL;
3677: l_rel_hist_csr.new_subject_id := NULL;
3678: ELSE
3679: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;

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

3675: OR ( l_new_relship_rec.subject_id = fnd_api.g_miss_num ) THEN
3676: l_rel_hist_csr.old_subject_id := NULL;
3677: l_rel_hist_csr.new_subject_id := NULL;
3678: ELSE
3679: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;
3680: l_rel_hist_csr.new_subject_id := l_new_relship_rec.subject_id;
3681: END IF;
3682: ELSE
3683: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;

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

3679: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;
3680: l_rel_hist_csr.new_subject_id := l_new_relship_rec.subject_id;
3681: END IF;
3682: ELSE
3683: l_rel_hist_csr.old_subject_id := fnd_api.g_miss_num;
3684: l_rel_hist_csr.new_subject_id := l_new_relship_rec.subject_id;
3685: END IF;
3686: --
3687: IF ( l_rel_hist_csr.old_position_reference IS NULL

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

3686: --
3687: IF ( l_rel_hist_csr.old_position_reference IS NULL
3688: AND l_rel_hist_csr.new_position_reference IS NULL ) THEN
3689: IF ( l_new_relship_rec.position_reference = l_old_relship_rec.position_reference )
3690: OR ( l_new_relship_rec.position_reference = fnd_api.g_miss_char ) THEN
3691: l_rel_hist_csr.old_position_reference := NULL;
3692: l_rel_hist_csr.new_position_reference := NULL;
3693: ELSE
3694: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;

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

3690: OR ( l_new_relship_rec.position_reference = fnd_api.g_miss_char ) THEN
3691: l_rel_hist_csr.old_position_reference := NULL;
3692: l_rel_hist_csr.new_position_reference := NULL;
3693: ELSE
3694: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;
3695: l_rel_hist_csr.new_position_reference := l_new_relship_rec.position_reference;
3696: END IF;
3697: ELSE
3698: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;

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

3694: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;
3695: l_rel_hist_csr.new_position_reference := l_new_relship_rec.position_reference;
3696: END IF;
3697: ELSE
3698: l_rel_hist_csr.old_position_reference := fnd_api.g_miss_char;
3699: l_rel_hist_csr.new_position_reference := l_new_relship_rec.position_reference;
3700: END IF;
3701: --
3702: IF ( l_rel_hist_csr.old_active_start_date IS NULL

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

3701: --
3702: IF ( l_rel_hist_csr.old_active_start_date IS NULL
3703: AND l_rel_hist_csr.new_active_start_date IS NULL ) THEN
3704: IF ( l_new_relship_rec.active_start_date = l_old_relship_rec.active_start_date )
3705: OR ( l_new_relship_rec.active_start_date = fnd_api.g_miss_date ) THEN
3706: l_rel_hist_csr.old_active_start_date := NULL;
3707: l_rel_hist_csr.new_active_start_date := NULL;
3708: ELSE
3709: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;

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

3705: OR ( l_new_relship_rec.active_start_date = fnd_api.g_miss_date ) THEN
3706: l_rel_hist_csr.old_active_start_date := NULL;
3707: l_rel_hist_csr.new_active_start_date := NULL;
3708: ELSE
3709: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;
3710: l_rel_hist_csr.new_active_start_date := l_new_relship_rec.active_start_date;
3711: END IF;
3712: ELSE
3713: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;

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

3709: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;
3710: l_rel_hist_csr.new_active_start_date := l_new_relship_rec.active_start_date;
3711: END IF;
3712: ELSE
3713: l_rel_hist_csr.old_active_start_date := fnd_api.g_miss_date;
3714: l_rel_hist_csr.new_active_start_date := l_new_relship_rec.active_start_date;
3715: END IF;
3716: --
3717: IF ( l_rel_hist_csr.old_active_end_date IS NULL

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

3716: --
3717: IF ( l_rel_hist_csr.old_active_end_date IS NULL
3718: AND l_rel_hist_csr.new_active_end_date IS NULL ) THEN
3719: IF ( l_new_relship_rec.active_end_date = l_old_relship_rec.active_end_date )
3720: OR ( l_new_relship_rec.active_end_date = fnd_api.g_miss_date ) THEN
3721: l_rel_hist_csr.old_active_end_date := NULL;
3722: l_rel_hist_csr.new_active_end_date := NULL;
3723: ELSE
3724: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;

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

3720: OR ( l_new_relship_rec.active_end_date = fnd_api.g_miss_date ) THEN
3721: l_rel_hist_csr.old_active_end_date := NULL;
3722: l_rel_hist_csr.new_active_end_date := NULL;
3723: ELSE
3724: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;
3725: l_rel_hist_csr.new_active_end_date := l_new_relship_rec.active_end_date;
3726: END IF;
3727: ELSE
3728: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;

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

3724: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;
3725: l_rel_hist_csr.new_active_end_date := l_new_relship_rec.active_end_date;
3726: END IF;
3727: ELSE
3728: l_rel_hist_csr.old_active_end_date := fnd_api.g_miss_date;
3729: l_rel_hist_csr.new_active_end_date := l_new_relship_rec.active_end_date;
3730: END IF;
3731: --
3732: IF ( l_rel_hist_csr.old_mandatory_flag IS NULL

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

3731: --
3732: IF ( l_rel_hist_csr.old_mandatory_flag IS NULL
3733: AND l_rel_hist_csr.new_mandatory_flag IS NULL ) THEN
3734: IF ( l_new_relship_rec.mandatory_flag = l_old_relship_rec.mandatory_flag )
3735: OR ( l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char ) THEN
3736: l_rel_hist_csr.old_mandatory_flag := NULL;
3737: l_rel_hist_csr.new_mandatory_flag := NULL;
3738: ELSE
3739: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;

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

3735: OR ( l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char ) THEN
3736: l_rel_hist_csr.old_mandatory_flag := NULL;
3737: l_rel_hist_csr.new_mandatory_flag := NULL;
3738: ELSE
3739: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;
3740: l_rel_hist_csr.new_mandatory_flag := l_new_relship_rec.mandatory_flag;
3741: END IF;
3742: ELSE
3743: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;

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

3739: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;
3740: l_rel_hist_csr.new_mandatory_flag := l_new_relship_rec.mandatory_flag;
3741: END IF;
3742: ELSE
3743: l_rel_hist_csr.old_mandatory_flag := fnd_api.g_miss_char;
3744: l_rel_hist_csr.new_mandatory_flag := l_new_relship_rec.mandatory_flag;
3745: END IF;
3746: --
3747: IF ( l_rel_hist_csr.old_context IS NULL

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

3746: --
3747: IF ( l_rel_hist_csr.old_context IS NULL
3748: AND l_rel_hist_csr.new_context IS NULL ) THEN
3749: IF ( l_new_relship_rec.context = l_old_relship_rec.context )
3750: OR ( l_new_relship_rec.context = fnd_api.g_miss_char ) THEN
3751: l_rel_hist_csr.old_context := NULL;
3752: l_rel_hist_csr.new_context := NULL;
3753: ELSE
3754: l_rel_hist_csr.old_context := fnd_api.g_miss_char;

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

3750: OR ( l_new_relship_rec.context = fnd_api.g_miss_char ) THEN
3751: l_rel_hist_csr.old_context := NULL;
3752: l_rel_hist_csr.new_context := NULL;
3753: ELSE
3754: l_rel_hist_csr.old_context := fnd_api.g_miss_char;
3755: l_rel_hist_csr.new_context := l_new_relship_rec.context;
3756: END IF;
3757: ELSE
3758: l_rel_hist_csr.old_context := fnd_api.g_miss_char;

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

3754: l_rel_hist_csr.old_context := fnd_api.g_miss_char;
3755: l_rel_hist_csr.new_context := l_new_relship_rec.context;
3756: END IF;
3757: ELSE
3758: l_rel_hist_csr.old_context := fnd_api.g_miss_char;
3759: l_rel_hist_csr.new_context := l_new_relship_rec.context;
3760: END IF;
3761: --
3762: IF ( l_rel_hist_csr.old_attribute1 IS NULL

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

3761: --
3762: IF ( l_rel_hist_csr.old_attribute1 IS NULL
3763: AND l_rel_hist_csr.new_attribute1 IS NULL ) THEN
3764: IF ( l_new_relship_rec.attribute1 = l_old_relship_rec.attribute1 )
3765: OR ( l_new_relship_rec.attribute1 = fnd_api.g_miss_char ) THEN
3766: l_rel_hist_csr.old_attribute1 := NULL;
3767: l_rel_hist_csr.new_attribute1 := NULL;
3768: ELSE
3769: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;

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

3765: OR ( l_new_relship_rec.attribute1 = fnd_api.g_miss_char ) THEN
3766: l_rel_hist_csr.old_attribute1 := NULL;
3767: l_rel_hist_csr.new_attribute1 := NULL;
3768: ELSE
3769: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;
3770: l_rel_hist_csr.new_attribute1 := l_new_relship_rec.attribute1;
3771: END IF;
3772: ELSE
3773: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;

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

3769: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;
3770: l_rel_hist_csr.new_attribute1 := l_new_relship_rec.attribute1;
3771: END IF;
3772: ELSE
3773: l_rel_hist_csr.old_attribute1 := fnd_api.g_miss_char;
3774: l_rel_hist_csr.new_attribute1 := l_new_relship_rec.attribute1;
3775: END IF;
3776: --
3777: IF ( l_rel_hist_csr.old_attribute2 IS NULL

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

3776: --
3777: IF ( l_rel_hist_csr.old_attribute2 IS NULL
3778: AND l_rel_hist_csr.new_attribute2 IS NULL ) THEN
3779: IF ( l_new_relship_rec.attribute2 = l_old_relship_rec.attribute2 )
3780: OR ( l_new_relship_rec.attribute2 = fnd_api.g_miss_char ) THEN
3781: l_rel_hist_csr.old_attribute2 := NULL;
3782: l_rel_hist_csr.new_attribute2 := NULL;
3783: ELSE
3784: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;

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

3780: OR ( l_new_relship_rec.attribute2 = fnd_api.g_miss_char ) THEN
3781: l_rel_hist_csr.old_attribute2 := NULL;
3782: l_rel_hist_csr.new_attribute2 := NULL;
3783: ELSE
3784: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;
3785: l_rel_hist_csr.new_attribute2 := l_new_relship_rec.attribute2;
3786: END IF;
3787: ELSE
3788: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;

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

3784: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;
3785: l_rel_hist_csr.new_attribute2 := l_new_relship_rec.attribute2;
3786: END IF;
3787: ELSE
3788: l_rel_hist_csr.old_attribute2 := fnd_api.g_miss_char;
3789: l_rel_hist_csr.new_attribute2 := l_new_relship_rec.attribute2;
3790: END IF;
3791: --
3792: IF ( l_rel_hist_csr.old_attribute3 IS NULL

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

3791: --
3792: IF ( l_rel_hist_csr.old_attribute3 IS NULL
3793: AND l_rel_hist_csr.new_attribute3 IS NULL ) THEN
3794: IF ( l_new_relship_rec.attribute3 = l_old_relship_rec.attribute3 )
3795: OR ( l_new_relship_rec.attribute3 = fnd_api.g_miss_char ) THEN
3796: l_rel_hist_csr.old_attribute3 := NULL;
3797: l_rel_hist_csr.new_attribute3 := NULL;
3798: ELSE
3799: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;

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

3795: OR ( l_new_relship_rec.attribute3 = fnd_api.g_miss_char ) THEN
3796: l_rel_hist_csr.old_attribute3 := NULL;
3797: l_rel_hist_csr.new_attribute3 := NULL;
3798: ELSE
3799: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;
3800: l_rel_hist_csr.new_attribute3 := l_new_relship_rec.attribute3;
3801: END IF;
3802: ELSE
3803: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;

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

3799: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;
3800: l_rel_hist_csr.new_attribute3 := l_new_relship_rec.attribute3;
3801: END IF;
3802: ELSE
3803: l_rel_hist_csr.old_attribute3 := fnd_api.g_miss_char;
3804: l_rel_hist_csr.new_attribute3 := l_new_relship_rec.attribute3;
3805: END IF;
3806: --
3807: IF ( l_rel_hist_csr.old_attribute4 IS NULL

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

3806: --
3807: IF ( l_rel_hist_csr.old_attribute4 IS NULL
3808: AND l_rel_hist_csr.new_attribute4 IS NULL ) THEN
3809: IF ( l_new_relship_rec.attribute4 = l_old_relship_rec.attribute4 )
3810: OR ( l_new_relship_rec.attribute4 = fnd_api.g_miss_char ) THEN
3811: l_rel_hist_csr.old_attribute4 := NULL;
3812: l_rel_hist_csr.new_attribute4 := NULL;
3813: ELSE
3814: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;

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

3810: OR ( l_new_relship_rec.attribute4 = fnd_api.g_miss_char ) THEN
3811: l_rel_hist_csr.old_attribute4 := NULL;
3812: l_rel_hist_csr.new_attribute4 := NULL;
3813: ELSE
3814: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;
3815: l_rel_hist_csr.new_attribute4 := l_new_relship_rec.attribute4;
3816: END IF;
3817: ELSE
3818: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;

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

3814: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;
3815: l_rel_hist_csr.new_attribute4 := l_new_relship_rec.attribute4;
3816: END IF;
3817: ELSE
3818: l_rel_hist_csr.old_attribute4 := fnd_api.g_miss_char;
3819: l_rel_hist_csr.new_attribute4 := l_new_relship_rec.attribute4;
3820: END IF;
3821: --
3822: IF ( l_rel_hist_csr.old_attribute5 IS NULL

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

3821: --
3822: IF ( l_rel_hist_csr.old_attribute5 IS NULL
3823: AND l_rel_hist_csr.new_attribute5 IS NULL ) THEN
3824: IF ( l_new_relship_rec.attribute5 = l_old_relship_rec.attribute5 )
3825: OR ( l_new_relship_rec.attribute5 = fnd_api.g_miss_char ) THEN
3826: l_rel_hist_csr.old_attribute5 := NULL;
3827: l_rel_hist_csr.new_attribute5 := NULL;
3828: ELSE
3829: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;

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

3825: OR ( l_new_relship_rec.attribute5 = fnd_api.g_miss_char ) THEN
3826: l_rel_hist_csr.old_attribute5 := NULL;
3827: l_rel_hist_csr.new_attribute5 := NULL;
3828: ELSE
3829: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;
3830: l_rel_hist_csr.new_attribute5 := l_new_relship_rec.attribute5;
3831: END IF;
3832: ELSE
3833: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;

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

3829: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;
3830: l_rel_hist_csr.new_attribute5 := l_new_relship_rec.attribute5;
3831: END IF;
3832: ELSE
3833: l_rel_hist_csr.old_attribute5 := fnd_api.g_miss_char;
3834: l_rel_hist_csr.new_attribute5 := l_new_relship_rec.attribute5;
3835: END IF;
3836: --
3837: IF ( l_rel_hist_csr.old_attribute6 IS NULL

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

3836: --
3837: IF ( l_rel_hist_csr.old_attribute6 IS NULL
3838: AND l_rel_hist_csr.new_attribute6 IS NULL ) THEN
3839: IF ( l_new_relship_rec.attribute6 = l_old_relship_rec.attribute6 )
3840: OR ( l_new_relship_rec.attribute6 = fnd_api.g_miss_char ) THEN
3841: l_rel_hist_csr.old_attribute6 := NULL;
3842: l_rel_hist_csr.new_attribute6 := NULL;
3843: ELSE
3844: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;

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

3840: OR ( l_new_relship_rec.attribute6 = fnd_api.g_miss_char ) THEN
3841: l_rel_hist_csr.old_attribute6 := NULL;
3842: l_rel_hist_csr.new_attribute6 := NULL;
3843: ELSE
3844: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;
3845: l_rel_hist_csr.new_attribute6 := l_new_relship_rec.attribute6;
3846: END IF;
3847: ELSE
3848: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;

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

3844: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;
3845: l_rel_hist_csr.new_attribute6 := l_new_relship_rec.attribute6;
3846: END IF;
3847: ELSE
3848: l_rel_hist_csr.old_attribute6 := fnd_api.g_miss_char;
3849: l_rel_hist_csr.new_attribute6 := l_new_relship_rec.attribute6;
3850: END IF;
3851: --
3852: IF ( l_rel_hist_csr.old_attribute7 IS NULL

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

3851: --
3852: IF ( l_rel_hist_csr.old_attribute7 IS NULL
3853: AND l_rel_hist_csr.new_attribute7 IS NULL ) THEN
3854: IF ( l_new_relship_rec.attribute7 = l_old_relship_rec.attribute7 )
3855: OR ( l_new_relship_rec.attribute7 = fnd_api.g_miss_char ) THEN
3856: l_rel_hist_csr.old_attribute7 := NULL;
3857: l_rel_hist_csr.new_attribute7 := NULL;
3858: ELSE
3859: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;

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

3855: OR ( l_new_relship_rec.attribute7 = fnd_api.g_miss_char ) THEN
3856: l_rel_hist_csr.old_attribute7 := NULL;
3857: l_rel_hist_csr.new_attribute7 := NULL;
3858: ELSE
3859: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;
3860: l_rel_hist_csr.new_attribute7 := l_new_relship_rec.attribute7;
3861: END IF;
3862: ELSE
3863: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;

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

3859: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;
3860: l_rel_hist_csr.new_attribute7 := l_new_relship_rec.attribute7;
3861: END IF;
3862: ELSE
3863: l_rel_hist_csr.old_attribute7 := fnd_api.g_miss_char;
3864: l_rel_hist_csr.new_attribute7 := l_new_relship_rec.attribute7;
3865: END IF;
3866: --
3867: IF ( l_rel_hist_csr.old_attribute8 IS NULL

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

3866: --
3867: IF ( l_rel_hist_csr.old_attribute8 IS NULL
3868: AND l_rel_hist_csr.new_attribute8 IS NULL ) THEN
3869: IF ( l_new_relship_rec.attribute8 = l_old_relship_rec.attribute8 )
3870: OR ( l_new_relship_rec.attribute8 = fnd_api.g_miss_char ) THEN
3871: l_rel_hist_csr.old_attribute8 := NULL;
3872: l_rel_hist_csr.new_attribute8 := NULL;
3873: ELSE
3874: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;

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

3870: OR ( l_new_relship_rec.attribute8 = fnd_api.g_miss_char ) THEN
3871: l_rel_hist_csr.old_attribute8 := NULL;
3872: l_rel_hist_csr.new_attribute8 := NULL;
3873: ELSE
3874: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;
3875: l_rel_hist_csr.new_attribute8 := l_new_relship_rec.attribute8;
3876: END IF;
3877: ELSE
3878: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;

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

3874: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;
3875: l_rel_hist_csr.new_attribute8 := l_new_relship_rec.attribute8;
3876: END IF;
3877: ELSE
3878: l_rel_hist_csr.old_attribute8 := fnd_api.g_miss_char;
3879: l_rel_hist_csr.new_attribute8 := l_new_relship_rec.attribute8;
3880: END IF;
3881: --
3882: IF ( l_rel_hist_csr.old_attribute9 IS NULL

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

3881: --
3882: IF ( l_rel_hist_csr.old_attribute9 IS NULL
3883: AND l_rel_hist_csr.new_attribute9 IS NULL ) THEN
3884: IF ( l_new_relship_rec.attribute9 = l_old_relship_rec.attribute9 )
3885: OR ( l_new_relship_rec.attribute9 = fnd_api.g_miss_char ) THEN
3886: l_rel_hist_csr.old_attribute9 := NULL;
3887: l_rel_hist_csr.new_attribute9 := NULL;
3888: ELSE
3889: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;

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

3885: OR ( l_new_relship_rec.attribute9 = fnd_api.g_miss_char ) THEN
3886: l_rel_hist_csr.old_attribute9 := NULL;
3887: l_rel_hist_csr.new_attribute9 := NULL;
3888: ELSE
3889: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;
3890: l_rel_hist_csr.new_attribute9 := l_new_relship_rec.attribute9;
3891: END IF;
3892: ELSE
3893: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;

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

3889: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;
3890: l_rel_hist_csr.new_attribute9 := l_new_relship_rec.attribute9;
3891: END IF;
3892: ELSE
3893: l_rel_hist_csr.old_attribute9 := fnd_api.g_miss_char;
3894: l_rel_hist_csr.new_attribute9 := l_new_relship_rec.attribute9;
3895: END IF;
3896: --
3897: IF ( l_rel_hist_csr.old_attribute10 IS NULL

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

3896: --
3897: IF ( l_rel_hist_csr.old_attribute10 IS NULL
3898: AND l_rel_hist_csr.new_attribute10 IS NULL ) THEN
3899: IF ( l_new_relship_rec.attribute10 = l_old_relship_rec.attribute10 )
3900: OR ( l_new_relship_rec.attribute10 = fnd_api.g_miss_char ) THEN
3901: l_rel_hist_csr.old_attribute10 := NULL;
3902: l_rel_hist_csr.new_attribute10 := NULL;
3903: ELSE
3904: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;

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

3900: OR ( l_new_relship_rec.attribute10 = fnd_api.g_miss_char ) THEN
3901: l_rel_hist_csr.old_attribute10 := NULL;
3902: l_rel_hist_csr.new_attribute10 := NULL;
3903: ELSE
3904: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;
3905: l_rel_hist_csr.new_attribute10 := l_new_relship_rec.attribute10;
3906: END IF;
3907: ELSE
3908: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;

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

3904: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;
3905: l_rel_hist_csr.new_attribute10 := l_new_relship_rec.attribute10;
3906: END IF;
3907: ELSE
3908: l_rel_hist_csr.old_attribute10 := fnd_api.g_miss_char;
3909: l_rel_hist_csr.new_attribute10 := l_new_relship_rec.attribute10;
3910: END IF;
3911: --
3912: IF ( l_rel_hist_csr.old_attribute11 IS NULL

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

3911: --
3912: IF ( l_rel_hist_csr.old_attribute11 IS NULL
3913: AND l_rel_hist_csr.new_attribute11 IS NULL ) THEN
3914: IF ( l_new_relship_rec.attribute11 = l_old_relship_rec.attribute11 )
3915: OR ( l_new_relship_rec.attribute11 = fnd_api.g_miss_char ) THEN
3916: l_rel_hist_csr.old_attribute11 := NULL;
3917: l_rel_hist_csr.new_attribute11 := NULL;
3918: ELSE
3919: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;

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

3915: OR ( l_new_relship_rec.attribute11 = fnd_api.g_miss_char ) THEN
3916: l_rel_hist_csr.old_attribute11 := NULL;
3917: l_rel_hist_csr.new_attribute11 := NULL;
3918: ELSE
3919: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;
3920: l_rel_hist_csr.new_attribute11 := l_new_relship_rec.attribute11;
3921: END IF;
3922: ELSE
3923: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;

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

3919: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;
3920: l_rel_hist_csr.new_attribute11 := l_new_relship_rec.attribute11;
3921: END IF;
3922: ELSE
3923: l_rel_hist_csr.old_attribute11 := fnd_api.g_miss_char;
3924: l_rel_hist_csr.new_attribute11 := l_new_relship_rec.attribute11;
3925: END IF;
3926: --
3927: IF ( l_rel_hist_csr.old_attribute12 IS NULL

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

3926: --
3927: IF ( l_rel_hist_csr.old_attribute12 IS NULL
3928: AND l_rel_hist_csr.new_attribute12 IS NULL ) THEN
3929: IF ( l_new_relship_rec.attribute12 = l_old_relship_rec.attribute12 )
3930: OR ( l_new_relship_rec.attribute12 = fnd_api.g_miss_char ) THEN
3931: l_rel_hist_csr.old_attribute12 := NULL;
3932: l_rel_hist_csr.new_attribute12 := NULL;
3933: ELSE
3934: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;

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

3930: OR ( l_new_relship_rec.attribute12 = fnd_api.g_miss_char ) THEN
3931: l_rel_hist_csr.old_attribute12 := NULL;
3932: l_rel_hist_csr.new_attribute12 := NULL;
3933: ELSE
3934: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;
3935: l_rel_hist_csr.new_attribute12 := l_new_relship_rec.attribute12;
3936: END IF;
3937: ELSE
3938: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;

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

3934: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;
3935: l_rel_hist_csr.new_attribute12 := l_new_relship_rec.attribute12;
3936: END IF;
3937: ELSE
3938: l_rel_hist_csr.old_attribute12 := fnd_api.g_miss_char;
3939: l_rel_hist_csr.new_attribute12 := l_new_relship_rec.attribute12;
3940: END IF;
3941: --
3942: IF ( l_rel_hist_csr.old_attribute13 IS NULL

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

3941: --
3942: IF ( l_rel_hist_csr.old_attribute13 IS NULL
3943: AND l_rel_hist_csr.new_attribute13 IS NULL ) THEN
3944: IF ( l_new_relship_rec.attribute13 = l_old_relship_rec.attribute13 )
3945: OR ( l_new_relship_rec.attribute13 = fnd_api.g_miss_char ) THEN
3946: l_rel_hist_csr.old_attribute13 := NULL;
3947: l_rel_hist_csr.new_attribute13 := NULL;
3948: ELSE
3949: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;

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

3945: OR ( l_new_relship_rec.attribute13 = fnd_api.g_miss_char ) THEN
3946: l_rel_hist_csr.old_attribute13 := NULL;
3947: l_rel_hist_csr.new_attribute13 := NULL;
3948: ELSE
3949: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;
3950: l_rel_hist_csr.new_attribute13 := l_new_relship_rec.attribute13;
3951: END IF;
3952: ELSE
3953: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;

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

3949: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;
3950: l_rel_hist_csr.new_attribute13 := l_new_relship_rec.attribute13;
3951: END IF;
3952: ELSE
3953: l_rel_hist_csr.old_attribute13 := fnd_api.g_miss_char;
3954: l_rel_hist_csr.new_attribute13 := l_new_relship_rec.attribute13;
3955: END IF;
3956: --
3957: IF ( l_rel_hist_csr.old_attribute14 IS NULL

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

3956: --
3957: IF ( l_rel_hist_csr.old_attribute14 IS NULL
3958: AND l_rel_hist_csr.new_attribute14 IS NULL ) THEN
3959: IF ( l_new_relship_rec.attribute14 = l_old_relship_rec.attribute14 )
3960: OR ( l_new_relship_rec.attribute14 = fnd_api.g_miss_char ) THEN
3961: l_rel_hist_csr.old_attribute14 := NULL;
3962: l_rel_hist_csr.new_attribute14 := NULL;
3963: ELSE
3964: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;

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

3960: OR ( l_new_relship_rec.attribute14 = fnd_api.g_miss_char ) THEN
3961: l_rel_hist_csr.old_attribute14 := NULL;
3962: l_rel_hist_csr.new_attribute14 := NULL;
3963: ELSE
3964: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;
3965: l_rel_hist_csr.new_attribute14 := l_new_relship_rec.attribute14;
3966: END IF;
3967: ELSE
3968: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;

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

3964: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;
3965: l_rel_hist_csr.new_attribute14 := l_new_relship_rec.attribute14;
3966: END IF;
3967: ELSE
3968: l_rel_hist_csr.old_attribute14 := fnd_api.g_miss_char;
3969: l_rel_hist_csr.new_attribute14 := l_new_relship_rec.attribute14;
3970: END IF;
3971: --
3972: IF ( l_rel_hist_csr.old_attribute15 IS NULL

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

3971: --
3972: IF ( l_rel_hist_csr.old_attribute15 IS NULL
3973: AND l_rel_hist_csr.new_attribute15 IS NULL ) THEN
3974: IF ( l_new_relship_rec.attribute15 = l_old_relship_rec.attribute15 )
3975: OR ( l_new_relship_rec.attribute15 = fnd_api.g_miss_char ) THEN
3976: l_rel_hist_csr.old_attribute15 := NULL;
3977: l_rel_hist_csr.new_attribute15 := NULL;
3978: ELSE
3979: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;

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

3975: OR ( l_new_relship_rec.attribute15 = fnd_api.g_miss_char ) THEN
3976: l_rel_hist_csr.old_attribute15 := NULL;
3977: l_rel_hist_csr.new_attribute15 := NULL;
3978: ELSE
3979: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;
3980: l_rel_hist_csr.new_attribute15 := l_new_relship_rec.attribute15;
3981: END IF;
3982: ELSE
3983: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;

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

3979: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;
3980: l_rel_hist_csr.new_attribute15 := l_new_relship_rec.attribute15;
3981: END IF;
3982: ELSE
3983: l_rel_hist_csr.old_attribute15 := fnd_api.g_miss_char;
3984: l_rel_hist_csr.new_attribute15 := l_new_relship_rec.attribute15;
3985: END IF;
3986: --
3987:

Line 3990: p_relationship_id => fnd_api.g_miss_num ,

3986: --
3987:
3988: csi_ii_relationships_h_pkg.update_row(
3989: p_relationship_history_id => l_rel_hist_id ,
3990: p_relationship_id => fnd_api.g_miss_num ,
3991: p_transaction_id => fnd_api.g_miss_num ,
3992: p_old_subject_id => l_rel_hist_csr.old_subject_id ,
3993: p_new_subject_id => l_rel_hist_csr.new_subject_id ,
3994: p_old_position_reference => l_rel_hist_csr.old_position_reference,

Line 3991: p_transaction_id => fnd_api.g_miss_num ,

3987:
3988: csi_ii_relationships_h_pkg.update_row(
3989: p_relationship_history_id => l_rel_hist_id ,
3990: p_relationship_id => fnd_api.g_miss_num ,
3991: p_transaction_id => fnd_api.g_miss_num ,
3992: p_old_subject_id => l_rel_hist_csr.old_subject_id ,
3993: p_new_subject_id => l_rel_hist_csr.new_subject_id ,
3994: p_old_position_reference => l_rel_hist_csr.old_position_reference,
3995: p_new_position_reference => l_rel_hist_csr.new_position_reference,

Line 4034: p_full_dump_flag => fnd_api.g_miss_char ,

4030: p_old_attribute14 => l_rel_hist_csr.old_attribute14 ,
4031: p_new_attribute14 => l_rel_hist_csr.new_attribute14 ,
4032: p_old_attribute15 => l_rel_hist_csr.old_attribute15 ,
4033: p_new_attribute15 => l_rel_hist_csr.new_attribute15 ,
4034: p_full_dump_flag => fnd_api.g_miss_char ,
4035: p_created_by => fnd_api.g_miss_num ,
4036: p_creation_date => fnd_api.g_miss_date ,
4037: p_last_updated_by => fnd_global.user_id ,
4038: p_last_update_date => SYSDATE ,

Line 4035: p_created_by => fnd_api.g_miss_num ,

4031: p_new_attribute14 => l_rel_hist_csr.new_attribute14 ,
4032: p_old_attribute15 => l_rel_hist_csr.old_attribute15 ,
4033: p_new_attribute15 => l_rel_hist_csr.new_attribute15 ,
4034: p_full_dump_flag => fnd_api.g_miss_char ,
4035: p_created_by => fnd_api.g_miss_num ,
4036: p_creation_date => fnd_api.g_miss_date ,
4037: p_last_updated_by => fnd_global.user_id ,
4038: p_last_update_date => SYSDATE ,
4039: p_last_update_login => fnd_global.conc_login_id ,

Line 4036: p_creation_date => fnd_api.g_miss_date ,

4032: p_old_attribute15 => l_rel_hist_csr.old_attribute15 ,
4033: p_new_attribute15 => l_rel_hist_csr.new_attribute15 ,
4034: p_full_dump_flag => fnd_api.g_miss_char ,
4035: p_created_by => fnd_api.g_miss_num ,
4036: p_creation_date => fnd_api.g_miss_date ,
4037: p_last_updated_by => fnd_global.user_id ,
4038: p_last_update_date => SYSDATE ,
4039: p_last_update_login => fnd_global.conc_login_id ,
4040: p_object_version_number => fnd_api.g_miss_num );

Line 4040: p_object_version_number => fnd_api.g_miss_num );

4036: p_creation_date => fnd_api.g_miss_date ,
4037: p_last_updated_by => fnd_global.user_id ,
4038: p_last_update_date => SYSDATE ,
4039: p_last_update_login => fnd_global.conc_login_id ,
4040: p_object_version_number => fnd_api.g_miss_num );
4041: END IF;
4042:
4043: EXCEPTION
4044: WHEN NO_DATA_FOUND THEN

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

4099: p_object_version_number => 1);
4100:
4101: ELSE
4102:
4103: IF (l_new_relship_rec.subject_id = fnd_api.g_miss_num) OR
4104: 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
4105: --Modified code for bug 8516781, FP bug 8551918 old and new Subject_ID are always populated in CSI_II_RELATIONSHIPS_H such that
4106: --the parent's history always shows the subject ID which modified
4107: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id;

Line 4104: 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

4100:
4101: ELSE
4102:
4103: IF (l_new_relship_rec.subject_id = fnd_api.g_miss_num) OR
4104: 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
4105: --Modified code for bug 8516781, FP bug 8551918 old and new Subject_ID are always populated in CSI_II_RELATIONSHIPS_H such that
4106: --the parent's history always shows the subject ID which modified
4107: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id;
4108: l_relship_hist_rec.new_subject_id := l_old_relship_rec.subject_id;

Line 4110: 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

4106: --the parent's history always shows the subject ID which modified
4107: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id;
4108: l_relship_hist_rec.new_subject_id := l_old_relship_rec.subject_id;
4109: ELSIF
4110: 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
4111: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id ;
4112: l_relship_hist_rec.new_subject_id := l_new_relship_rec.subject_id ;
4113: END IF;
4114: --

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

4111: l_relship_hist_rec.old_subject_id := l_old_relship_rec.subject_id ;
4112: l_relship_hist_rec.new_subject_id := l_new_relship_rec.subject_id ;
4113: END IF;
4114: --
4115: IF (l_new_relship_rec.position_reference = fnd_api.g_miss_char) OR
4116: 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
4117: l_relship_hist_rec.old_position_reference := NULL;
4118: l_relship_hist_rec.new_position_reference := NULL;
4119: ELSIF

Line 4116: 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

4112: l_relship_hist_rec.new_subject_id := l_new_relship_rec.subject_id ;
4113: END IF;
4114: --
4115: IF (l_new_relship_rec.position_reference = fnd_api.g_miss_char) OR
4116: 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
4117: l_relship_hist_rec.old_position_reference := NULL;
4118: l_relship_hist_rec.new_position_reference := NULL;
4119: ELSIF
4120: 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 4120: 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

4116: 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
4117: l_relship_hist_rec.old_position_reference := NULL;
4118: l_relship_hist_rec.new_position_reference := NULL;
4119: ELSIF
4120: 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
4121: l_relship_hist_rec.old_position_reference := l_old_relship_rec.position_reference ;
4122: l_relship_hist_rec.new_position_reference := l_new_relship_rec.position_reference ;
4123: END IF;
4124: --

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

4121: l_relship_hist_rec.old_position_reference := l_old_relship_rec.position_reference ;
4122: l_relship_hist_rec.new_position_reference := l_new_relship_rec.position_reference ;
4123: END IF;
4124: --
4125: IF (l_new_relship_rec.active_start_date = fnd_api.g_miss_date) OR
4126: 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
4127: l_relship_hist_rec.old_active_start_date := NULL;
4128: l_relship_hist_rec.new_active_start_date := NULL;
4129: ELSIF

Line 4126: 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

4122: l_relship_hist_rec.new_position_reference := l_new_relship_rec.position_reference ;
4123: END IF;
4124: --
4125: IF (l_new_relship_rec.active_start_date = fnd_api.g_miss_date) OR
4126: 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
4127: l_relship_hist_rec.old_active_start_date := NULL;
4128: l_relship_hist_rec.new_active_start_date := NULL;
4129: ELSIF
4130: 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 4130: 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

4126: 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
4127: l_relship_hist_rec.old_active_start_date := NULL;
4128: l_relship_hist_rec.new_active_start_date := NULL;
4129: ELSIF
4130: 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
4131: l_relship_hist_rec.old_active_start_date := l_old_relship_rec.active_start_date ;
4132: l_relship_hist_rec.new_active_start_date := l_new_relship_rec.active_start_date ;
4133: END IF;
4134: --

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

4131: l_relship_hist_rec.old_active_start_date := l_old_relship_rec.active_start_date ;
4132: l_relship_hist_rec.new_active_start_date := l_new_relship_rec.active_start_date ;
4133: END IF;
4134: --
4135: IF (l_new_relship_rec.active_end_date = fnd_api.g_miss_date) OR
4136: 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
4137: l_relship_hist_rec.old_active_end_date := NULL;
4138: l_relship_hist_rec.new_active_end_date := NULL;
4139: ELSIF

Line 4136: 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

4132: l_relship_hist_rec.new_active_start_date := l_new_relship_rec.active_start_date ;
4133: END IF;
4134: --
4135: IF (l_new_relship_rec.active_end_date = fnd_api.g_miss_date) OR
4136: 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
4137: l_relship_hist_rec.old_active_end_date := NULL;
4138: l_relship_hist_rec.new_active_end_date := NULL;
4139: ELSIF
4140: 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 4140: 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

4136: 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
4137: l_relship_hist_rec.old_active_end_date := NULL;
4138: l_relship_hist_rec.new_active_end_date := NULL;
4139: ELSIF
4140: 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
4141: l_relship_hist_rec.old_active_end_date := l_old_relship_rec.active_end_date ;
4142: l_relship_hist_rec.new_active_end_date := l_new_relship_rec.active_end_date ;
4143: END IF;
4144: --

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

4141: l_relship_hist_rec.old_active_end_date := l_old_relship_rec.active_end_date ;
4142: l_relship_hist_rec.new_active_end_date := l_new_relship_rec.active_end_date ;
4143: END IF;
4144: --
4145: IF (l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char) OR
4146: 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
4147: l_relship_hist_rec.old_mandatory_flag := NULL;
4148: l_relship_hist_rec.new_mandatory_flag := NULL;
4149: ELSIF

Line 4146: 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

4142: l_relship_hist_rec.new_active_end_date := l_new_relship_rec.active_end_date ;
4143: END IF;
4144: --
4145: IF (l_new_relship_rec.mandatory_flag = fnd_api.g_miss_char) OR
4146: 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
4147: l_relship_hist_rec.old_mandatory_flag := NULL;
4148: l_relship_hist_rec.new_mandatory_flag := NULL;
4149: ELSIF
4150: 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 4150: 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

4146: 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
4147: l_relship_hist_rec.old_mandatory_flag := NULL;
4148: l_relship_hist_rec.new_mandatory_flag := NULL;
4149: ELSIF
4150: 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
4151: l_relship_hist_rec.old_mandatory_flag := l_old_relship_rec.mandatory_flag ;
4152: l_relship_hist_rec.new_mandatory_flag := l_new_relship_rec.mandatory_flag ;
4153: END IF;
4154: --

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

4151: l_relship_hist_rec.old_mandatory_flag := l_old_relship_rec.mandatory_flag ;
4152: l_relship_hist_rec.new_mandatory_flag := l_new_relship_rec.mandatory_flag ;
4153: END IF;
4154: --
4155: IF (l_new_relship_rec.context = fnd_api.g_miss_char) OR
4156: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) = NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN
4157: l_relship_hist_rec.old_context := NULL;
4158: l_relship_hist_rec.new_context := NULL;
4159: ELSIF

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

4152: l_relship_hist_rec.new_mandatory_flag := l_new_relship_rec.mandatory_flag ;
4153: END IF;
4154: --
4155: IF (l_new_relship_rec.context = fnd_api.g_miss_char) OR
4156: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) = NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN
4157: l_relship_hist_rec.old_context := NULL;
4158: l_relship_hist_rec.new_context := NULL;
4159: ELSIF
4160: NVL(l_old_relship_rec.context,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.context,fnd_api.g_miss_char) THEN

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

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

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

4161: l_relship_hist_rec.old_context := l_old_relship_rec.context ;
4162: l_relship_hist_rec.new_context := l_new_relship_rec.context ;
4163: END IF;
4164: --
4165: IF (l_new_relship_rec.attribute1 = fnd_api.g_miss_char) OR
4166: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4167: l_relship_hist_rec.old_attribute1 := NULL;
4168: l_relship_hist_rec.new_attribute1 := NULL;
4169: ELSIF

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

4162: l_relship_hist_rec.new_context := l_new_relship_rec.context ;
4163: END IF;
4164: --
4165: IF (l_new_relship_rec.attribute1 = fnd_api.g_miss_char) OR
4166: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4167: l_relship_hist_rec.old_attribute1 := NULL;
4168: l_relship_hist_rec.new_attribute1 := NULL;
4169: ELSIF
4170: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN

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

4166: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4167: l_relship_hist_rec.old_attribute1 := NULL;
4168: l_relship_hist_rec.new_attribute1 := NULL;
4169: ELSIF
4170: NVL(l_old_relship_rec.attribute1,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute1,fnd_api.g_miss_char) THEN
4171: l_relship_hist_rec.old_attribute1 := l_old_relship_rec.attribute1 ;
4172: l_relship_hist_rec.new_attribute1 := l_new_relship_rec.attribute1 ;
4173: END IF;
4174: --

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

4171: l_relship_hist_rec.old_attribute1 := l_old_relship_rec.attribute1 ;
4172: l_relship_hist_rec.new_attribute1 := l_new_relship_rec.attribute1 ;
4173: END IF;
4174: --
4175: IF (l_new_relship_rec.attribute2 = fnd_api.g_miss_char) OR
4176: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4177: l_relship_hist_rec.old_attribute2 := NULL;
4178: l_relship_hist_rec.new_attribute2 := NULL;
4179: ELSIF

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

4172: l_relship_hist_rec.new_attribute1 := l_new_relship_rec.attribute1 ;
4173: END IF;
4174: --
4175: IF (l_new_relship_rec.attribute2 = fnd_api.g_miss_char) OR
4176: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4177: l_relship_hist_rec.old_attribute2 := NULL;
4178: l_relship_hist_rec.new_attribute2 := NULL;
4179: ELSIF
4180: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN

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

4176: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4177: l_relship_hist_rec.old_attribute2 := NULL;
4178: l_relship_hist_rec.new_attribute2 := NULL;
4179: ELSIF
4180: NVL(l_old_relship_rec.attribute2,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute2,fnd_api.g_miss_char) THEN
4181: l_relship_hist_rec.old_attribute2 := l_old_relship_rec.attribute2 ;
4182: l_relship_hist_rec.new_attribute2 := l_new_relship_rec.attribute2 ;
4183: END IF;
4184: --

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

4181: l_relship_hist_rec.old_attribute2 := l_old_relship_rec.attribute2 ;
4182: l_relship_hist_rec.new_attribute2 := l_new_relship_rec.attribute2 ;
4183: END IF;
4184: --
4185: IF (l_new_relship_rec.attribute3 = fnd_api.g_miss_char) OR
4186: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4187: l_relship_hist_rec.old_attribute3 := NULL;
4188: l_relship_hist_rec.new_attribute3 := NULL;
4189: ELSIF

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

4182: l_relship_hist_rec.new_attribute2 := l_new_relship_rec.attribute2 ;
4183: END IF;
4184: --
4185: IF (l_new_relship_rec.attribute3 = fnd_api.g_miss_char) OR
4186: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4187: l_relship_hist_rec.old_attribute3 := NULL;
4188: l_relship_hist_rec.new_attribute3 := NULL;
4189: ELSIF
4190: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN

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

4186: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4187: l_relship_hist_rec.old_attribute3 := NULL;
4188: l_relship_hist_rec.new_attribute3 := NULL;
4189: ELSIF
4190: NVL(l_old_relship_rec.attribute3,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute3,fnd_api.g_miss_char) THEN
4191: l_relship_hist_rec.old_attribute3 := l_old_relship_rec.attribute3 ;
4192: l_relship_hist_rec.new_attribute3 := l_new_relship_rec.attribute3 ;
4193: END IF;
4194: --

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

4191: l_relship_hist_rec.old_attribute3 := l_old_relship_rec.attribute3 ;
4192: l_relship_hist_rec.new_attribute3 := l_new_relship_rec.attribute3 ;
4193: END IF;
4194: --
4195: IF (l_new_relship_rec.attribute4 = fnd_api.g_miss_char) OR
4196: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4197: l_relship_hist_rec.old_attribute4 := NULL;
4198: l_relship_hist_rec.new_attribute4 := NULL;
4199: ELSIF

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

4192: l_relship_hist_rec.new_attribute3 := l_new_relship_rec.attribute3 ;
4193: END IF;
4194: --
4195: IF (l_new_relship_rec.attribute4 = fnd_api.g_miss_char) OR
4196: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4197: l_relship_hist_rec.old_attribute4 := NULL;
4198: l_relship_hist_rec.new_attribute4 := NULL;
4199: ELSIF
4200: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN

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

4196: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4197: l_relship_hist_rec.old_attribute4 := NULL;
4198: l_relship_hist_rec.new_attribute4 := NULL;
4199: ELSIF
4200: NVL(l_old_relship_rec.attribute4,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute4,fnd_api.g_miss_char) THEN
4201: l_relship_hist_rec.old_attribute4 := l_old_relship_rec.attribute4 ;
4202: l_relship_hist_rec.new_attribute4 := l_new_relship_rec.attribute4 ;
4203: END IF;
4204: --

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

4201: l_relship_hist_rec.old_attribute4 := l_old_relship_rec.attribute4 ;
4202: l_relship_hist_rec.new_attribute4 := l_new_relship_rec.attribute4 ;
4203: END IF;
4204: --
4205: IF (l_new_relship_rec.attribute5 = fnd_api.g_miss_char) OR
4206: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4207: l_relship_hist_rec.old_attribute5 := NULL;
4208: l_relship_hist_rec.new_attribute5 := NULL;
4209: ELSIF

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

4202: l_relship_hist_rec.new_attribute4 := l_new_relship_rec.attribute4 ;
4203: END IF;
4204: --
4205: IF (l_new_relship_rec.attribute5 = fnd_api.g_miss_char) OR
4206: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4207: l_relship_hist_rec.old_attribute5 := NULL;
4208: l_relship_hist_rec.new_attribute5 := NULL;
4209: ELSIF
4210: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN

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

4206: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4207: l_relship_hist_rec.old_attribute5 := NULL;
4208: l_relship_hist_rec.new_attribute5 := NULL;
4209: ELSIF
4210: NVL(l_old_relship_rec.attribute5,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute5,fnd_api.g_miss_char) THEN
4211: l_relship_hist_rec.old_attribute5 := l_old_relship_rec.attribute5 ;
4212: l_relship_hist_rec.new_attribute5 := l_new_relship_rec.attribute5 ;
4213: END IF;
4214: --

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

4211: l_relship_hist_rec.old_attribute5 := l_old_relship_rec.attribute5 ;
4212: l_relship_hist_rec.new_attribute5 := l_new_relship_rec.attribute5 ;
4213: END IF;
4214: --
4215: IF (l_new_relship_rec.attribute6 = fnd_api.g_miss_char) OR
4216: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4217: l_relship_hist_rec.old_attribute6 := NULL;
4218: l_relship_hist_rec.new_attribute6 := NULL;
4219: ELSIF

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

4212: l_relship_hist_rec.new_attribute5 := l_new_relship_rec.attribute5 ;
4213: END IF;
4214: --
4215: IF (l_new_relship_rec.attribute6 = fnd_api.g_miss_char) OR
4216: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4217: l_relship_hist_rec.old_attribute6 := NULL;
4218: l_relship_hist_rec.new_attribute6 := NULL;
4219: ELSIF
4220: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN

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

4216: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4217: l_relship_hist_rec.old_attribute6 := NULL;
4218: l_relship_hist_rec.new_attribute6 := NULL;
4219: ELSIF
4220: NVL(l_old_relship_rec.attribute6,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute6,fnd_api.g_miss_char) THEN
4221: l_relship_hist_rec.old_attribute6 := l_old_relship_rec.attribute6 ;
4222: l_relship_hist_rec.new_attribute6 := l_new_relship_rec.attribute6 ;
4223: END IF;
4224: --

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

4221: l_relship_hist_rec.old_attribute6 := l_old_relship_rec.attribute6 ;
4222: l_relship_hist_rec.new_attribute6 := l_new_relship_rec.attribute6 ;
4223: END IF;
4224: --
4225: IF (l_new_relship_rec.attribute7 = fnd_api.g_miss_char) OR
4226: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4227: l_relship_hist_rec.old_attribute7 := NULL;
4228: l_relship_hist_rec.new_attribute7 := NULL;
4229: ELSIF

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

4222: l_relship_hist_rec.new_attribute6 := l_new_relship_rec.attribute6 ;
4223: END IF;
4224: --
4225: IF (l_new_relship_rec.attribute7 = fnd_api.g_miss_char) OR
4226: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4227: l_relship_hist_rec.old_attribute7 := NULL;
4228: l_relship_hist_rec.new_attribute7 := NULL;
4229: ELSIF
4230: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN

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

4226: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4227: l_relship_hist_rec.old_attribute7 := NULL;
4228: l_relship_hist_rec.new_attribute7 := NULL;
4229: ELSIF
4230: NVL(l_old_relship_rec.attribute7,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute7,fnd_api.g_miss_char) THEN
4231: l_relship_hist_rec.old_attribute7 := l_old_relship_rec.attribute7 ;
4232: l_relship_hist_rec.new_attribute7 := l_new_relship_rec.attribute7 ;
4233: END IF;
4234: --

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

4231: l_relship_hist_rec.old_attribute7 := l_old_relship_rec.attribute7 ;
4232: l_relship_hist_rec.new_attribute7 := l_new_relship_rec.attribute7 ;
4233: END IF;
4234: --
4235: IF (l_new_relship_rec.attribute8 = fnd_api.g_miss_char) OR
4236: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4237: l_relship_hist_rec.old_attribute8 := NULL;
4238: l_relship_hist_rec.new_attribute8 := NULL;
4239: ELSIF

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

4232: l_relship_hist_rec.new_attribute7 := l_new_relship_rec.attribute7 ;
4233: END IF;
4234: --
4235: IF (l_new_relship_rec.attribute8 = fnd_api.g_miss_char) OR
4236: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4237: l_relship_hist_rec.old_attribute8 := NULL;
4238: l_relship_hist_rec.new_attribute8 := NULL;
4239: ELSIF
4240: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN

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

4236: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4237: l_relship_hist_rec.old_attribute8 := NULL;
4238: l_relship_hist_rec.new_attribute8 := NULL;
4239: ELSIF
4240: NVL(l_old_relship_rec.attribute8,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute8,fnd_api.g_miss_char) THEN
4241: l_relship_hist_rec.old_attribute8 := l_old_relship_rec.attribute8 ;
4242: l_relship_hist_rec.new_attribute8 := l_new_relship_rec.attribute8 ;
4243: END IF;
4244: --

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

4241: l_relship_hist_rec.old_attribute8 := l_old_relship_rec.attribute8 ;
4242: l_relship_hist_rec.new_attribute8 := l_new_relship_rec.attribute8 ;
4243: END IF;
4244: --
4245: IF (l_new_relship_rec.attribute9 = fnd_api.g_miss_char) OR
4246: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4247: l_relship_hist_rec.old_attribute9 := NULL;
4248: l_relship_hist_rec.new_attribute9 := NULL;
4249: ELSIF

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

4242: l_relship_hist_rec.new_attribute8 := l_new_relship_rec.attribute8 ;
4243: END IF;
4244: --
4245: IF (l_new_relship_rec.attribute9 = fnd_api.g_miss_char) OR
4246: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4247: l_relship_hist_rec.old_attribute9 := NULL;
4248: l_relship_hist_rec.new_attribute9 := NULL;
4249: ELSIF
4250: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN

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

4246: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4247: l_relship_hist_rec.old_attribute9 := NULL;
4248: l_relship_hist_rec.new_attribute9 := NULL;
4249: ELSIF
4250: NVL(l_old_relship_rec.attribute9,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute9,fnd_api.g_miss_char) THEN
4251: l_relship_hist_rec.old_attribute9 := l_old_relship_rec.attribute9 ;
4252: l_relship_hist_rec.new_attribute9 := l_new_relship_rec.attribute9 ;
4253: END IF;
4254: --

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

4251: l_relship_hist_rec.old_attribute9 := l_old_relship_rec.attribute9 ;
4252: l_relship_hist_rec.new_attribute9 := l_new_relship_rec.attribute9 ;
4253: END IF;
4254: --
4255: IF (l_new_relship_rec.attribute10 = fnd_api.g_miss_char) OR
4256: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4257: l_relship_hist_rec.old_attribute10 := NULL;
4258: l_relship_hist_rec.new_attribute10 := NULL;
4259: ELSIF

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

4252: l_relship_hist_rec.new_attribute9 := l_new_relship_rec.attribute9 ;
4253: END IF;
4254: --
4255: IF (l_new_relship_rec.attribute10 = fnd_api.g_miss_char) OR
4256: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4257: l_relship_hist_rec.old_attribute10 := NULL;
4258: l_relship_hist_rec.new_attribute10 := NULL;
4259: ELSIF
4260: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN

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

4256: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4257: l_relship_hist_rec.old_attribute10 := NULL;
4258: l_relship_hist_rec.new_attribute10 := NULL;
4259: ELSIF
4260: NVL(l_old_relship_rec.attribute10,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute10,fnd_api.g_miss_char) THEN
4261: l_relship_hist_rec.old_attribute10 := l_old_relship_rec.attribute10 ;
4262: l_relship_hist_rec.new_attribute10 := l_new_relship_rec.attribute10 ;
4263: END IF;
4264: --

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

4261: l_relship_hist_rec.old_attribute10 := l_old_relship_rec.attribute10 ;
4262: l_relship_hist_rec.new_attribute10 := l_new_relship_rec.attribute10 ;
4263: END IF;
4264: --
4265: IF (l_new_relship_rec.attribute11 = fnd_api.g_miss_char) OR
4266: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4267: l_relship_hist_rec.old_attribute11 := NULL;
4268: l_relship_hist_rec.new_attribute11 := NULL;
4269: ELSIF

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

4262: l_relship_hist_rec.new_attribute10 := l_new_relship_rec.attribute10 ;
4263: END IF;
4264: --
4265: IF (l_new_relship_rec.attribute11 = fnd_api.g_miss_char) OR
4266: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4267: l_relship_hist_rec.old_attribute11 := NULL;
4268: l_relship_hist_rec.new_attribute11 := NULL;
4269: ELSIF
4270: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN

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

4266: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4267: l_relship_hist_rec.old_attribute11 := NULL;
4268: l_relship_hist_rec.new_attribute11 := NULL;
4269: ELSIF
4270: NVL(l_old_relship_rec.attribute11,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute11,fnd_api.g_miss_char) THEN
4271: l_relship_hist_rec.old_attribute11 := l_old_relship_rec.attribute11 ;
4272: l_relship_hist_rec.new_attribute11 := l_new_relship_rec.attribute11 ;
4273: END IF;
4274: --

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

4271: l_relship_hist_rec.old_attribute11 := l_old_relship_rec.attribute11 ;
4272: l_relship_hist_rec.new_attribute11 := l_new_relship_rec.attribute11 ;
4273: END IF;
4274: --
4275: IF (l_new_relship_rec.attribute12 = fnd_api.g_miss_char) OR
4276: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4277: l_relship_hist_rec.old_attribute12 := NULL;
4278: l_relship_hist_rec.new_attribute12 := NULL;
4279: ELSIF

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

4272: l_relship_hist_rec.new_attribute11 := l_new_relship_rec.attribute11 ;
4273: END IF;
4274: --
4275: IF (l_new_relship_rec.attribute12 = fnd_api.g_miss_char) OR
4276: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4277: l_relship_hist_rec.old_attribute12 := NULL;
4278: l_relship_hist_rec.new_attribute12 := NULL;
4279: ELSIF
4280: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN

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

4276: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4277: l_relship_hist_rec.old_attribute12 := NULL;
4278: l_relship_hist_rec.new_attribute12 := NULL;
4279: ELSIF
4280: NVL(l_old_relship_rec.attribute12,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute12,fnd_api.g_miss_char) THEN
4281: l_relship_hist_rec.old_attribute12 := l_old_relship_rec.attribute12 ;
4282: l_relship_hist_rec.new_attribute12 := l_new_relship_rec.attribute12 ;
4283: END IF;
4284: --

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

4281: l_relship_hist_rec.old_attribute12 := l_old_relship_rec.attribute12 ;
4282: l_relship_hist_rec.new_attribute12 := l_new_relship_rec.attribute12 ;
4283: END IF;
4284: --
4285: IF (l_new_relship_rec.attribute13 = fnd_api.g_miss_char) OR
4286: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4287: l_relship_hist_rec.old_attribute13 := NULL;
4288: l_relship_hist_rec.new_attribute13 := NULL;
4289: ELSIF

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

4282: l_relship_hist_rec.new_attribute12 := l_new_relship_rec.attribute12 ;
4283: END IF;
4284: --
4285: IF (l_new_relship_rec.attribute13 = fnd_api.g_miss_char) OR
4286: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4287: l_relship_hist_rec.old_attribute13 := NULL;
4288: l_relship_hist_rec.new_attribute13 := NULL;
4289: ELSIF
4290: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN

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

4286: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4287: l_relship_hist_rec.old_attribute13 := NULL;
4288: l_relship_hist_rec.new_attribute13 := NULL;
4289: ELSIF
4290: NVL(l_old_relship_rec.attribute13,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute13,fnd_api.g_miss_char) THEN
4291: l_relship_hist_rec.old_attribute13 := l_old_relship_rec.attribute13 ;
4292: l_relship_hist_rec.new_attribute13 := l_new_relship_rec.attribute13 ;
4293: END IF;
4294: --

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

4291: l_relship_hist_rec.old_attribute13 := l_old_relship_rec.attribute13 ;
4292: l_relship_hist_rec.new_attribute13 := l_new_relship_rec.attribute13 ;
4293: END IF;
4294: --
4295: IF (l_new_relship_rec.attribute14 = fnd_api.g_miss_char) OR
4296: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4297: l_relship_hist_rec.old_attribute14 := NULL;
4298: l_relship_hist_rec.new_attribute14 := NULL;
4299: ELSIF

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

4292: l_relship_hist_rec.new_attribute13 := l_new_relship_rec.attribute13 ;
4293: END IF;
4294: --
4295: IF (l_new_relship_rec.attribute14 = fnd_api.g_miss_char) OR
4296: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4297: l_relship_hist_rec.old_attribute14 := NULL;
4298: l_relship_hist_rec.new_attribute14 := NULL;
4299: ELSIF
4300: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN

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

4296: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4297: l_relship_hist_rec.old_attribute14 := NULL;
4298: l_relship_hist_rec.new_attribute14 := NULL;
4299: ELSIF
4300: NVL(l_old_relship_rec.attribute14,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute14,fnd_api.g_miss_char) THEN
4301: l_relship_hist_rec.old_attribute14 := l_old_relship_rec.attribute14 ;
4302: l_relship_hist_rec.new_attribute14 := l_new_relship_rec.attribute14 ;
4303: END IF;
4304: --

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

4301: l_relship_hist_rec.old_attribute14 := l_old_relship_rec.attribute14 ;
4302: l_relship_hist_rec.new_attribute14 := l_new_relship_rec.attribute14 ;
4303: END IF;
4304: --
4305: IF (l_new_relship_rec.attribute15 = fnd_api.g_miss_char) OR
4306: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4307: l_relship_hist_rec.old_attribute15 := NULL;
4308: l_relship_hist_rec.new_attribute15 := NULL;
4309: ELSIF

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

4302: l_relship_hist_rec.new_attribute14 := l_new_relship_rec.attribute14 ;
4303: END IF;
4304: --
4305: IF (l_new_relship_rec.attribute15 = fnd_api.g_miss_char) OR
4306: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4307: l_relship_hist_rec.old_attribute15 := NULL;
4308: l_relship_hist_rec.new_attribute15 := NULL;
4309: ELSIF
4310: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN

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

4306: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) = NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4307: l_relship_hist_rec.old_attribute15 := NULL;
4308: l_relship_hist_rec.new_attribute15 := NULL;
4309: ELSIF
4310: NVL(l_old_relship_rec.attribute15,fnd_api.g_miss_char) <> NVL(l_new_relship_rec.attribute15,fnd_api.g_miss_char) THEN
4311: l_relship_hist_rec.old_attribute15 := l_old_relship_rec.attribute15 ;
4312: l_relship_hist_rec.new_attribute15 := l_new_relship_rec.attribute15 ;
4313: END IF;
4314: --

Line 4378: x_return_status := fnd_api.g_ret_sts_error;

4374: END;
4375: -- End of modifications for Bug#2547034 on 09/20/02 - rtalluri
4376: EXCEPTION
4377: WHEN OTHERS THEN
4378: x_return_status := fnd_api.g_ret_sts_error;
4379: END;
4380: /* ----------------------------------------------------------------------------------------------------------+
4381: | Case1. Create/Update Relationship |
4382: | Only 'COMPONENT-OF' If subject_id not null and subject_id's creation_complete_flag |

Line 4445: x_return_status := fnd_api.g_ret_sts_success;

4441: -- End Add Code for Siebel Genesis Project
4442:
4443: BEGIN
4444:
4445: x_return_status := fnd_api.g_ret_sts_success;
4446: l_ii_relationship_rec := p_ii_relationship_rec;
4447: --
4448: IF l_ii_relationship_rec.relationship_id IS NOT NULL AND
4449: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN

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

4445: x_return_status := fnd_api.g_ret_sts_success;
4446: l_ii_relationship_rec := p_ii_relationship_rec;
4447: --
4448: IF l_ii_relationship_rec.relationship_id IS NOT NULL AND
4449: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN
4450: IF l_ii_relationship_rec.subject_id IS NULL OR
4451: l_ii_relationship_rec.subject_id = FND_API.G_MISS_NUM THEN
4452: Begin
4453: select subject_id

Line 4451: l_ii_relationship_rec.subject_id = FND_API.G_MISS_NUM THEN

4447: --
4448: IF l_ii_relationship_rec.relationship_id IS NOT NULL AND
4449: l_ii_relationship_rec.relationship_id <> FND_API.G_MISS_NUM THEN
4450: IF l_ii_relationship_rec.subject_id IS NULL OR
4451: l_ii_relationship_rec.subject_id = FND_API.G_MISS_NUM THEN
4452: Begin
4453: select subject_id
4454: into l_ii_relationship_rec.subject_id
4455: from CSI_II_RELATIONSHIPS

Line 4461: l_ii_relationship_rec.object_id = FND_API.G_MISS_NUM THEN

4457: End;
4458: END IF;
4459: --
4460: IF l_ii_relationship_rec.object_id IS NULL OR
4461: l_ii_relationship_rec.object_id = FND_API.G_MISS_NUM THEN
4462: Begin
4463: select object_id
4464: into l_ii_relationship_rec.object_id
4465: from CSI_II_RELATIONSHIPS

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

4567: ,p_child_inst_tbl => px_child_inst_tbl
4568: );*/
4569: -- End Add Code for Siebel Genesis Project
4570:
4571: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4572: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4573: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4574: fnd_msg_pub.add;
4575: RAISE fnd_api.g_exc_error;

Line 4575: RAISE fnd_api.g_exc_error;

4571: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4572: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4573: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4574: fnd_msg_pub.add;
4575: RAISE fnd_api.g_exc_error;
4576: END IF;
4577:
4578: EXCEPTION
4579: WHEN OTHERS THEN

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

4618: AND relationship_type_code='COMPONENT-OF'
4619: )
4620: AND creation_complete_flag = 'N';
4621:
4622: IF nvl(l_dummy,fnd_api.g_miss_num) > 0 THEN
4623: EXIT;
4624: ELSE
4625: SELECT object_version_number,
4626: config_inst_hdr_id, --added

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

4657: ,p_oks_txn_inst_tbl => px_oks_txn_inst_tbl
4658: ,p_child_inst_tbl => px_child_inst_tbl
4659: );
4660:
4661: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4662: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4663: fnd_message.set_token('instance_id',l_instance_rec1.instance_id);
4664: fnd_msg_pub.add;
4665: RAISE fnd_api.g_exc_error;

Line 4665: RAISE fnd_api.g_exc_error;

4661: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
4662: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4663: fnd_message.set_token('instance_id',l_instance_rec1.instance_id);
4664: fnd_msg_pub.add;
4665: RAISE fnd_api.g_exc_error;
4666: END IF;
4667:
4668: END IF;
4669: END IF;

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

4701: l_asset_assignment_tbl csi_datastructures_pub.instance_asset_tbl;
4702: l_instance_id_lst csi_datastructures_pub.id_tbl;
4703: l_instance_rec csi_datastructures_pub.instance_rec;
4704: l_subject_id NUMBER;
4705: l_record_found VARCHAR2(1):= fnd_api.g_true;
4706: BEGIN
4707: IF p_ii_relationship_rec.relationship_type_code='COMPONENT-OF' THEN
4708:
4709: BEGIN

Line 4732: l_record_found := fnd_api.g_false;

4728: AND (cp.active_end_date IS NULL OR cp.active_end_date > SYSDATE)
4729: AND (ca.active_end_date IS NULL OR ca.active_end_date > SYSDATE);
4730: EXCEPTION
4731: WHEN OTHERS THEN
4732: l_record_found := fnd_api.g_false;
4733: END;
4734:
4735: BEGIN
4736: SELECT instance_party_id

Line 4749: IF l_record_found = fnd_api.g_true

4745: WHEN OTHERS THEN
4746: NULL;
4747: END;
4748:
4749: IF l_record_found = fnd_api.g_true
4750: THEN
4751: BEGIN
4752: SELECT instance_id
4753: ,object_version_number

Line 4763: l_record_found := fnd_api.g_false;

4759: l_party_tbl(1).instance_id := p_ii_relationship_rec.subject_id;
4760: l_account_tbl(1).parent_tbl_index := 1;
4761: EXCEPTION
4762: WHEN OTHERS THEN
4763: l_record_found := fnd_api.g_false;
4764: END;
4765: END IF;
4766:
4767:

Line 4768: IF l_record_found = fnd_api.g_true

4764: END;
4765: END IF;
4766:
4767:
4768: IF l_record_found = fnd_api.g_true
4769: THEN
4770: csi_item_instance_pub.update_item_instance
4771: ( p_api_version => p_api_version
4772: ,p_commit => p_commit

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

4785: ,x_msg_count => x_msg_count
4786: ,x_msg_data => x_msg_data
4787: );
4788:
4789: IF NOT(x_return_status = fnd_api.g_ret_sts_success)
4790: THEN
4791: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4792: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4793: fnd_msg_pub.add;

Line 4794: RAISE fnd_api.g_exc_error;

4790: THEN
4791: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
4792: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
4793: fnd_msg_pub.add;
4794: RAISE fnd_api.g_exc_error;
4795: END IF;
4796: END IF;
4797: END IF;
4798: END update_party_account;

Line 4851: IF NOT fnd_api.compatible_api_call ( l_api_version,

4847: -- standard start of api savepoint
4848: SAVEPOINT create_relationship_pvt;
4849:
4850: -- standard call to check for call compatibility.
4851: IF NOT fnd_api.compatible_api_call ( l_api_version,
4852: p_api_version,
4853: l_api_name,
4854: g_pkg_name)
4855: THEN

Line 4856: RAISE fnd_api.g_exc_unexpected_error;

4852: p_api_version,
4853: l_api_name,
4854: g_pkg_name)
4855: THEN
4856: RAISE fnd_api.g_exc_unexpected_error;
4857: END IF;
4858:
4859:
4860: -- initialize message list if p_init_msg_list is set to true.

Line 4861: IF fnd_api.to_boolean( p_init_msg_list )

4857: END IF;
4858:
4859:
4860: -- initialize message list if p_init_msg_list is set to true.
4861: IF fnd_api.to_boolean( p_init_msg_list )
4862: THEN
4863: fnd_msg_pub.initialize;
4864: END IF;
4865:

Line 4867: x_return_status := fnd_api.g_ret_sts_success;

4863: fnd_msg_pub.initialize;
4864: END IF;
4865:
4866: -- initialize api return status to success
4867: x_return_status := fnd_api.g_ret_sts_success;
4868:
4869: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
4870: IF (l_debug_level > 0) THEN
4871: CSI_gen_utility_pvt.put_line( 'create_relationship');

Line 4890: p_init_msg_list => fnd_api.g_false,

4886: END IF;
4887:
4888: -- invoke validation procedures
4889: validate_ii_relationships(
4890: p_init_msg_list => fnd_api.g_false,
4891: p_validation_level => p_validation_level,
4892: p_validation_mode => 'CREATE',
4893: p_ii_relationship_tbl => p_relationship_tbl,
4894: x_return_status => x_return_status,

Line 4899: IF x_return_status<>fnd_api.g_ret_sts_success THEN

4895: x_msg_count => x_msg_count,
4896: x_msg_data => x_msg_data);
4897:
4898:
4899: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4900: RAISE fnd_api.g_exc_error;
4901: END IF;
4902:
4903:

Line 4900: RAISE fnd_api.g_exc_error;

4896: x_msg_data => x_msg_data);
4897:
4898:
4899: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4900: RAISE fnd_api.g_exc_error;
4901: END IF;
4902:
4903:
4904:

Line 4913: RAISE fnd_api.g_exc_error;

4909: IF (p_relationship_tbl(l_count).subject_id = p_relationship_tbl(l_count).object_id) THEN
4910: FND_MESSAGE.SET_NAME('CSI','CSI_RELATIONSHIP_LOOP');
4911: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
4912: FND_MSG_PUB.ADD;
4913: RAISE fnd_api.g_exc_error;
4914: END IF;
4915:
4916: IF ( (p_relationship_tbl(l_count).mandatory_flag IS NULL) OR
4917: (p_relationship_tbl(l_count).mandatory_flag = fnd_api.g_miss_char) ) THEN

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

4913: RAISE fnd_api.g_exc_error;
4914: END IF;
4915:
4916: IF ( (p_relationship_tbl(l_count).mandatory_flag IS NULL) OR
4917: (p_relationship_tbl(l_count).mandatory_flag = fnd_api.g_miss_char) ) THEN
4918: p_relationship_tbl(l_count).mandatory_flag:='N';
4919: END IF;
4920:
4921: --Added for MACD lock functionality

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

4919: END IF;
4920:
4921: --Added for MACD lock functionality
4922: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
4923: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
4924: THEN
4925: IF csi_item_instance_pvt.check_item_instance_lock
4926: ( p_instance_id => p_relationship_tbl(l_count).object_id)
4927: THEN

Line 4933: RAISE FND_API.G_EXC_ERROR;

4929: THEN
4930: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
4931: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
4932: FND_MSG_PUB.ADD;
4933: RAISE FND_API.G_EXC_ERROR;
4934: END IF;
4935: END IF;
4936: END IF;
4937: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND

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

4934: END IF;
4935: END IF;
4936: END IF;
4937: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND
4938: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num
4939: THEN
4940: IF csi_item_instance_pvt.check_item_instance_lock
4941: ( p_instance_id => p_relationship_tbl(l_count).subject_id)
4942: THEN

Line 4948: RAISE FND_API.G_EXC_ERROR;

4944: THEN
4945: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
4946: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).subject_id);
4947: FND_MSG_PUB.ADD;
4948: RAISE FND_API.G_EXC_ERROR;
4949: END IF;
4950: END IF;
4951: END IF;
4952: -- End addition for MACD lock functionality

Line 4963: x_return_status:=fnd_api.g_ret_sts_success;

4959: p_relship_type_code => p_relationship_tbl(l_count).relationship_type_code,
4960: p_relationship_id => Null,
4961: p_mode => 'CREATE' )
4962: THEN
4963: x_return_status:=fnd_api.g_ret_sts_success;
4964: ELSE
4965: x_return_status:=fnd_api.g_ret_sts_error;
4966: RAISE fnd_api.g_exc_error;
4967: END IF;

Line 4965: x_return_status:=fnd_api.g_ret_sts_error;

4961: p_mode => 'CREATE' )
4962: THEN
4963: x_return_status:=fnd_api.g_ret_sts_success;
4964: ELSE
4965: x_return_status:=fnd_api.g_ret_sts_error;
4966: RAISE fnd_api.g_exc_error;
4967: END IF;
4968:
4969: IF ((x_return_status=fnd_api.g_ret_sts_success) AND

Line 4966: RAISE fnd_api.g_exc_error;

4962: THEN
4963: x_return_status:=fnd_api.g_ret_sts_success;
4964: ELSE
4965: x_return_status:=fnd_api.g_ret_sts_error;
4966: RAISE fnd_api.g_exc_error;
4967: END IF;
4968:
4969: IF ((x_return_status=fnd_api.g_ret_sts_success) AND
4970: (p_relationship_tbl(l_count).object_id IS NOT NULL) ) THEN

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

4965: x_return_status:=fnd_api.g_ret_sts_error;
4966: RAISE fnd_api.g_exc_error;
4967: END IF;
4968:
4969: IF ((x_return_status=fnd_api.g_ret_sts_success) AND
4970: (p_relationship_tbl(l_count).object_id IS NOT NULL) ) THEN
4971: csi_ii_relationships_pvt.check_for_object
4972: (p_subject_id =>p_relationship_tbl(l_count).subject_id,
4973: p_object_id =>p_relationship_tbl(l_count).object_id,

Line 4979: IF x_return_status<>fnd_api.g_ret_sts_success THEN

4975: x_return_status =>x_return_status,
4976: x_msg_count =>x_msg_count,
4977: x_msg_data =>x_msg_data
4978: );
4979: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4980: RAISE fnd_api.g_exc_error;
4981: END IF;
4982: END IF;
4983: END IF; /* end of additional for cyclic relationship */

Line 4980: RAISE fnd_api.g_exc_error;

4976: x_msg_count =>x_msg_count,
4977: x_msg_data =>x_msg_data
4978: );
4979: IF x_return_status<>fnd_api.g_ret_sts_success THEN
4980: RAISE fnd_api.g_exc_error;
4981: END IF;
4982: END IF;
4983: END IF; /* end of additional for cyclic relationship */
4984: /* Another one for cyclic relationship */

Line 4991: fnd_api.g_miss_num)

4987: IF relationship_not_exists(p_relationship_tbl(l_count).subject_id,
4988: p_relationship_tbl(l_count).object_id,
4989: p_relationship_tbl(l_count).relationship_type_code,
4990: 'CREATE',
4991: fnd_api.g_miss_num)
4992: THEN
4993: x_return_status:=fnd_api.g_ret_sts_success;
4994: ELSE
4995: x_return_status:=fnd_api.g_ret_sts_error;

Line 4993: x_return_status:=fnd_api.g_ret_sts_success;

4989: p_relationship_tbl(l_count).relationship_type_code,
4990: 'CREATE',
4991: fnd_api.g_miss_num)
4992: THEN
4993: x_return_status:=fnd_api.g_ret_sts_success;
4994: ELSE
4995: x_return_status:=fnd_api.g_ret_sts_error;
4996: RAISE fnd_api.g_exc_error;
4997: END IF;

Line 4995: x_return_status:=fnd_api.g_ret_sts_error;

4991: fnd_api.g_miss_num)
4992: THEN
4993: x_return_status:=fnd_api.g_ret_sts_success;
4994: ELSE
4995: x_return_status:=fnd_api.g_ret_sts_error;
4996: RAISE fnd_api.g_exc_error;
4997: END IF;
4998: -- Start of att enhancements by sguthiva
4999: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => p_relationship_tbl(l_count).object_id )

Line 4996: RAISE fnd_api.g_exc_error;

4992: THEN
4993: x_return_status:=fnd_api.g_ret_sts_success;
4994: ELSE
4995: x_return_status:=fnd_api.g_ret_sts_error;
4996: RAISE fnd_api.g_exc_error;
4997: END IF;
4998: -- Start of att enhancements by sguthiva
4999: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => p_relationship_tbl(l_count).object_id )
5000: THEN

Line 5009: RAISE fnd_api.g_exc_error;

5005: THEN
5006: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
5007: fnd_message.set_token('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
5008: fnd_msg_pub.add;
5009: RAISE fnd_api.g_exc_error;
5010: END IF;
5011: END IF;
5012:
5013: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => p_relationship_tbl(l_count).subject_id )

Line 5023: RAISE fnd_api.g_exc_error;

5019: THEN
5020: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
5021: fnd_message.set_token('INSTANCE_ID',p_relationship_tbl(l_count).subject_id);
5022: fnd_msg_pub.add;
5023: RAISE fnd_api.g_exc_error;
5024: END IF;
5025: END IF;
5026: -- End of att enhancements by sguthiva
5027: END IF;

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

5028:
5029: /* end of cyclic relationship */
5030:
5031: IF ((p_relationship_tbl(l_count).active_start_date IS NULL) OR
5032: (p_relationship_tbl(l_count).active_start_date = FND_API.G_MISS_DATE))
5033: THEN
5034: p_relationship_tbl(l_count).active_start_date := SYSDATE;
5035: END IF;
5036:

Line 5037: IF x_return_status=fnd_api.g_ret_sts_success THEN

5033: THEN
5034: p_relationship_tbl(l_count).active_start_date := SYSDATE;
5035: END IF;
5036:
5037: IF x_return_status=fnd_api.g_ret_sts_success THEN
5038: -- srramakr Moved the Update_instance call before the table handler Bug # 3296009
5039: update_instance
5040: ( p_api_version => p_api_version,
5041: p_commit => fnd_api.g_false,

Line 5041: p_commit => fnd_api.g_false,

5037: IF x_return_status=fnd_api.g_ret_sts_success THEN
5038: -- srramakr Moved the Update_instance call before the table handler Bug # 3296009
5039: update_instance
5040: ( p_api_version => p_api_version,
5041: p_commit => fnd_api.g_false,
5042: p_init_msg_list => p_init_msg_list,
5043: p_validation_level => p_validation_level,
5044: p_ii_relationship_rec => p_relationship_tbl(l_count),
5045: p_txn_rec => p_txn_rec,

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

5047: x_return_status => x_return_status,
5048: x_msg_count => x_msg_count,
5049: x_msg_data => x_msg_data);
5050: -- Added by sguthiva for bug 2373109
5051: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
5052: l_msg_index := 1;
5053: l_msg_count := x_msg_count;
5054: WHILE l_msg_count > 0
5055: LOOP

Line 5058: FND_API.G_FALSE );

5054: WHILE l_msg_count > 0
5055: LOOP
5056: x_msg_data := FND_MSG_PUB.GET
5057: ( l_msg_index,
5058: FND_API.G_FALSE );
5059: csi_gen_utility_pvt.put_line( ' Error from CSI_II_RELATIONSHIPS_PVT.CREATE_RELATIONSHIP');
5060: csi_gen_utility_pvt.put_line( ' Call to update_instance has errored ....');
5061: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
5062: l_msg_index := l_msg_index + 1;

Line 5065: RAISE FND_API.G_EXC_ERROR;

5061: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
5062: l_msg_index := l_msg_index + 1;
5063: l_msg_count := l_msg_count - 1;
5064: END LOOP;
5065: RAISE FND_API.G_EXC_ERROR;
5066: END IF;
5067: -- End of addition by sguthiva for bug 2373109
5068:
5069:

Line 5109: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5105: -- hint: primary key should be returned.
5106: -- x_relationship_id := px_relationship_id;
5107: END IF;
5108:
5109: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5110: RAISE fnd_api.g_exc_error;
5111: END IF;
5112:
5113: csi_transactions_pvt.create_transaction

Line 5110: RAISE fnd_api.g_exc_error;

5106: -- x_relationship_id := px_relationship_id;
5107: END IF;
5108:
5109: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5110: RAISE fnd_api.g_exc_error;
5111: END IF;
5112:
5113: csi_transactions_pvt.create_transaction
5114: (

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

5122: ,x_msg_count => x_msg_count
5123: ,x_msg_data => x_msg_data
5124: );
5125:
5126: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5127: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
5128: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
5129: fnd_msg_pub.add;
5130: RAISE fnd_api.g_exc_error;

Line 5130: RAISE fnd_api.g_exc_error;

5126: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5127: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
5128: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
5129: fnd_msg_pub.add;
5130: RAISE fnd_api.g_exc_error;
5131: ROLLBACK TO create_relationship_pvt;
5132: END IF;
5133:
5134: -- The following code has been commented by sguthiva

Line 5141: p_commit => fnd_api.g_false,

5137: -- any changes to the ownership.
5138: /*
5139: update_party_account
5140: ( p_api_version => p_api_version,
5141: p_commit => fnd_api.g_false,
5142: p_init_msg_list => p_init_msg_list,
5143: p_validation_level => p_validation_level,
5144: p_ii_relationship_rec => p_relationship_tbl(l_count),
5145: p_txn_rec => p_txn_rec,

Line 5152: IF x_return_status = fnd_api.g_ret_sts_success THEN

5148: x_msg_data => x_msg_data);
5149: */
5150: -- End addition by sk for bug 2304221
5151:
5152: IF x_return_status = fnd_api.g_ret_sts_success THEN
5153:
5154: l_relship_history_id := NULL;
5155:
5156: csi_ii_relationships_h_pkg.insert_row(

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

5224: l_org_assignments_tbl.delete;
5225: l_instance_id_lst.delete;
5226:
5227: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
5228: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
5229: THEN
5230: l_instance_rec.instance_id:=p_relationship_tbl(l_count).object_id;
5231: END IF;
5232:

Line 5246: RAISE fnd_api.g_exc_error;

5242: WHEN OTHERS
5243: THEN
5244: csi_gen_utility_pvt.put_line( 'Error from create relationship API.');
5245: 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. ');
5246: RAISE fnd_api.g_exc_error;
5247: END;
5248:
5249: csi_item_instance_pub.update_item_instance
5250: ( p_api_version => p_api_version

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

5264: ,x_msg_count => x_msg_count
5265: ,x_msg_data => x_msg_data
5266: );
5267:
5268: IF NOT(x_return_status = fnd_api.g_ret_sts_success)
5269: THEN
5270: csi_gen_utility_pvt.put_line( 'Error from create relationship API.');
5271: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
5272: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');

Line 5275: RAISE fnd_api.g_exc_error;

5271: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
5272: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
5273: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
5274: fnd_msg_pub.add;
5275: RAISE fnd_api.g_exc_error;
5276: END IF;
5277: END IF;
5278:
5279: -- End of cascade ownership changes bug 2972082

Line 5282: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5278:
5279: -- End of cascade ownership changes bug 2972082
5280:
5281: END LOOP;
5282: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5283: RAISE fnd_api.g_exc_error;
5284: END IF;
5285: --
5286: -- END of API BODY

Line 5283: RAISE fnd_api.g_exc_error;

5279: -- End of cascade ownership changes bug 2972082
5280:
5281: END LOOP;
5282: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5283: RAISE fnd_api.g_exc_error;
5284: END IF;
5285: --
5286: -- END of API BODY
5287: --

Line 5290: IF fnd_api.to_boolean( p_commit )

5286: -- END of API BODY
5287: --
5288:
5289: -- standard check for p_commit
5290: IF fnd_api.to_boolean( p_commit )
5291: THEN
5292: COMMIT WORK;
5293: END IF;
5294:

Line 5297: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

5293: END IF;
5294:
5295: -- standard call to get message count and if count is 1, get message info.
5296: fnd_msg_pub.count_AND_get
5297: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
5298: p_count => x_msg_count,
5299: p_data => x_msg_data
5300: );
5301:

Line 5303: WHEN fnd_api.g_exc_error THEN

5299: p_data => x_msg_data
5300: );
5301:
5302: EXCEPTION
5303: WHEN fnd_api.g_exc_error THEN
5304: ROLLBACK TO create_relationship_pvt;
5305: x_return_status := fnd_api.g_ret_sts_error ;
5306: fnd_msg_pub.count_AND_get
5307: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 5305: x_return_status := fnd_api.g_ret_sts_error ;

5301:
5302: EXCEPTION
5303: WHEN fnd_api.g_exc_error THEN
5304: ROLLBACK TO create_relationship_pvt;
5305: x_return_status := fnd_api.g_ret_sts_error ;
5306: fnd_msg_pub.count_AND_get
5307: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
5308: p_count => x_msg_count ,
5309: p_data => x_msg_data

Line 5307: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

5303: WHEN fnd_api.g_exc_error THEN
5304: ROLLBACK TO create_relationship_pvt;
5305: x_return_status := fnd_api.g_ret_sts_error ;
5306: fnd_msg_pub.count_AND_get
5307: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
5308: p_count => x_msg_count ,
5309: p_data => x_msg_data
5310: );
5311:

Line 5312: WHEN fnd_api.g_exc_unexpected_error THEN

5308: p_count => x_msg_count ,
5309: p_data => x_msg_data
5310: );
5311:
5312: WHEN fnd_api.g_exc_unexpected_error THEN
5313: ROLLBACK TO create_relationship_pvt;
5314: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5315: fnd_msg_pub.count_AND_get
5316: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 5314: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5310: );
5311:
5312: WHEN fnd_api.g_exc_unexpected_error THEN
5313: ROLLBACK TO create_relationship_pvt;
5314: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5315: fnd_msg_pub.count_AND_get
5316: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
5317: p_count => x_msg_count ,
5318: p_data => x_msg_data

Line 5316: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

5312: WHEN fnd_api.g_exc_unexpected_error THEN
5313: ROLLBACK TO create_relationship_pvt;
5314: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5315: fnd_msg_pub.count_AND_get
5316: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
5317: p_count => x_msg_count ,
5318: p_data => x_msg_data
5319: );
5320:

Line 5323: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5319: );
5320:
5321: WHEN OTHERS THEN
5322: ROLLBACK TO create_relationship_pvt;
5323: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5324: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
5325: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
5326: END IF;
5327: fnd_msg_pub.count_AND_get

Line 5328: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

5324: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
5325: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
5326: END IF;
5327: fnd_msg_pub.count_AND_get
5328: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
5329: p_count => x_msg_count ,
5330: p_data => x_msg_data
5331: );
5332:

Line 5441: IF NOT fnd_api.compatible_api_call ( l_api_version,

5437: BEGIN
5438: -- standard start of api savepoint
5439: SAVEPOINT update_relationship_pvt;
5440: -- standard call to check for call compatibility.
5441: IF NOT fnd_api.compatible_api_call ( l_api_version,
5442: p_api_version,
5443: l_api_name,
5444: g_pkg_name)
5445: THEN

Line 5446: RAISE fnd_api.g_exc_unexpected_error;

5442: p_api_version,
5443: l_api_name,
5444: g_pkg_name)
5445: THEN
5446: RAISE fnd_api.g_exc_unexpected_error;
5447: END IF;
5448:
5449:
5450: -- initialize message list IF p_init_msg_list IS set TO true.

Line 5451: IF fnd_api.to_boolean( p_init_msg_list )

5447: END IF;
5448:
5449:
5450: -- initialize message list IF p_init_msg_list IS set TO true.
5451: IF fnd_api.to_boolean( p_init_msg_list )
5452: THEN
5453: fnd_msg_pub.initialize;
5454: END IF;
5455:

Line 5458: x_return_status := fnd_api.g_ret_sts_success;

5454: END IF;
5455:
5456:
5457: -- initialize api return status to success
5458: x_return_status := fnd_api.g_ret_sts_success;
5459:
5460:
5461: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
5462: IF (l_debug_level > 0) THEN

Line 5482: p_init_msg_list => fnd_api.g_false,

5478: END IF;
5479:
5480:
5481: validate_ii_relationships(
5482: p_init_msg_list => fnd_api.g_false,
5483: p_validation_level => p_validation_level,
5484: p_validation_mode => 'UPDATE',
5485: p_ii_relationship_tbl => p_relationship_tbl,
5486: x_return_status => x_return_status,

Line 5490: IF x_return_status<>fnd_api.g_ret_sts_success THEN

5486: x_return_status => x_return_status,
5487: x_msg_count => x_msg_count,
5488: x_msg_data => x_msg_data);
5489:
5490: IF x_return_status<>fnd_api.g_ret_sts_success THEN
5491: RAISE fnd_api.g_exc_error;
5492: END IF;
5493:
5494: l_line_count := p_relationship_tbl.count;

Line 5491: RAISE fnd_api.g_exc_error;

5487: x_msg_count => x_msg_count,
5488: x_msg_data => x_msg_data);
5489:
5490: IF x_return_status<>fnd_api.g_ret_sts_success THEN
5491: RAISE fnd_api.g_exc_error;
5492: END IF;
5493:
5494: l_line_count := p_relationship_tbl.count;
5495:

Line 5502: RAISE fnd_api.g_exc_unexpected_error;

5498: /* Cyclic Relationship */
5499: /* added this to validate input parameters */
5500: -- check for infinite loop; Added for bug 10081206
5501: IF (p_relationship_tbl(l_count).subject_id = p_relationship_tbl(l_count).object_id) THEN
5502: RAISE fnd_api.g_exc_unexpected_error;
5503: END IF;
5504: IF NOT valid_in_parameters
5505: (p_relship_id => p_relationship_tbl(l_count).relationship_id,
5506: p_object_id => p_relationship_tbl(l_count).object_id,

Line 5511: RAISE fnd_api.g_exc_error;

5507: p_subject_id => p_relationship_tbl(l_count).subject_id )
5508: THEN
5509: fnd_message.set_name('CSI','CSI_API_INVALID_PARAMETERS');
5510: fnd_msg_pub.add;
5511: RAISE fnd_api.g_exc_error;
5512: END IF;
5513:
5514: --Added for MACD lock functionality
5515: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND

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

5512: END IF;
5513:
5514: --Added for MACD lock functionality
5515: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
5516: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
5517: THEN
5518: IF csi_item_instance_pvt.check_item_instance_lock
5519: ( p_instance_id => p_relationship_tbl(l_count).object_id)
5520: THEN

Line 5526: RAISE FND_API.G_EXC_ERROR;

5522: THEN
5523: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
5524: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).object_id);
5525: FND_MSG_PUB.ADD;
5526: RAISE FND_API.G_EXC_ERROR;
5527: END IF;
5528: END IF;
5529: END IF;
5530: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND

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

5527: END IF;
5528: END IF;
5529: END IF;
5530: IF p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5531: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num
5532: THEN
5533: IF csi_item_instance_pvt.check_item_instance_lock
5534: ( p_instance_id => p_relationship_tbl(l_count).subject_id)
5535: THEN

Line 5541: RAISE FND_API.G_EXC_ERROR;

5537: THEN
5538: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
5539: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',p_relationship_tbl(l_count).subject_id);
5540: FND_MSG_PUB.ADD;
5541: RAISE FND_API.G_EXC_ERROR;
5542: END IF;
5543: END IF;
5544: ELSE
5545: l_subject_lock:=NULL;

Line 5559: RAISE FND_API.G_EXC_ERROR;

5555: THEN
5556: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
5557: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',l_subject_lock);
5558: FND_MSG_PUB.ADD;
5559: RAISE FND_API.G_EXC_ERROR;
5560: END IF;
5561: END IF;
5562: EXCEPTION
5563: WHEN NO_DATA_FOUND THEN

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

5570: l_new_relship_rec:=p_relationship_tbl(l_count);
5571: OPEN relship_csr (p_relationship_tbl(l_count).relationship_id);
5572: FETCH relship_csr INTO l_relship_csr;
5573: IF ( (l_relship_csr.object_version_number<>p_relationship_tbl(l_count).object_version_number)
5574: AND (p_relationship_tbl(l_count).object_version_number <> fnd_api.g_miss_num) ) THEN
5575: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
5576: fnd_msg_pub.add;
5577: RAISE fnd_api.g_exc_error;
5578: END IF;

Line 5577: RAISE fnd_api.g_exc_error;

5573: IF ( (l_relship_csr.object_version_number<>p_relationship_tbl(l_count).object_version_number)
5574: AND (p_relationship_tbl(l_count).object_version_number <> fnd_api.g_miss_num) ) THEN
5575: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
5576: fnd_msg_pub.add;
5577: RAISE fnd_api.g_exc_error;
5578: END IF;
5579: CLOSE relship_csr;
5580:
5581: /* Cyclic relationship */

Line 5586: RAISE fnd_api.g_exc_error;

5582: /* added this call to check configurator_id */
5583: /* IF config_set
5584: (p_relationship_id=>p_relationship_tbl(l_count).relationship_id)
5585: THEN
5586: RAISE fnd_api.g_exc_error;
5587: END IF;
5588: */
5589: /* added this to skip this validation ,in case subject and object_id are null */
5590: IF ((p_relationship_tbl(l_count).relationship_id IS NOT NULL

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

5587: END IF;
5588: */
5589: /* added this to skip this validation ,in case subject and object_id are null */
5590: IF ((p_relationship_tbl(l_count).relationship_id IS NOT NULL
5591: AND p_relationship_tbl(l_count).relationship_id <> fnd_api.g_miss_num)
5592: AND ( p_relationship_tbl(l_count).object_id IS NOT NULL
5593: AND p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num))
5594: THEN
5595: /* End cyclic relationship */

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

5589: /* added this to skip this validation ,in case subject and object_id are null */
5590: IF ((p_relationship_tbl(l_count).relationship_id IS NOT NULL
5591: AND p_relationship_tbl(l_count).relationship_id <> fnd_api.g_miss_num)
5592: AND ( p_relationship_tbl(l_count).object_id IS NOT NULL
5593: AND p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num))
5594: THEN
5595: /* End cyclic relationship */
5596: IF object_relship_exists(p_relationship_tbl(l_count).relationship_id,
5597: p_relationship_tbl(l_count).object_id,

Line 5600: x_return_status := fnd_api.g_ret_sts_success;

5596: IF object_relship_exists(p_relationship_tbl(l_count).relationship_id,
5597: p_relationship_tbl(l_count).object_id,
5598: p_relationship_tbl(l_count).relationship_type_code)
5599: THEN
5600: x_return_status := fnd_api.g_ret_sts_success;
5601: ELSE
5602: x_return_status := fnd_api.g_ret_sts_error;
5603: RAISE fnd_api.g_exc_error;
5604: END IF;

Line 5602: x_return_status := fnd_api.g_ret_sts_error;

5598: p_relationship_tbl(l_count).relationship_type_code)
5599: THEN
5600: x_return_status := fnd_api.g_ret_sts_success;
5601: ELSE
5602: x_return_status := fnd_api.g_ret_sts_error;
5603: RAISE fnd_api.g_exc_error;
5604: END IF;
5605: END IF;
5606:

Line 5603: RAISE fnd_api.g_exc_error;

5599: THEN
5600: x_return_status := fnd_api.g_ret_sts_success;
5601: ELSE
5602: x_return_status := fnd_api.g_ret_sts_error;
5603: RAISE fnd_api.g_exc_error;
5604: END IF;
5605: END IF;
5606:
5607: /* Cyclic relationship -- added the condition to skip the validation for 'CONNECTED-TO' relationship */

Line 5615: x_return_status:=fnd_api.g_ret_sts_success;

5611: p_relship_type_code => p_relationship_tbl(l_count).relationship_type_code,
5612: p_relationship_id => p_relationship_tbl(l_count).relationship_id,
5613: p_mode => 'UPDATE')
5614: THEN
5615: x_return_status:=fnd_api.g_ret_sts_success;
5616: ELSE
5617: x_return_status:=fnd_api.g_ret_sts_error;
5618: RAISE fnd_api.g_exc_error;
5619: END IF;

Line 5617: x_return_status:=fnd_api.g_ret_sts_error;

5613: p_mode => 'UPDATE')
5614: THEN
5615: x_return_status:=fnd_api.g_ret_sts_success;
5616: ELSE
5617: x_return_status:=fnd_api.g_ret_sts_error;
5618: RAISE fnd_api.g_exc_error;
5619: END IF;
5620: --
5621: -- check whether the Inverse Active Relationship exists

Line 5618: RAISE fnd_api.g_exc_error;

5614: THEN
5615: x_return_status:=fnd_api.g_ret_sts_success;
5616: ELSE
5617: x_return_status:=fnd_api.g_ret_sts_error;
5618: RAISE fnd_api.g_exc_error;
5619: END IF;
5620: --
5621: -- check whether the Inverse Active Relationship exists
5622: Begin

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

5622: Begin
5623: select 'x'
5624: into l_exists
5625: from csi_ii_relationships
5626: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,
5627: p_relationship_tbl(l_count).subject_id)
5628: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,
5629: p_relationship_tbl(l_count).object_id)
5630: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,

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

5624: into l_exists
5625: from csi_ii_relationships
5626: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,
5627: p_relationship_tbl(l_count).subject_id)
5628: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,
5629: p_relationship_tbl(l_count).object_id)
5630: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,
5631: l_relship_csr.relationship_type_code,
5632: p_relationship_tbl(l_count).relationship_type_code)

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

5626: where object_id = decode(p_relationship_tbl(l_count).subject_id,fnd_api.g_miss_num,l_relship_csr.subject_id,
5627: p_relationship_tbl(l_count).subject_id)
5628: and subject_id = decode(p_relationship_tbl(l_count).object_id,fnd_api.g_miss_num,l_relship_csr.object_id,
5629: p_relationship_tbl(l_count).object_id)
5630: and relationship_type_code = decode(p_relationship_tbl(l_count).relationship_type_code,fnd_api.g_miss_char,
5631: l_relship_csr.relationship_type_code,
5632: p_relationship_tbl(l_count).relationship_type_code)
5633: and ((active_end_date is null) or (active_end_date > sysdate))
5634: and relationship_id <> p_relationship_tbl(l_count).relationship_id;

Line 5638: x_return_status := fnd_api.g_ret_sts_error;

5634: and relationship_id <> p_relationship_tbl(l_count).relationship_id;
5635: --
5636: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');
5637: fnd_msg_pub.add;
5638: x_return_status := fnd_api.g_ret_sts_error;
5639: RAISE fnd_api.g_exc_error;
5640: Exception
5641: when no_data_found then
5642: null;

Line 5639: RAISE fnd_api.g_exc_error;

5635: --
5636: fnd_message.set_name('CSI','CSI_CHILD_PARENT_REL_LOOP');
5637: fnd_msg_pub.add;
5638: x_return_status := fnd_api.g_ret_sts_error;
5639: RAISE fnd_api.g_exc_error;
5640: Exception
5641: when no_data_found then
5642: null;
5643: End;

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

5645: -- Start of att enhancements by sguthiva
5646: ELSIF p_relationship_tbl(l_count).relationship_type_code = 'CONNECTED-TO'
5647: THEN
5648: IF p_relationship_tbl(l_count).object_id IS NULL OR
5649: p_relationship_tbl(l_count).object_id=fnd_api.g_miss_num
5650: THEN
5651: l_obj_id:=NULL;
5652: BEGIN
5653: SELECT object_id

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

5662: l_obj_id := p_relationship_tbl(l_count).object_id;
5663: END IF;
5664: --
5665: IF p_relationship_tbl(l_count).subject_id IS NULL OR
5666: p_relationship_tbl(l_count).subject_id=fnd_api.g_miss_num
5667: THEN
5668: l_sub_id:=NULL;
5669: BEGIN
5670: SELECT subject_id

Line 5692: RAISE fnd_api.g_exc_error;

5688: THEN
5689: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
5690: fnd_message.set_token('INSTANCE_ID',l_obj_id);
5691: fnd_msg_pub.add;
5692: RAISE fnd_api.g_exc_error;
5693: END IF;
5694: END IF;
5695: --
5696: IF csi_ii_relationships_pvt.Is_link_type (p_instance_id => l_sub_id )

Line 5706: RAISE fnd_api.g_exc_error;

5702: THEN
5703: fnd_message.set_name('CSI','CSI_LINK_EXISTS');
5704: fnd_message.set_token('INSTANCE_ID',l_sub_id);
5705: fnd_msg_pub.add;
5706: RAISE fnd_api.g_exc_error;
5707: END IF;
5708: END IF;
5709: -- End of att enhancements by sguthiva
5710: END IF;

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

5709: -- End of att enhancements by sguthiva
5710: END IF;
5711: --
5712: IF (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5713: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5714: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id
5715: AND ( (p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5716: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5717: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF'

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

5712: IF (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5713: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5714: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id
5715: AND ( (p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5716: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5717: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF'
5718: )
5719: OR (p_relationship_tbl(l_count).relationship_type_code = fnd_api.g_miss_char AND
5720: l_relship_csr.relationship_type_code = 'COMPONENT-OF'

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

5715: AND ( (p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5716: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5717: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF'
5718: )
5719: OR (p_relationship_tbl(l_count).relationship_type_code = fnd_api.g_miss_char AND
5720: l_relship_csr.relationship_type_code = 'COMPONENT-OF'
5721: )
5722: )
5723: )

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

5723: )
5724: OR
5725: (l_relship_csr.relationship_type_code = 'COMPONENT-OF' AND
5726: p_relationship_tbl(l_count).ACTIVE_END_DATE <= SYSDATE AND
5727: p_relationship_tbl(l_count).ACTIVE_END_DATE <> fnd_api.g_miss_date AND
5728: p_relationship_tbl(l_count).ACTIVE_END_DATE IS NOT NULL
5729: )
5730: THEN
5731: l_object_id := NULL;

Line 5805: x_return_status:=fnd_api.g_ret_sts_success;

5801: p_relationship_tbl(l_count).relationship_type_code,
5802: 'UPDATE',
5803: p_relationship_tbl(l_count).relationship_id)
5804: THEN
5805: x_return_status:=fnd_api.g_ret_sts_success;
5806: ELSE
5807: x_return_status:=fnd_api.g_ret_sts_error;
5808: RAISE fnd_api.g_exc_error;
5809: END IF;

Line 5807: x_return_status:=fnd_api.g_ret_sts_error;

5803: p_relationship_tbl(l_count).relationship_id)
5804: THEN
5805: x_return_status:=fnd_api.g_ret_sts_success;
5806: ELSE
5807: x_return_status:=fnd_api.g_ret_sts_error;
5808: RAISE fnd_api.g_exc_error;
5809: END IF;
5810: END IF;
5811:

Line 5808: RAISE fnd_api.g_exc_error;

5804: THEN
5805: x_return_status:=fnd_api.g_ret_sts_success;
5806: ELSE
5807: x_return_status:=fnd_api.g_ret_sts_error;
5808: RAISE fnd_api.g_exc_error;
5809: END IF;
5810: END IF;
5811:
5812: IF x_return_status = fnd_api.g_ret_sts_success THEN

Line 5812: IF x_return_status = fnd_api.g_ret_sts_success THEN

5808: RAISE fnd_api.g_exc_error;
5809: END IF;
5810: END IF;
5811:
5812: IF x_return_status = fnd_api.g_ret_sts_success THEN
5813: -- Update for the New subject only if the subject or relationship type is changing
5814: -- OR during Un-expiry
5815: IF (( (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5816: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND

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

5812: IF x_return_status = fnd_api.g_ret_sts_success THEN
5813: -- Update for the New subject only if the subject or relationship type is changing
5814: -- OR during Un-expiry
5815: IF (( (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5816: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5817: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id) OR
5818: ( p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5819: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5820: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF' AND

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

5815: IF (( (p_relationship_tbl(l_count).subject_id IS NOT NULL AND
5816: p_relationship_tbl(l_count).subject_id <> fnd_api.g_miss_num AND
5817: l_relship_csr.subject_id <> p_relationship_tbl(l_count).subject_id) OR
5818: ( p_relationship_tbl(l_count).relationship_type_code IS NOT NULL AND
5819: p_relationship_tbl(l_count).relationship_type_code <> fnd_api.g_miss_char AND
5820: p_relationship_tbl(l_count).relationship_type_code = 'COMPONENT-OF' AND
5821: l_relship_csr.relationship_type_code <> p_relationship_tbl(l_count).relationship_type_code) )
5822: OR
5823: ( (p_relationship_tbl(l_count).active_end_date IS NULL AND

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

5821: l_relship_csr.relationship_type_code <> p_relationship_tbl(l_count).relationship_type_code) )
5822: OR
5823: ( (p_relationship_tbl(l_count).active_end_date IS NULL AND
5824: nvl(l_relship_csr.active_end_date,(sysdate+1)) <= SYSDATE) AND
5825: (p_relationship_tbl(l_count).subject_id = FND_API.G_MISS_NUM OR
5826: p_relationship_tbl(l_count).subject_id = l_relship_csr.subject_id) )
5827: )
5828: THEN
5829: csi_gen_utility_pvt.put_line('Calling Update_Instance..');

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

5828: THEN
5829: csi_gen_utility_pvt.put_line('Calling Update_Instance..');
5830: update_instance
5831: ( p_api_version => p_api_version,
5832: p_commit => fnd_api.g_false,--p_commit,
5833: p_init_msg_list => p_init_msg_list,
5834: p_validation_level => p_validation_level,
5835: p_ii_relationship_rec => p_relationship_tbl(l_count),
5836: p_txn_rec => p_txn_rec,

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

5837: p_mode => 'UPDATE',
5838: x_return_status => x_return_status,
5839: x_msg_count => x_msg_count,
5840: x_msg_data => x_msg_data);
5841: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
5842: l_msg_index := 1;
5843: l_msg_count := x_msg_count;
5844: WHILE l_msg_count > 0
5845: LOOP

Line 5848: FND_API.G_FALSE );

5844: WHILE l_msg_count > 0
5845: LOOP
5846: x_msg_data := FND_MSG_PUB.GET
5847: ( l_msg_index,
5848: FND_API.G_FALSE );
5849: csi_gen_utility_pvt.put_line( ' Error from CSI_II_RELATIONSHIPS_PVT.UPDATE_RELATIONSHIP');
5850: csi_gen_utility_pvt.put_line( ' Call to update_instance has errored ....');
5851: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
5852: l_msg_index := l_msg_index + 1;

Line 5855: RAISE FND_API.G_EXC_ERROR;

5851: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
5852: l_msg_index := l_msg_index + 1;
5853: l_msg_count := l_msg_count - 1;
5854: END LOOP;
5855: RAISE FND_API.G_EXC_ERROR;
5856: END IF;
5857: END IF;
5858: --
5859: csi_ii_relationships_pkg.update_row(

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

5861: p_relationship_type_code => p_relationship_tbl(l_count).relationship_type_code,
5862: p_object_id => p_relationship_tbl(l_count).object_id,
5863: p_subject_id => p_relationship_tbl(l_count).subject_id,
5864: p_position_reference => p_relationship_tbl(l_count).position_reference,
5865: p_active_start_date => fnd_api.g_miss_date, -- p_relationship_tbl(l_count).active_start_date,
5866: p_active_end_date => p_relationship_tbl(l_count).active_end_date,
5867: p_display_order => p_relationship_tbl(l_count).display_order,
5868: p_mandatory_flag => p_relationship_tbl(l_count).mandatory_flag,
5869: p_context => p_relationship_tbl(l_count).context,

Line 5885: p_created_by => fnd_api.g_miss_num,

5881: p_attribute12 => p_relationship_tbl(l_count).attribute12,
5882: p_attribute13 => p_relationship_tbl(l_count).attribute13,
5883: p_attribute14 => p_relationship_tbl(l_count).attribute14,
5884: p_attribute15 => p_relationship_tbl(l_count).attribute15,
5885: p_created_by => fnd_api.g_miss_num,
5886: p_creation_date => fnd_api.g_miss_date,
5887: p_last_updated_by => fnd_global.user_id,
5888: p_last_update_date => SYSDATE,
5889: p_last_update_login => fnd_global.conc_login_id,

Line 5886: p_creation_date => fnd_api.g_miss_date,

5882: p_attribute13 => p_relationship_tbl(l_count).attribute13,
5883: p_attribute14 => p_relationship_tbl(l_count).attribute14,
5884: p_attribute15 => p_relationship_tbl(l_count).attribute15,
5885: p_created_by => fnd_api.g_miss_num,
5886: p_creation_date => fnd_api.g_miss_date,
5887: p_last_updated_by => fnd_global.user_id,
5888: p_last_update_date => SYSDATE,
5889: p_last_update_login => fnd_global.conc_login_id,
5890: p_object_version_number => p_relationship_tbl(l_count).object_version_number);

Line 5891: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5887: p_last_updated_by => fnd_global.user_id,
5888: p_last_update_date => SYSDATE,
5889: p_last_update_login => fnd_global.conc_login_id,
5890: p_object_version_number => p_relationship_tbl(l_count).object_version_number);
5891: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5892: RAISE fnd_api.g_exc_error;
5893: END IF;
5894:
5895: /*

Line 5892: RAISE fnd_api.g_exc_error;

5888: p_last_update_date => SYSDATE,
5889: p_last_update_login => fnd_global.conc_login_id,
5890: p_object_version_number => p_relationship_tbl(l_count).object_version_number);
5891: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5892: RAISE fnd_api.g_exc_error;
5893: END IF;
5894:
5895: /*
5896: ELSE

Line 5899: p_commit => fnd_api.g_false,

5895: /*
5896: ELSE
5897: csi_ii_relationships_pvt.expire_relationship
5898: (p_api_version => p_api_version,
5899: p_commit => fnd_api.g_false,
5900: p_init_msg_list => p_init_msg_list,
5901: p_validation_level => p_validation_level,
5902: p_relationship_rec => p_relationship_tbl(l_count),
5903: p_txn_rec => p_txn_rec,

Line 5910: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5906: x_msg_count => x_msg_count,
5907: x_msg_data => x_msg_data);
5908:
5909:
5910: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5911: RAISE fnd_api.g_exc_error;
5912: END IF;
5913:
5914: l_relationship_tbl(1).relationship_type_code := p_relationship_tbl(l_count).relationship_type_code; --'CONNECTED-TO' ;

Line 5911: RAISE fnd_api.g_exc_error;

5907: x_msg_data => x_msg_data);
5908:
5909:
5910: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5911: RAISE fnd_api.g_exc_error;
5912: END IF;
5913:
5914: l_relationship_tbl(1).relationship_type_code := p_relationship_tbl(l_count).relationship_type_code; --'CONNECTED-TO' ;
5915: l_relationship_tbl(1).object_id := p_relationship_tbl(l_count).object_id;

Line 5923: p_commit => fnd_api.g_false,

5919: l_relationship_tbl(1).object_version_number:=1;
5920:
5921: csi_ii_relationships_pvt.create_relationship(
5922: p_api_version => p_api_version,
5923: p_commit => fnd_api.g_false,
5924: p_init_msg_list => p_init_msg_list,
5925: p_validation_level => p_validation_level,
5926: p_relationship_tbl => l_relationship_tbl,
5927: p_txn_rec => p_txn_rec,

Line 5932: IF x_return_status <> fnd_api.g_ret_sts_success THEN

5928: x_return_status => x_return_status,
5929: x_msg_count => x_msg_count,
5930: x_msg_data => x_msg_data);
5931:
5932: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5933: RAISE fnd_api.g_exc_error;
5934: END IF;
5935: -- END IF;
5936: */

Line 5933: RAISE fnd_api.g_exc_error;

5929: x_msg_count => x_msg_count,
5930: x_msg_data => x_msg_data);
5931:
5932: IF x_return_status <> fnd_api.g_ret_sts_success THEN
5933: RAISE fnd_api.g_exc_error;
5934: END IF;
5935: -- END IF;
5936: */
5937: -- END IF;

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

5936: */
5937: -- END IF;
5938: END IF;
5939:
5940: /* IF x_return_status <> fnd_api.g_ret_sts_success THEN
5941: RAISE fnd_api.g_exc_error;
5942: END IF;*/
5943: csi_transactions_pvt.create_transaction
5944: (

Line 5941: RAISE fnd_api.g_exc_error;

5937: -- END IF;
5938: END IF;
5939:
5940: /* IF x_return_status <> fnd_api.g_ret_sts_success THEN
5941: RAISE fnd_api.g_exc_error;
5942: END IF;*/
5943: csi_transactions_pvt.create_transaction
5944: (
5945: p_api_version => p_api_version

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

5952: ,x_msg_count => x_msg_count
5953: ,x_msg_data => x_msg_data
5954: );
5955:
5956: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5957: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
5958: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
5959: fnd_msg_pub.add;
5960: RAISE fnd_api.g_exc_error;

Line 5960: RAISE fnd_api.g_exc_error;

5956: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
5957: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
5958: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
5959: fnd_msg_pub.add;
5960: RAISE fnd_api.g_exc_error;
5961: ROLLBACK TO create_relationship_pvt;
5962: END IF;
5963: --
5964:

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

6000: l_instance_rec.object_version_number IS NOT NULL AND
6001: l_found AND l_is_a_child <> 'Y' --Changed for Bug 14163453
6002: THEN
6003: IF l_relship_csr.subject_id = l_instance_rec.instance_id AND
6004: nvl(p_replace_flag,fnd_api.g_false)<> fnd_api.g_true
6005: THEN
6006: csi_gen_utility_pvt.put_line('Calling update_item_instance..');
6007: csi_gen_utility_pvt.put_line('Parameter p_called_from_rel set to true..');
6008: csi_item_instance_pvt.update_item_instance

Line 6024: ,p_called_from_rel => fnd_api.g_true

6020: ,p_location_tbl => l_location_tbl
6021: ,p_generic_id_tbl => l_generic_id_tbl
6022: ,p_lookup_tbl => l_lookup_tbl
6023: ,p_ins_count_rec => l_ins_count_rec
6024: ,p_called_from_rel => fnd_api.g_true
6025: ,p_oks_txn_inst_tbl => px_oks_txn_inst_tbl
6026: ,p_child_inst_tbl => px_child_inst_tbl
6027: );
6028: END IF;

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

6026: ,p_child_inst_tbl => px_child_inst_tbl
6027: );
6028: END IF;
6029:
6030: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6031: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6032: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6033: fnd_msg_pub.add;
6034: RAISE fnd_api.g_exc_error;

Line 6034: RAISE fnd_api.g_exc_error;

6030: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6031: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6032: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6033: fnd_msg_pub.add;
6034: RAISE fnd_api.g_exc_error;
6035: END IF;
6036: END IF;
6037: --
6038: l_old_relship_rec.relationship_id := l_relship_csr.relationship_id;

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

6087: l_org_assignments_tbl.delete;
6088: l_inst_id_lst.delete;
6089:
6090: IF p_relationship_tbl(l_count).object_id IS NOT NULL AND
6091: p_relationship_tbl(l_count).object_id <> fnd_api.g_miss_num
6092: THEN
6093: l_inst_rec.instance_id:=p_relationship_tbl(l_count).object_id;
6094: ELSE
6095: BEGIN

Line 6105: RAISE fnd_api.g_exc_error;

6101: WHEN OTHERS
6102: THEN
6103: csi_gen_utility_pvt.put_line( 'Error from update relationship API.');
6104: csi_gen_utility_pvt.put_line( 'Object_id not found in csi_ii_relationships to cascade ownership');
6105: RAISE fnd_api.g_exc_error;
6106: END;
6107: END IF;
6108:
6109: BEGIN

Line 6122: RAISE fnd_api.g_exc_error;

6118: WHEN OTHERS
6119: THEN
6120: csi_gen_utility_pvt.put_line( 'Error from update relationship API.');
6121: 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. ');
6122: RAISE fnd_api.g_exc_error;
6123: END;
6124:
6125: csi_item_instance_pub.update_item_instance
6126: ( p_api_version => p_api_version

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

6140: ,x_msg_count => x_msg_count
6141: ,x_msg_data => x_msg_data
6142: );
6143:
6144: IF NOT(x_return_status = fnd_api.g_ret_sts_success)
6145: THEN
6146: csi_gen_utility_pvt.put_line( 'Error from update relationship API.');
6147: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
6148: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');

Line 6151: RAISE fnd_api.g_exc_error;

6147: csi_gen_utility_pvt.put_line( 'Call to update_item_instance API for cascade ownership has errored');
6148: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6149: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6150: fnd_msg_pub.add;
6151: RAISE fnd_api.g_exc_error;
6152: END IF;
6153: END IF;
6154:
6155: -- End of cascade ownership changes bug 2972082

Line 6163: IF x_return_status <> fnd_api.g_ret_sts_success THEN

6159: --
6160: -- END of API body.
6161: --
6162:
6163: IF x_return_status <> fnd_api.g_ret_sts_success THEN
6164: RAISE fnd_api.g_exc_error;
6165: END IF;
6166:
6167: -- standard check for p_commit

Line 6164: RAISE fnd_api.g_exc_error;

6160: -- END of API body.
6161: --
6162:
6163: IF x_return_status <> fnd_api.g_ret_sts_success THEN
6164: RAISE fnd_api.g_exc_error;
6165: END IF;
6166:
6167: -- standard check for p_commit
6168: IF fnd_api.to_boolean( p_commit )

Line 6168: IF fnd_api.to_boolean( p_commit )

6164: RAISE fnd_api.g_exc_error;
6165: END IF;
6166:
6167: -- standard check for p_commit
6168: IF fnd_api.to_boolean( p_commit )
6169: THEN
6170: COMMIT WORK;
6171: END IF;
6172:

Line 6178: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6174:
6175:
6176: -- standard call to get message count and if count is 1, get message info.
6177: fnd_msg_pub.count_AND_get
6178: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6179: p_count => x_msg_count,
6180: p_data => x_msg_data
6181: );
6182:

Line 6184: WHEN fnd_api.g_exc_error THEN

6180: p_data => x_msg_data
6181: );
6182:
6183: EXCEPTION
6184: WHEN fnd_api.g_exc_error THEN
6185: ROLLBACK TO update_relationship_pvt;
6186: x_return_status := fnd_api.g_ret_sts_error ;
6187: fnd_msg_pub.count_AND_get
6188: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 6186: x_return_status := fnd_api.g_ret_sts_error ;

6182:
6183: EXCEPTION
6184: WHEN fnd_api.g_exc_error THEN
6185: ROLLBACK TO update_relationship_pvt;
6186: x_return_status := fnd_api.g_ret_sts_error ;
6187: fnd_msg_pub.count_AND_get
6188: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6189: p_count => x_msg_count ,
6190: p_data => x_msg_data

Line 6188: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6184: WHEN fnd_api.g_exc_error THEN
6185: ROLLBACK TO update_relationship_pvt;
6186: x_return_status := fnd_api.g_ret_sts_error ;
6187: fnd_msg_pub.count_AND_get
6188: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6189: p_count => x_msg_count ,
6190: p_data => x_msg_data
6191: );
6192:

Line 6193: WHEN fnd_api.g_exc_unexpected_error THEN

6189: p_count => x_msg_count ,
6190: p_data => x_msg_data
6191: );
6192:
6193: WHEN fnd_api.g_exc_unexpected_error THEN
6194: ROLLBACK TO update_relationship_pvt;
6195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6196: fnd_msg_pub.count_AND_get
6197: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 6195: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6191: );
6192:
6193: WHEN fnd_api.g_exc_unexpected_error THEN
6194: ROLLBACK TO update_relationship_pvt;
6195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6196: fnd_msg_pub.count_AND_get
6197: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6198: p_count => x_msg_count ,
6199: p_data => x_msg_data

Line 6197: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6193: WHEN fnd_api.g_exc_unexpected_error THEN
6194: ROLLBACK TO update_relationship_pvt;
6195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6196: fnd_msg_pub.count_AND_get
6197: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6198: p_count => x_msg_count ,
6199: p_data => x_msg_data
6200: );
6201:

Line 6204: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6200: );
6201:
6202: WHEN OTHERS THEN
6203: ROLLBACK TO update_relationship_pvt;
6204: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6205: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6206: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
6207: END IF;
6208: fnd_msg_pub.count_AND_get

Line 6209: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6205: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6206: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
6207: END IF;
6208: fnd_msg_pub.count_AND_get
6209: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6210: p_count => x_msg_count ,
6211: p_data => x_msg_data
6212: );
6213:

Line 6297: IF NOT fnd_api.compatible_api_call ( l_api_version,

6293: -- standard start of api savepoint
6294: SAVEPOINT expire_relationship_pvt;
6295:
6296: -- standard call to check for call compatibility.
6297: IF NOT fnd_api.compatible_api_call ( l_api_version,
6298: p_api_version,
6299: l_api_name,
6300: g_pkg_name)
6301: THEN

Line 6302: RAISE fnd_api.g_exc_unexpected_error;

6298: p_api_version,
6299: l_api_name,
6300: g_pkg_name)
6301: THEN
6302: RAISE fnd_api.g_exc_unexpected_error;
6303: END IF;
6304:
6305: -- initialize message list if p_init_msg_list is set to true.
6306: IF fnd_api.to_boolean( p_init_msg_list )

Line 6306: IF fnd_api.to_boolean( p_init_msg_list )

6302: RAISE fnd_api.g_exc_unexpected_error;
6303: END IF;
6304:
6305: -- initialize message list if p_init_msg_list is set to true.
6306: IF fnd_api.to_boolean( p_init_msg_list )
6307: THEN
6308: fnd_msg_pub.initialize;
6309: END IF;
6310:

Line 6312: x_return_status := fnd_api.g_ret_sts_success;

6308: fnd_msg_pub.initialize;
6309: END IF;
6310:
6311: -- initialize api return status to success
6312: x_return_status := fnd_api.g_ret_sts_success;
6313:
6314: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
6315: IF (l_debug_level > 0) THEN
6316: CSI_gen_utility_pvt.put_line( 'expire_relationship');

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

6336: --
6337: OPEN relship_csr (p_relationship_rec.relationship_id);
6338: FETCH relship_csr INTO l_relship_csr;
6339: IF ( (l_relship_csr.object_version_number<>p_relationship_rec.object_version_number)
6340: AND (p_relationship_rec.object_version_number <> fnd_api.g_miss_num) ) THEN
6341: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
6342: fnd_msg_pub.add;
6343: RAISE fnd_api.g_exc_error;
6344: END IF;

Line 6343: RAISE fnd_api.g_exc_error;

6339: IF ( (l_relship_csr.object_version_number<>p_relationship_rec.object_version_number)
6340: AND (p_relationship_rec.object_version_number <> fnd_api.g_miss_num) ) THEN
6341: fnd_message.set_name('CSI', 'CSI_RECORD_CHANGED');
6342: fnd_msg_pub.add;
6343: RAISE fnd_api.g_exc_error;
6344: END IF;
6345: CLOSE relship_csr;
6346:
6347: l_ii_relationship_tbl(1) := p_relationship_rec;

Line 6349: p_init_msg_list => fnd_api.g_false,

6345: CLOSE relship_csr;
6346:
6347: l_ii_relationship_tbl(1) := p_relationship_rec;
6348: validate_ii_relationships(
6349: p_init_msg_list => fnd_api.g_false,
6350: p_validation_level => p_validation_level,
6351: p_validation_mode => 'EXPIRE',
6352: p_ii_relationship_tbl => l_ii_relationship_tbl,
6353: x_return_status => x_return_status,

Line 6357: IF x_return_status<>fnd_api.g_ret_sts_success THEN

6353: x_return_status => x_return_status,
6354: x_msg_count => x_msg_count,
6355: x_msg_data => x_msg_data);
6356:
6357: IF x_return_status<>fnd_api.g_ret_sts_success THEN
6358: RAISE fnd_api.g_exc_error;
6359: END IF;
6360: IF l_relship_csr.relationship_type_code = 'COMPONENT-OF'
6361: THEN

Line 6358: RAISE fnd_api.g_exc_error;

6354: x_msg_count => x_msg_count,
6355: x_msg_data => x_msg_data);
6356:
6357: IF x_return_status<>fnd_api.g_ret_sts_success THEN
6358: RAISE fnd_api.g_exc_error;
6359: END IF;
6360: IF l_relship_csr.relationship_type_code = 'COMPONENT-OF'
6361: THEN
6362: BEGIN

Line 6435: l_relship_csr.object_id <> fnd_api.g_miss_num

6431:
6432:
6433: --Added for MACD lock functionality
6434: IF l_relship_csr.object_id IS NOT NULL AND
6435: l_relship_csr.object_id <> fnd_api.g_miss_num
6436: THEN
6437: --Added for Bug 12357214
6438: BEGIN
6439: SELECT l_lock_id

Line 6445: AND nvl(lock_source_header_ref, fnd_api.g_miss_char) <> nvl(p_txn_rec.SOURCE_HEADER_REF, fnd_api.g_miss_char);

6441: FROM csi_item_instance_locks
6442: WHERE lock_status IS NOT NULL
6443: AND lock_status <> 0
6444: AND instance_id = l_relship_csr.object_id
6445: AND nvl(lock_source_header_ref, fnd_api.g_miss_char) <> nvl(p_txn_rec.SOURCE_HEADER_REF, fnd_api.g_miss_char);
6446:
6447: l_is_locked := TRUE;
6448: EXCEPTION
6449: WHEN NO_DATA_FOUND THEN

Line 6465: RAISE FND_API.G_EXC_ERROR;

6461: THEN
6462: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
6463: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',l_relship_csr.object_id);
6464: FND_MSG_PUB.ADD;
6465: RAISE FND_API.G_EXC_ERROR;
6466: END IF;
6467: END IF;
6468: END IF;
6469:

Line 6471: l_relship_csr.subject_id <> fnd_api.g_miss_num

6467: END IF;
6468: END IF;
6469:
6470: IF l_relship_csr.subject_id IS NOT NULL AND
6471: l_relship_csr.subject_id <> fnd_api.g_miss_num
6472: THEN
6473: --Added for Bug 12357214
6474: BEGIN
6475: SELECT l_lock_id

Line 6481: AND nvl(lock_source_header_ref, fnd_api.g_miss_char) <> nvl(p_txn_rec.SOURCE_HEADER_REF, fnd_api.g_miss_char);

6477: FROM csi_item_instance_locks
6478: WHERE lock_status IS NOT NULL
6479: AND lock_status <> 0
6480: AND instance_id= l_relship_csr.subject_id
6481: AND nvl(lock_source_header_ref, fnd_api.g_miss_char) <> nvl(p_txn_rec.SOURCE_HEADER_REF, fnd_api.g_miss_char);
6482:
6483: l_is_locked := TRUE;
6484: EXCEPTION
6485: WHEN NO_DATA_FOUND THEN

Line 6497: RAISE FND_API.G_EXC_ERROR;

6493: THEN
6494: FND_MESSAGE.SET_NAME('CSI','CSI_LOCKED_INSTANCE');
6495: FND_MESSAGE.SET_TOKEN('INSTANCE_ID',l_relship_csr.subject_id);
6496: FND_MSG_PUB.ADD;
6497: RAISE FND_API.G_EXC_ERROR;
6498: END IF;
6499: END IF;
6500: -- End addition for MACD lock functionality
6501:

Line 6506: p_relationship_type_code => fnd_api.g_miss_char,

6502:
6503:
6504: csi_ii_relationships_pkg.update_row(
6505: p_relationship_id => p_relationship_rec.relationship_id,
6506: p_relationship_type_code => fnd_api.g_miss_char,
6507: p_object_id => fnd_api.g_miss_num,
6508: p_subject_id => fnd_api.g_miss_num,
6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,

Line 6507: p_object_id => fnd_api.g_miss_num,

6503:
6504: csi_ii_relationships_pkg.update_row(
6505: p_relationship_id => p_relationship_rec.relationship_id,
6506: p_relationship_type_code => fnd_api.g_miss_char,
6507: p_object_id => fnd_api.g_miss_num,
6508: p_subject_id => fnd_api.g_miss_num,
6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,

Line 6508: p_subject_id => fnd_api.g_miss_num,

6504: csi_ii_relationships_pkg.update_row(
6505: p_relationship_id => p_relationship_rec.relationship_id,
6506: p_relationship_type_code => fnd_api.g_miss_char,
6507: p_object_id => fnd_api.g_miss_num,
6508: p_subject_id => fnd_api.g_miss_num,
6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,

Line 6509: p_position_reference => fnd_api.g_miss_char,

6505: p_relationship_id => p_relationship_rec.relationship_id,
6506: p_relationship_type_code => fnd_api.g_miss_char,
6507: p_object_id => fnd_api.g_miss_num,
6508: p_subject_id => fnd_api.g_miss_num,
6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,

Line 6510: p_active_start_date => fnd_api.g_miss_date,

6506: p_relationship_type_code => fnd_api.g_miss_char,
6507: p_object_id => fnd_api.g_miss_num,
6508: p_subject_id => fnd_api.g_miss_num,
6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,

Line 6512: p_display_order => fnd_api.g_miss_num,

6508: p_subject_id => fnd_api.g_miss_num,
6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,

Line 6513: p_mandatory_flag => fnd_api.g_miss_char,

6509: p_position_reference => fnd_api.g_miss_char,
6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,

Line 6514: p_context => fnd_api.g_miss_char,

6510: p_active_start_date => fnd_api.g_miss_date,
6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,

Line 6515: p_attribute1 => fnd_api.g_miss_char,

6511: p_active_end_date => l_sysdate,
6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,

Line 6516: p_attribute2 => fnd_api.g_miss_char,

6512: p_display_order => fnd_api.g_miss_num,
6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,

Line 6517: p_attribute3 => fnd_api.g_miss_char,

6513: p_mandatory_flag => fnd_api.g_miss_char,
6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,

Line 6518: p_attribute4 => fnd_api.g_miss_char,

6514: p_context => fnd_api.g_miss_char,
6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,

Line 6519: p_attribute5 => fnd_api.g_miss_char,

6515: p_attribute1 => fnd_api.g_miss_char,
6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,

Line 6520: p_attribute6 => fnd_api.g_miss_char,

6516: p_attribute2 => fnd_api.g_miss_char,
6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,

Line 6521: p_attribute7 => fnd_api.g_miss_char,

6517: p_attribute3 => fnd_api.g_miss_char,
6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,

Line 6522: p_attribute8 => fnd_api.g_miss_char,

6518: p_attribute4 => fnd_api.g_miss_char,
6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,

Line 6523: p_attribute9 => fnd_api.g_miss_char,

6519: p_attribute5 => fnd_api.g_miss_char,
6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,

Line 6524: p_attribute10 => fnd_api.g_miss_char,

6520: p_attribute6 => fnd_api.g_miss_char,
6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,

Line 6525: p_attribute11 => fnd_api.g_miss_char,

6521: p_attribute7 => fnd_api.g_miss_char,
6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,

Line 6526: p_attribute12 => fnd_api.g_miss_char,

6522: p_attribute8 => fnd_api.g_miss_char,
6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,
6530: p_created_by => fnd_api.g_miss_num,

Line 6527: p_attribute13 => fnd_api.g_miss_char,

6523: p_attribute9 => fnd_api.g_miss_char,
6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,
6530: p_created_by => fnd_api.g_miss_num,
6531: p_creation_date => fnd_api.g_miss_date,

Line 6528: p_attribute14 => fnd_api.g_miss_char,

6524: p_attribute10 => fnd_api.g_miss_char,
6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,
6530: p_created_by => fnd_api.g_miss_num,
6531: p_creation_date => fnd_api.g_miss_date,
6532: p_last_updated_by => fnd_global.user_id,

Line 6529: p_attribute15 => fnd_api.g_miss_char,

6525: p_attribute11 => fnd_api.g_miss_char,
6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,
6530: p_created_by => fnd_api.g_miss_num,
6531: p_creation_date => fnd_api.g_miss_date,
6532: p_last_updated_by => fnd_global.user_id,
6533: p_last_update_date => l_sysdate,

Line 6530: p_created_by => fnd_api.g_miss_num,

6526: p_attribute12 => fnd_api.g_miss_char,
6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,
6530: p_created_by => fnd_api.g_miss_num,
6531: p_creation_date => fnd_api.g_miss_date,
6532: p_last_updated_by => fnd_global.user_id,
6533: p_last_update_date => l_sysdate,
6534: p_last_update_login => fnd_global.conc_login_id,

Line 6531: p_creation_date => fnd_api.g_miss_date,

6527: p_attribute13 => fnd_api.g_miss_char,
6528: p_attribute14 => fnd_api.g_miss_char,
6529: p_attribute15 => fnd_api.g_miss_char,
6530: p_created_by => fnd_api.g_miss_num,
6531: p_creation_date => fnd_api.g_miss_date,
6532: p_last_updated_by => fnd_global.user_id,
6533: p_last_update_date => l_sysdate,
6534: p_last_update_login => fnd_global.conc_login_id,
6535: p_object_version_number => fnd_api.g_miss_num);

Line 6535: p_object_version_number => fnd_api.g_miss_num);

6531: p_creation_date => fnd_api.g_miss_date,
6532: p_last_updated_by => fnd_global.user_id,
6533: p_last_update_date => l_sysdate,
6534: p_last_update_login => fnd_global.conc_login_id,
6535: p_object_version_number => fnd_api.g_miss_num);
6536:
6537:
6538: csi_transactions_pvt.create_transaction
6539: (

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

6547: ,x_msg_count => x_msg_count
6548: ,x_msg_data => x_msg_data
6549: );
6550:
6551: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6552: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
6553: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
6554: fnd_msg_pub.add;
6555: RAISE fnd_api.g_exc_error;

Line 6555: RAISE fnd_api.g_exc_error;

6551: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6552: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_TXN');
6553: fnd_message.set_token('transaction_id',p_txn_rec.transaction_id );
6554: fnd_msg_pub.add;
6555: RAISE fnd_api.g_exc_error;
6556: ROLLBACK TO create_relationship_pvt;
6557: END IF;
6558:
6559: l_instance_rec:=l_temp_ins_rec;

Line 6563: IF NVL(l_serial_number, FND_API.G_MISS_CHAR) <> FND_API.G_MISS_CHAR

6559: l_instance_rec:=l_temp_ins_rec;
6560: l_instance_rec.instance_id:= l_relship_csr.subject_id;
6561: --validation for serialized item instance
6562: ---Base Bug 14349178
6563: IF NVL(l_serial_number, FND_API.G_MISS_CHAR) <> FND_API.G_MISS_CHAR
6564: THEN
6565: -- Base Bug 9748923/FP Bug 10091407
6566: l_instance_rec.instance_usage_code :=l_ins_usage_code; --Uncommented for bug#13729720
6567: END IF;

Line 6598: ,p_called_from_rel => fnd_api.g_true

6594: ,p_location_tbl => l_location_tbl
6595: ,p_generic_id_tbl => l_generic_id_tbl
6596: ,p_lookup_tbl => l_lookup_tbl
6597: ,p_ins_count_rec => l_ins_count_rec
6598: ,p_called_from_rel => fnd_api.g_true
6599: ,p_oks_txn_inst_tbl => px_oks_txn_inst_tbl
6600: ,p_child_inst_tbl => px_child_inst_tbl
6601: );
6602:

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

6600: ,p_child_inst_tbl => px_child_inst_tbl
6601: );
6602:
6603:
6604: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6605: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6606: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6607: fnd_msg_pub.add;
6608: RAISE fnd_api.g_exc_error;

Line 6608: RAISE fnd_api.g_exc_error;

6604: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
6605: fnd_message.set_name('CSI','CSI_FAILED_TO_VALIDATE_INS');
6606: fnd_message.set_token('instance_id',l_instance_rec.instance_id);
6607: fnd_msg_pub.add;
6608: RAISE fnd_api.g_exc_error;
6609: END IF;
6610: END IF;
6611:
6612: -- End Addition by sk for bug 2151750

Line 6653: IF x_return_status <> fnd_api.g_ret_sts_success THEN

6649: );
6650:
6651:
6652:
6653: IF x_return_status <> fnd_api.g_ret_sts_success THEN
6654: RAISE fnd_api.g_exc_error;
6655: END IF;
6656:
6657: -- standard check for p_commit

Line 6654: RAISE fnd_api.g_exc_error;

6650:
6651:
6652:
6653: IF x_return_status <> fnd_api.g_ret_sts_success THEN
6654: RAISE fnd_api.g_exc_error;
6655: END IF;
6656:
6657: -- standard check for p_commit
6658: IF fnd_api.to_boolean( p_commit )

Line 6658: IF fnd_api.to_boolean( p_commit )

6654: RAISE fnd_api.g_exc_error;
6655: END IF;
6656:
6657: -- standard check for p_commit
6658: IF fnd_api.to_boolean( p_commit )
6659: THEN
6660: COMMIT WORK;
6661: END IF;
6662:

Line 6665: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6661: END IF;
6662:
6663: -- standard call to get message count and if count is 1, get message info.
6664: fnd_msg_pub.count_AND_get
6665: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6666: p_count => x_msg_count,
6667: p_data => x_msg_data
6668: );
6669:

Line 6671: WHEN fnd_api.g_exc_error THEN

6667: p_data => x_msg_data
6668: );
6669:
6670: EXCEPTION
6671: WHEN fnd_api.g_exc_error THEN
6672: ROLLBACK TO expire_relationship_pvt;
6673: x_return_status := fnd_api.g_ret_sts_error ;
6674: fnd_msg_pub.count_AND_get
6675: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 6673: x_return_status := fnd_api.g_ret_sts_error ;

6669:
6670: EXCEPTION
6671: WHEN fnd_api.g_exc_error THEN
6672: ROLLBACK TO expire_relationship_pvt;
6673: x_return_status := fnd_api.g_ret_sts_error ;
6674: fnd_msg_pub.count_AND_get
6675: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6676: p_count => x_msg_count ,
6677: p_data => x_msg_data

Line 6675: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6671: WHEN fnd_api.g_exc_error THEN
6672: ROLLBACK TO expire_relationship_pvt;
6673: x_return_status := fnd_api.g_ret_sts_error ;
6674: fnd_msg_pub.count_AND_get
6675: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6676: p_count => x_msg_count ,
6677: p_data => x_msg_data
6678: );
6679:

Line 6680: WHEN fnd_api.g_exc_unexpected_error THEN

6676: p_count => x_msg_count ,
6677: p_data => x_msg_data
6678: );
6679:
6680: WHEN fnd_api.g_exc_unexpected_error THEN
6681: ROLLBACK TO expire_relationship_pvt;
6682: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6683: fnd_msg_pub.count_AND_get
6684: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 6682: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6678: );
6679:
6680: WHEN fnd_api.g_exc_unexpected_error THEN
6681: ROLLBACK TO expire_relationship_pvt;
6682: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6683: fnd_msg_pub.count_AND_get
6684: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6685: p_count => x_msg_count ,
6686: p_data => x_msg_data

Line 6684: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6680: WHEN fnd_api.g_exc_unexpected_error THEN
6681: ROLLBACK TO expire_relationship_pvt;
6682: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6683: fnd_msg_pub.count_AND_get
6684: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6685: p_count => x_msg_count ,
6686: p_data => x_msg_data
6687: );
6688:

Line 6691: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6687: );
6688:
6689: WHEN OTHERS THEN
6690: ROLLBACK TO expire_relationship_pvt;
6691: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6692: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6693: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
6694: END IF;
6695: fnd_msg_pub.count_AND_get

Line 6696: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6692: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6693: fnd_msg_pub.add_exc_msg(g_pkg_name ,l_api_name);
6694: END IF;
6695: fnd_msg_pub.count_AND_get
6696: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6697: p_count => x_msg_count ,
6698: p_data => x_msg_data
6699: );
6700: END expire_relationship;

Line 6716: IF fnd_api.to_boolean( p_init_msg_list )

6712: l_dummy VARCHAR2(1);
6713: BEGIN
6714:
6715: -- initialize message list IF p_init_msg_list IS set TO true.
6716: IF fnd_api.to_boolean( p_init_msg_list )
6717: THEN
6718: fnd_msg_pub.initialize;
6719: END IF;
6720:

Line 6723: x_return_status := fnd_api.g_ret_sts_success;

6719: END IF;
6720:
6721:
6722: -- initialize api return status to success
6723: x_return_status := fnd_api.g_ret_sts_success;
6724: IF(p_validation_mode ='CREATE') THEN
6725: -- validate not null column
6726: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) )
6727: /* if p_relationship_id is not null check if it already exists if found return success else error*/

Line 6726: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) )

6722: -- initialize api return status to success
6723: x_return_status := fnd_api.g_ret_sts_success;
6724: IF(p_validation_mode ='CREATE') THEN
6725: -- validate not null column
6726: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) )
6727: /* if p_relationship_id is not null check if it already exists if found return success else error*/
6728: THEN
6729: BEGIN
6730: SELECT 'x'

Line 6738: x_return_status := fnd_api.g_ret_sts_error;

6734: AND ROWNUM=1;
6735: fnd_message.set_name('CSI','CSI_INVALID_RELSHIPID');
6736: fnd_message.set_token('relationship_id',p_relationship_id);
6737: fnd_msg_pub.add;
6738: x_return_status := fnd_api.g_ret_sts_error;
6739: EXCEPTION
6740: WHEN NO_DATA_FOUND THEN
6741: x_return_status := fnd_api.g_ret_sts_success;
6742:

Line 6741: x_return_status := fnd_api.g_ret_sts_success;

6737: fnd_msg_pub.add;
6738: x_return_status := fnd_api.g_ret_sts_error;
6739: EXCEPTION
6740: WHEN NO_DATA_FOUND THEN
6741: x_return_status := fnd_api.g_ret_sts_success;
6742:
6743: END;
6744:
6745: ELSE

Line 6747: x_return_status := fnd_api.g_ret_sts_success;

6743: END;
6744:
6745: ELSE
6746: /* if p_relationship_id is null then return success */
6747: x_return_status := fnd_api.g_ret_sts_success;
6748: END IF;
6749: ELSIF ( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
6750: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) ) THEN
6751: BEGIN

Line 6750: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) ) THEN

6746: /* if p_relationship_id is null then return success */
6747: x_return_status := fnd_api.g_ret_sts_success;
6748: END IF;
6749: ELSIF ( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
6750: IF ( (p_relationship_id IS NOT NULL) AND (p_relationship_id <> fnd_api.g_miss_num) ) THEN
6751: BEGIN
6752: /* Added the condition 'AND ACTIVE_END_DATE IS NULL' to avoid updating expired relationship */
6753: SELECT 'x'
6754: INTO l_dummy

Line 6761: x_return_status := fnd_api.g_ret_sts_success;

6757: -- AND ( ACTIVE_END_DATE IS NULL
6758: -- OR ACTIVE_END_DATE >SYSDATE)
6759: -- AND ROWNUM=1;
6760: -- IF SQL%FOUND THEN
6761: x_return_status := fnd_api.g_ret_sts_success;
6762: -- END IF;
6763: EXCEPTION
6764: WHEN NO_DATA_FOUND THEN
6765: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIPID');

Line 6767: x_return_status := fnd_api.g_ret_sts_error;

6763: EXCEPTION
6764: WHEN NO_DATA_FOUND THEN
6765: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIPID');
6766: fnd_msg_pub.add;
6767: x_return_status := fnd_api.g_ret_sts_error;
6768: END;
6769: ELSE
6770: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_ID_PASSED');
6771: fnd_msg_pub.add;

Line 6772: x_return_status := fnd_api.g_ret_sts_error;

6768: END;
6769: ELSE
6770: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_ID_PASSED');
6771: fnd_msg_pub.add;
6772: x_return_status := fnd_api.g_ret_sts_error;
6773: END IF;
6774: END IF;
6775:
6776:

Line 6780: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6776:
6777:
6778: -- standard call to get message count and if count is 1, get message info.
6779: fnd_msg_pub.count_AND_get
6780: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6781: p_count => x_msg_count,
6782: p_data => x_msg_data
6783: );
6784:

Line 6800: IF fnd_api.to_boolean( p_init_msg_list )

6796: IS
6797: l_dummy VARCHAR2(1);
6798: BEGIN
6799: -- initialize message list if p_init_msg_list is set to true.
6800: IF fnd_api.to_boolean( p_init_msg_list )
6801: THEN
6802: fnd_msg_pub.initialize;
6803: END IF;
6804:

Line 6806: x_return_status := fnd_api.g_ret_sts_success;

6802: fnd_msg_pub.initialize;
6803: END IF;
6804:
6805: -- initialize api return status to success
6806: x_return_status := fnd_api.g_ret_sts_success;
6807: IF(p_validation_mode ='CREATE')
6808: THEN
6809: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN
6810: BEGIN

Line 6809: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN

6805: -- initialize api return status to success
6806: x_return_status := fnd_api.g_ret_sts_success;
6807: IF(p_validation_mode ='CREATE')
6808: THEN
6809: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN
6810: BEGIN
6811: SELECT 'x'
6812: INTO l_dummy
6813: FROM csi_ii_relation_types

Line 6817: x_return_status := fnd_api.g_ret_sts_success;

6813: FROM csi_ii_relation_types
6814: WHERE relationship_type_code=p_relationship_type_code;
6815:
6816: IF SQL%FOUND THEN
6817: x_return_status := fnd_api.g_ret_sts_success;
6818: END IF;
6819:
6820: EXCEPTION
6821: WHEN NO_DATA_FOUND THEN

Line 6825: x_return_status := fnd_api.g_ret_sts_error;

6821: WHEN NO_DATA_FOUND THEN
6822: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIP_CODE');
6823: fnd_message.set_token('relationship_type_code',p_relationship_type_code);
6824: fnd_msg_pub.add;
6825: x_return_status := fnd_api.g_ret_sts_error;
6826: END;
6827: ELSE
6828: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');
6829: --fnd_message.set_token('relationship_type_code',p_relationship_type_code);

Line 6831: x_return_status := fnd_api.g_ret_sts_error;

6827: ELSE
6828: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');
6829: --fnd_message.set_token('relationship_type_code',p_relationship_type_code);
6830: fnd_msg_pub.add;
6831: x_return_status := fnd_api.g_ret_sts_error;
6832:
6833: END IF;
6834: ELSIF(p_validation_mode ='UPDATE')
6835: THEN

Line 6836: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN

6832:
6833: END IF;
6834: ELSIF(p_validation_mode ='UPDATE')
6835: THEN
6836: IF ((p_relationship_type_code IS NOT NULL) AND (p_relationship_type_code <> fnd_api.g_miss_char)) THEN
6837: BEGIN
6838: SELECT 'x'
6839: INTO l_dummy
6840: FROM csi_ii_relation_types

Line 6843: x_return_status := fnd_api.g_ret_sts_success;

6839: INTO l_dummy
6840: FROM csi_ii_relation_types
6841: WHERE relationship_type_code=p_relationship_type_code;
6842: IF SQL%FOUND THEN
6843: x_return_status := fnd_api.g_ret_sts_success;
6844: END IF;
6845: EXCEPTION
6846: WHEN NO_DATA_FOUND THEN
6847: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIP_CODE');

Line 6850: x_return_status := fnd_api.g_ret_sts_error;

6846: WHEN NO_DATA_FOUND THEN
6847: fnd_message.set_name('CSI', 'CSI_INVALID_RELSHIP_CODE');
6848: fnd_message.set_token('relationship_type_code',p_relationship_type_code);
6849: fnd_msg_pub.add;
6850: x_return_status := fnd_api.g_ret_sts_error;
6851: END;
6852: ELSIF p_relationship_type_code IS NULL -- Added for bug 2151750
6853: THEN
6854: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');

Line 6856: x_return_status := fnd_api.g_ret_sts_error;

6852: ELSIF p_relationship_type_code IS NULL -- Added for bug 2151750
6853: THEN
6854: fnd_message.set_name('CSI', 'CSI_NO_RELSHIP_CODE');
6855: fnd_msg_pub.add;
6856: x_return_status := fnd_api.g_ret_sts_error;
6857: END IF;
6858: END IF;
6859: -- standard call to get message count and if count is 1, get message info.
6860: fnd_msg_pub.count_AND_get

Line 6861: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

6857: END IF;
6858: END IF;
6859: -- standard call to get message count and if count is 1, get message info.
6860: fnd_msg_pub.count_AND_get
6861: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
6862: p_count => x_msg_count,
6863: p_data => x_msg_data
6864: );
6865:

Line 6894: IF fnd_api.to_boolean( p_init_msg_list )

6890: l_active VARCHAR2(1);
6891: BEGIN
6892:
6893: -- initialize message list if p_init_msg_list is set to true.
6894: IF fnd_api.to_boolean( p_init_msg_list )
6895: THEN
6896: fnd_msg_pub.initialize;
6897: END IF;
6898:

Line 6901: x_return_status := fnd_api.g_ret_sts_success;

6897: END IF;
6898:
6899:
6900: -- initialize api return status to success
6901: x_return_status := fnd_api.g_ret_sts_success;
6902:
6903: -- validate not null column
6904: IF(p_validation_mode ='CREATE')
6905: THEN

Line 6906: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN

6902:
6903: -- validate not null column
6904: IF(p_validation_mode ='CREATE')
6905: THEN
6906: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN
6907: -- The following code has been added by sguthiva for bug 2416144.
6908: BEGIN
6909: SELECT 'x'
6910: INTO l_active

Line 6919: x_return_status := fnd_api.g_ret_sts_error;

6915: WHEN NO_DATA_FOUND THEN
6916: fnd_message.set_name('CSI', 'CSI_EXPIRED_OBJECT');
6917: fnd_message.set_token('object_id',p_object_id);
6918: fnd_msg_pub.add;
6919: x_return_status := fnd_api.g_ret_sts_error;
6920: RAISE fnd_api.g_exc_error;
6921: END;
6922: -- End of addition for bug 2416144.
6923:

Line 6920: RAISE fnd_api.g_exc_error;

6916: fnd_message.set_name('CSI', 'CSI_EXPIRED_OBJECT');
6917: fnd_message.set_token('object_id',p_object_id);
6918: fnd_msg_pub.add;
6919: x_return_status := fnd_api.g_ret_sts_error;
6920: RAISE fnd_api.g_exc_error;
6921: END;
6922: -- End of addition for bug 2416144.
6923:
6924: BEGIN

Line 6943: x_return_status := fnd_api.g_ret_sts_error;

6939: IF l_quantity<>1 THEN
6940: fnd_message.set_name('CSI', 'CSI_QTY_NOTEQUAL_TO_ONE');
6941: fnd_message.set_token('object_id',p_object_id);
6942: fnd_msg_pub.add;
6943: x_return_status := fnd_api.g_ret_sts_error;
6944: END IF;
6945: END IF;
6946: /* commented by sk for bug 2151750
6947: IF l_location_type_code IS NOT NULL THEN

Line 6952: x_return_status := fnd_api.g_ret_sts_error;

6948: IF UPPER(l_location_type_code) = 'INVENTORY' THEN
6949: fnd_message.set_name('CSI', 'CSI_INVALID_LOCATION_TYPE');
6950: fnd_message.set_token('object_id',p_object_id);
6951: fnd_msg_pub.add;
6952: x_return_status := fnd_api.g_ret_sts_error;
6953: END IF;
6954: END IF;
6955: */
6956: BEGIN

Line 6998: x_return_status := fnd_api.g_ret_sts_error;

6994: ELSE
6995: fnd_message.set_name('CSI', 'CSI_NON_ATO_PTO_ITEM');
6996: fnd_message.set_token('object_id',p_object_id);
6997: fnd_msg_pub.add;
6998: x_return_status := fnd_api.g_ret_sts_error;
6999: END IF;
7000:
7001: EXCEPTION
7002: WHEN OTHERS THEN

Line 7010: x_return_status := fnd_api.g_ret_sts_error;

7006: WHEN NO_DATA_FOUND THEN
7007: fnd_message.set_name('CSI', 'CSI_INVALID_OBJECT_ID');
7008: fnd_message.set_token('object_id',p_object_id);
7009: fnd_msg_pub.add;
7010: x_return_status := fnd_api.g_ret_sts_error;
7011: END;
7012: ELSE
7013: fnd_message.set_name('CSI', 'CSI_NO_OBJ_ID_PASSED');
7014: fnd_msg_pub.add;

Line 7015: x_return_status := fnd_api.g_ret_sts_error;

7011: END;
7012: ELSE
7013: fnd_message.set_name('CSI', 'CSI_NO_OBJ_ID_PASSED');
7014: fnd_msg_pub.add;
7015: x_return_status := fnd_api.g_ret_sts_error;
7016: END IF;
7017:
7018: ELSIF(p_validation_mode ='UPDATE')
7019: THEN

Line 7020: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN

7016: END IF;
7017:
7018: ELSIF(p_validation_mode ='UPDATE')
7019: THEN
7020: IF ((p_object_id IS NOT NULL) AND (p_object_id <> fnd_api.g_miss_num)) THEN
7021: BEGIN
7022: -- Modified by sk for bug 2266166
7023: SELECT instance_id
7024: ,quantity

Line 7041: x_return_status := fnd_api.g_ret_sts_error;

7037: IF l_quantity<>1 THEN
7038: fnd_message.set_name('CSI', 'CSI_QTY_NOTEQUAL_TO_ONE');
7039: fnd_message.set_token('object_id',p_object_id);
7040: fnd_msg_pub.add;
7041: x_return_status := fnd_api.g_ret_sts_error;
7042: END IF;
7043: END IF;
7044: /* commented by sk for bug 2151750
7045: IF l_location_type_code IS NOT NULL THEN

Line 7050: x_return_status := fnd_api.g_ret_sts_error;

7046: IF UPPER(l_location_type_code) = 'INVENTORY' THEN
7047: fnd_message.set_name('CSI', 'CSI_INVALID_LOCATION_TYPE');
7048: fnd_message.set_token('object_id',p_object_id);
7049: fnd_msg_pub.add;
7050: x_return_status := fnd_api.g_ret_sts_error;
7051: END IF;
7052: END IF;
7053: */
7054: BEGIN

Line 7096: x_return_status := fnd_api.g_ret_sts_error;

7092: ELSE
7093: fnd_message.set_name('CSI', 'CSI_NON_ATO_PTO_ITEM');
7094: fnd_message.set_token('object_id',p_object_id);
7095: fnd_msg_pub.add;
7096: x_return_status := fnd_api.g_ret_sts_error;
7097: END IF;
7098:
7099: EXCEPTION
7100: WHEN OTHERS THEN

Line 7109: x_return_status := fnd_api.g_ret_sts_error;

7105: WHEN NO_DATA_FOUND THEN
7106: fnd_message.set_name('CSI', 'CSI_INVALID_OBJECT_ID');
7107: fnd_message.set_token('object_id',p_object_id);
7108: fnd_msg_pub.add;
7109: x_return_status := fnd_api.g_ret_sts_error;
7110: END;
7111: END IF;
7112: END IF;
7113:

Line 7116: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7112: END IF;
7113:
7114: -- standard call to get message count and if count is 1, get message info.
7115: fnd_msg_pub.count_and_get
7116: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7117: p_count => x_msg_count,
7118: p_data => x_msg_data
7119: );
7120:

Line 7141: IF fnd_api.to_boolean( p_init_msg_list )

7137: l_active VARCHAR2(1);
7138: BEGIN
7139:
7140: -- initialize message list if p_init_msg_list is set to true.
7141: IF fnd_api.to_boolean( p_init_msg_list )
7142: THEN
7143: fnd_msg_pub.initialize;
7144: END IF;
7145:

Line 7148: x_return_status := fnd_api.g_ret_sts_success;

7144: END IF;
7145:
7146:
7147: -- initialize API RETURN status TO success
7148: x_return_status := fnd_api.g_ret_sts_success;
7149:
7150: IF ((p_subject_id IS NOT NULL) AND (p_subject_id <> fnd_api.g_miss_num)) THEN
7151: -- The following code has been added by sguthiva for bug 2416144.
7152: IF (p_validation_mode ='CREATE')

Line 7150: IF ((p_subject_id IS NOT NULL) AND (p_subject_id <> fnd_api.g_miss_num)) THEN

7146:
7147: -- initialize API RETURN status TO success
7148: x_return_status := fnd_api.g_ret_sts_success;
7149:
7150: IF ((p_subject_id IS NOT NULL) AND (p_subject_id <> fnd_api.g_miss_num)) THEN
7151: -- The following code has been added by sguthiva for bug 2416144.
7152: IF (p_validation_mode ='CREATE')
7153: THEN
7154: BEGIN

Line 7165: x_return_status := fnd_api.g_ret_sts_error;

7161: WHEN NO_DATA_FOUND THEN
7162: fnd_message.set_name('CSI', 'CSI_EXPIRED_SUBJECT');
7163: fnd_message.set_token('subject_id',p_subject_id);
7164: fnd_msg_pub.add;
7165: x_return_status := fnd_api.g_ret_sts_error;
7166: RAISE fnd_api.g_exc_error;
7167: END;
7168: END IF;
7169: -- End of addition for bug 2416144.

Line 7166: RAISE fnd_api.g_exc_error;

7162: fnd_message.set_name('CSI', 'CSI_EXPIRED_SUBJECT');
7163: fnd_message.set_token('subject_id',p_subject_id);
7164: fnd_msg_pub.add;
7165: x_return_status := fnd_api.g_ret_sts_error;
7166: RAISE fnd_api.g_exc_error;
7167: END;
7168: END IF;
7169: -- End of addition for bug 2416144.
7170: BEGIN

Line 7181: x_return_status := fnd_api.g_ret_sts_error;

7177: IF UPPER(l_location_type_code) = 'INVENTORY' THEN
7178: fnd_message.set_name('CSI', 'CSI_INVALID_LOCATION_TYPE');
7179: fnd_message.set_token('subject_id',p_subject_id);
7180: fnd_msg_pub.add;
7181: x_return_status := fnd_api.g_ret_sts_error;
7182: END IF;
7183: END IF;
7184: */
7185: EXCEPTION

Line 7190: x_return_status := fnd_api.g_ret_sts_error;

7186: WHEN NO_DATA_FOUND THEN
7187: fnd_message.set_name('CSI', 'CSI_INVALID_SUBJECT_ID');
7188: fnd_message.set_token('subject_id',p_subject_id);
7189: fnd_msg_pub.add;
7190: x_return_status := fnd_api.g_ret_sts_error;
7191: END;
7192: END IF;
7193: -- standard call to get message count and if count is 1, get message info.
7194: fnd_msg_pub.count_AND_get

Line 7195: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7191: END;
7192: END IF;
7193: -- standard call to get message count and if count is 1, get message info.
7194: fnd_msg_pub.count_AND_get
7195: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7196: p_count => x_msg_count,
7197: p_data => x_msg_data
7198: );
7199:

Line 7213: IF fnd_api.to_boolean( p_init_msg_list )

7209: )
7210: IS
7211: BEGIN
7212: -- initialize message list if p_init_msg_list is set to true.
7213: IF fnd_api.to_boolean( p_init_msg_list )
7214: THEN
7215: fnd_msg_pub.initialize;
7216: END IF;
7217:

Line 7220: x_return_status := fnd_api.g_ret_sts_success;

7216: END IF;
7217:
7218:
7219: -- initialize api return status to success
7220: x_return_status := fnd_api.g_ret_sts_success;
7221: IF(p_validation_mode ='CREATE') THEN
7222: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN
7223: fnd_message.set_name('CSI', 'CSI_ACTIVE_END_DATE');
7224: fnd_message.set_token('ACTIVE_END_DATE',p_active_end_date);

Line 7222: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN

7218:
7219: -- initialize api return status to success
7220: x_return_status := fnd_api.g_ret_sts_success;
7221: IF(p_validation_mode ='CREATE') THEN
7222: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN
7223: fnd_message.set_name('CSI', 'CSI_ACTIVE_END_DATE');
7224: fnd_message.set_token('ACTIVE_END_DATE',p_active_end_date);
7225: fnd_msg_pub.add;
7226: x_return_status := fnd_api.g_ret_sts_error;

Line 7226: x_return_status := fnd_api.g_ret_sts_error;

7222: IF ((p_active_end_date IS NOT NULL) AND (p_active_end_date <> fnd_api.g_miss_date)) THEN
7223: fnd_message.set_name('CSI', 'CSI_ACTIVE_END_DATE');
7224: fnd_message.set_token('ACTIVE_END_DATE',p_active_end_date);
7225: fnd_msg_pub.add;
7226: x_return_status := fnd_api.g_ret_sts_error;
7227: END IF;
7228: END IF;
7229: -- standard call to get message count and if count is 1, get message info.
7230: fnd_msg_pub.count_AND_get

Line 7231: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7227: END IF;
7228: END IF;
7229: -- standard call to get message count and if count is 1, get message info.
7230: fnd_msg_pub.count_AND_get
7231: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7232: p_count => x_msg_count,
7233: p_data => x_msg_data
7234: );
7235:

Line 7252: IF fnd_api.to_boolean( p_init_msg_list )

7248: l_dummy VARCHAR2(1);
7249: BEGIN
7250:
7251: -- initialize message list if p_init_msg_list is set to true.
7252: IF fnd_api.to_boolean( p_init_msg_list )
7253: THEN
7254: fnd_msg_pub.initialize;
7255: END IF;
7256:

Line 7259: x_return_status := fnd_api.g_ret_sts_success;

7255: END IF;
7256:
7257:
7258: -- initialize api return status to success
7259: x_return_status := fnd_api.g_ret_sts_success;
7260:
7261: -- validate not null column
7262:
7263:

Line 7265: IF ( (p_object_version_number IS NULL) OR (p_object_version_number = fnd_api.g_miss_num) ) THEN

7261: -- validate not null column
7262:
7263:
7264: IF( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
7265: IF ( (p_object_version_number IS NULL) OR (p_object_version_number = fnd_api.g_miss_num) ) THEN
7266: fnd_message.set_name('CSI', 'CSI_MISSING_OBJ_VER_NUM');
7267: fnd_msg_pub.add;
7268: x_return_status := fnd_api.g_ret_sts_error;
7269: ELSE

Line 7268: x_return_status := fnd_api.g_ret_sts_error;

7264: IF( (p_validation_mode = 'UPDATE') OR (p_validation_mode = 'EXPIRE') ) THEN
7265: IF ( (p_object_version_number IS NULL) OR (p_object_version_number = fnd_api.g_miss_num) ) THEN
7266: fnd_message.set_name('CSI', 'CSI_MISSING_OBJ_VER_NUM');
7267: fnd_msg_pub.add;
7268: x_return_status := fnd_api.g_ret_sts_error;
7269: ELSE
7270: x_return_status := fnd_api.g_ret_sts_success;
7271: END IF;
7272: END IF;

Line 7270: x_return_status := fnd_api.g_ret_sts_success;

7266: fnd_message.set_name('CSI', 'CSI_MISSING_OBJ_VER_NUM');
7267: fnd_msg_pub.add;
7268: x_return_status := fnd_api.g_ret_sts_error;
7269: ELSE
7270: x_return_status := fnd_api.g_ret_sts_success;
7271: END IF;
7272: END IF;
7273:
7274: -- standard call to get message count and if count is 1, get message info.

Line 7276: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7272: END IF;
7273:
7274: -- standard call to get message count and if count is 1, get message info.
7275: fnd_msg_pub.count_and_get
7276: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7277: p_count => x_msg_count,
7278: p_data => x_msg_data
7279: );
7280:

Line 7300: x_return_status := fnd_api.g_ret_sts_success;

7296:
7297:
7298:
7299: -- initialize api return status to success
7300: x_return_status := fnd_api.g_ret_sts_success;
7301:
7302: l_ct := p_ii_relationship_tbl.count;
7303: FOR l_count IN 1..l_ct LOOP
7304:

Line 7306: -- IF (p_validation_level >= fnd_api.g_valid_level_full) THEN

7302: l_ct := p_ii_relationship_tbl.count;
7303: FOR l_count IN 1..l_ct LOOP
7304:
7305: -- The following IF statement has been commented out for Bug: 3271806
7306: -- IF (p_validation_level >= fnd_api.g_valid_level_full) THEN
7307:
7308: validate_relationship_id(
7309: p_init_msg_list => fnd_api.g_false,
7310: p_validation_mode => p_validation_mode,

Line 7309: p_init_msg_list => fnd_api.g_false,

7305: -- The following IF statement has been commented out for Bug: 3271806
7306: -- IF (p_validation_level >= fnd_api.g_valid_level_full) THEN
7307:
7308: validate_relationship_id(
7309: p_init_msg_list => fnd_api.g_false,
7310: p_validation_mode => p_validation_mode,
7311: p_relationship_id => p_ii_relationship_tbl(l_count).relationship_id,
7312: x_return_status => x_return_status,
7313: x_msg_count => x_msg_count,

Line 7315: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7311: p_relationship_id => p_ii_relationship_tbl(l_count).relationship_id,
7312: x_return_status => x_return_status,
7313: x_msg_count => x_msg_count,
7314: x_msg_data => x_msg_data);
7315: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7316: RAISE fnd_api.g_exc_error;
7317: END IF;
7318:
7319: validate_rel_type_code(

Line 7316: RAISE fnd_api.g_exc_error;

7312: x_return_status => x_return_status,
7313: x_msg_count => x_msg_count,
7314: x_msg_data => x_msg_data);
7315: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7316: RAISE fnd_api.g_exc_error;
7317: END IF;
7318:
7319: validate_rel_type_code(
7320: p_init_msg_list => fnd_api.g_false,

Line 7320: p_init_msg_list => fnd_api.g_false,

7316: RAISE fnd_api.g_exc_error;
7317: END IF;
7318:
7319: validate_rel_type_code(
7320: p_init_msg_list => fnd_api.g_false,
7321: p_validation_mode => p_validation_mode,
7322: p_relationship_type_code => p_ii_relationship_tbl(l_count).relationship_type_code,
7323: x_return_status => x_return_status,
7324: x_msg_count => x_msg_count,

Line 7326: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7322: p_relationship_type_code => p_ii_relationship_tbl(l_count).relationship_type_code,
7323: x_return_status => x_return_status,
7324: x_msg_count => x_msg_count,
7325: x_msg_data => x_msg_data);
7326: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7327: RAISE fnd_api.g_exc_error;
7328: END IF;
7329:
7330: validate_object_id(

Line 7327: RAISE fnd_api.g_exc_error;

7323: x_return_status => x_return_status,
7324: x_msg_count => x_msg_count,
7325: x_msg_data => x_msg_data);
7326: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7327: RAISE fnd_api.g_exc_error;
7328: END IF;
7329:
7330: validate_object_id(
7331: p_init_msg_list => fnd_api.g_false,

Line 7331: p_init_msg_list => fnd_api.g_false,

7327: RAISE fnd_api.g_exc_error;
7328: END IF;
7329:
7330: validate_object_id(
7331: p_init_msg_list => fnd_api.g_false,
7332: p_validation_mode => p_validation_mode,
7333: p_object_id => p_ii_relationship_tbl(l_count).object_id,
7334: x_return_status => x_return_status,
7335: x_msg_count => x_msg_count,

Line 7337: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7333: p_object_id => p_ii_relationship_tbl(l_count).object_id,
7334: x_return_status => x_return_status,
7335: x_msg_count => x_msg_count,
7336: x_msg_data => x_msg_data);
7337: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7338: RAISE fnd_api.g_exc_error;
7339: END IF;
7340:
7341: validate_subject_id(

Line 7338: RAISE fnd_api.g_exc_error;

7334: x_return_status => x_return_status,
7335: x_msg_count => x_msg_count,
7336: x_msg_data => x_msg_data);
7337: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7338: RAISE fnd_api.g_exc_error;
7339: END IF;
7340:
7341: validate_subject_id(
7342: p_init_msg_list => fnd_api.g_false,

Line 7342: p_init_msg_list => fnd_api.g_false,

7338: RAISE fnd_api.g_exc_error;
7339: END IF;
7340:
7341: validate_subject_id(
7342: p_init_msg_list => fnd_api.g_false,
7343: p_validation_mode => p_validation_mode,
7344: p_subject_id => p_ii_relationship_tbl(l_count).subject_id,
7345: x_return_status => x_return_status,
7346: x_msg_count => x_msg_count,

Line 7348: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7344: p_subject_id => p_ii_relationship_tbl(l_count).subject_id,
7345: x_return_status => x_return_status,
7346: x_msg_count => x_msg_count,
7347: x_msg_data => x_msg_data);
7348: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7349: RAISE fnd_api.g_exc_error;
7350: END IF;
7351:
7352: validate_active_end_date(

Line 7349: RAISE fnd_api.g_exc_error;

7345: x_return_status => x_return_status,
7346: x_msg_count => x_msg_count,
7347: x_msg_data => x_msg_data);
7348: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7349: RAISE fnd_api.g_exc_error;
7350: END IF;
7351:
7352: validate_active_end_date(
7353: p_init_msg_list => fnd_api.g_false,

Line 7353: p_init_msg_list => fnd_api.g_false,

7349: RAISE fnd_api.g_exc_error;
7350: END IF;
7351:
7352: validate_active_end_date(
7353: p_init_msg_list => fnd_api.g_false,
7354: p_validation_mode => p_validation_mode,
7355: p_active_end_date => p_ii_relationship_tbl(l_count).active_end_date,
7356: x_return_status => x_return_status,
7357: x_msg_count => x_msg_count,

Line 7359: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7355: p_active_end_date => p_ii_relationship_tbl(l_count).active_end_date,
7356: x_return_status => x_return_status,
7357: x_msg_count => x_msg_count,
7358: x_msg_data => x_msg_data);
7359: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7360: RAISE fnd_api.g_exc_error;
7361: END IF;
7362:
7363: validate_object_version_num (

Line 7360: RAISE fnd_api.g_exc_error;

7356: x_return_status => x_return_status,
7357: x_msg_count => x_msg_count,
7358: x_msg_data => x_msg_data);
7359: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7360: RAISE fnd_api.g_exc_error;
7361: END IF;
7362:
7363: validate_object_version_num (
7364: p_init_msg_list => fnd_api.g_false,

Line 7364: p_init_msg_list => fnd_api.g_false,

7360: RAISE fnd_api.g_exc_error;
7361: END IF;
7362:
7363: validate_object_version_num (
7364: p_init_msg_list => fnd_api.g_false,
7365: p_validation_mode => p_validation_mode,
7366: p_object_version_number => p_ii_relationship_tbl(l_count).object_version_number,
7367: x_return_status => x_return_status,
7368: x_msg_count => x_msg_count,

Line 7371: IF x_return_status <> fnd_api.g_ret_sts_success THEN

7367: x_return_status => x_return_status,
7368: x_msg_count => x_msg_count,
7369: x_msg_data => x_msg_data);
7370:
7371: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7372: RAISE fnd_api.g_exc_error;
7373: END IF;
7374:
7375: -- END IF;

Line 7372: RAISE fnd_api.g_exc_error;

7368: x_msg_count => x_msg_count,
7369: x_msg_data => x_msg_data);
7370:
7371: IF x_return_status <> fnd_api.g_ret_sts_success THEN
7372: RAISE fnd_api.g_exc_error;
7373: END IF;
7374:
7375: -- END IF;
7376: END LOOP;

Line 7397: (p_rel_history_tbl(tab_row).relationship_type_code <> FND_API.G_MISS_CHAR) ) THEN

7393: FOR tab_row in p_rel_history_tbl.FIRST..p_rel_history_tbl.LAST
7394: LOOP
7395: IF p_rel_history_tbl.EXISTS(tab_row) THEN
7396: IF ( (p_rel_history_tbl(tab_row).relationship_type_code IS NOT NULL) AND
7397: (p_rel_history_tbl(tab_row).relationship_type_code <> FND_API.G_MISS_CHAR) ) THEN
7398: BEGIN
7399: SELECT name
7400: INTO p_rel_history_tbl(tab_row).relationship_type
7401: FROM csi_ii_relation_types

Line 7410: (p_rel_history_tbl(tab_row).OLD_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN

7406: END;
7407: END IF;
7408:
7409: IF ( (p_rel_history_tbl(tab_row).OLD_SUBJECT_ID IS NOT NULL) AND
7410: (p_rel_history_tbl(tab_row).OLD_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN
7411: BEGIN
7412: SELECT instance_number
7413: INTO p_rel_history_tbl(tab_row).old_subject_number
7414: FROM csi_item_instances

Line 7423: (p_rel_history_tbl(tab_row).NEW_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN

7419: END;
7420: END IF;
7421:
7422: IF ( (p_rel_history_tbl(tab_row).NEW_SUBJECT_ID IS NOT NULL) AND
7423: (p_rel_history_tbl(tab_row).NEW_SUBJECT_ID <> FND_API.G_MISS_NUM) ) THEN
7424: BEGIN
7425: SELECT instance_number
7426: INTO p_rel_history_tbl(tab_row).new_subject_number
7427: FROM csi_item_instances

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

7444: /*------------------------------------------------------------*/
7445:
7446: PROCEDURE get_inst_relationship_hist
7447: ( p_api_version IN NUMBER
7448: ,p_commit IN VARCHAR2 := fnd_api.g_false
7449: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
7450: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
7451: ,p_transaction_id IN NUMBER
7452: ,x_rel_history_tbl OUT NOCOPY csi_datastructures_pub.relationship_history_tbl

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

7445:
7446: PROCEDURE get_inst_relationship_hist
7447: ( p_api_version IN NUMBER
7448: ,p_commit IN VARCHAR2 := fnd_api.g_false
7449: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
7450: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
7451: ,p_transaction_id IN NUMBER
7452: ,x_rel_history_tbl OUT NOCOPY csi_datastructures_pub.relationship_history_tbl
7453: ,x_return_status OUT NOCOPY VARCHAR2

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

7446: PROCEDURE get_inst_relationship_hist
7447: ( p_api_version IN NUMBER
7448: ,p_commit IN VARCHAR2 := fnd_api.g_false
7449: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
7450: ,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
7451: ,p_transaction_id IN NUMBER
7452: ,x_rel_history_tbl OUT NOCOPY csi_datastructures_pub.relationship_history_tbl
7453: ,x_return_status OUT NOCOPY VARCHAR2
7454: ,x_msg_count OUT NOCOPY NUMBER

Line 7530: IF NOT FND_API.Compatible_API_Call ( l_api_version ,

7526: -- Standard Start of API savepoint
7527: --SAVEPOINT get_inst_relationship_hist;
7528:
7529: -- Standard call to check for call compatibility.
7530: IF NOT FND_API.Compatible_API_Call ( l_api_version ,
7531: p_api_version ,
7532: l_api_name ,
7533: g_pkg_name )
7534: THEN

Line 7535: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

7531: p_api_version ,
7532: l_api_name ,
7533: g_pkg_name )
7534: THEN
7535: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
7536: END IF;
7537:
7538: -- Initialize message list if p_init_msg_list is set to TRUE.
7539: IF FND_API.to_Boolean( p_init_msg_list ) THEN

Line 7539: IF FND_API.to_Boolean( p_init_msg_list ) THEN

7535: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
7536: END IF;
7537:
7538: -- Initialize message list if p_init_msg_list is set to TRUE.
7539: IF FND_API.to_Boolean( p_init_msg_list ) THEN
7540: FND_MSG_PUB.initialize;
7541: END IF;
7542:
7543: -- Initialize API return status to success

Line 7544: x_return_status := FND_API.G_RET_STS_SUCCESS;

7540: FND_MSG_PUB.initialize;
7541: END IF;
7542:
7543: -- Initialize API return status to success
7544: x_return_status := FND_API.G_RET_STS_SUCCESS;
7545:
7546: -- Check the profile option CSI_DEBUG_LEVEL for debug message reporting
7547: l_csi_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');
7548:

Line 7629: OR (x_rel_history_tbl(i).new_subject_id = FND_API.G_MISS_NUM)

7625:
7626:
7627: IF (
7628: (x_rel_history_tbl(i).new_subject_id IS NULL)
7629: OR (x_rel_history_tbl(i).new_subject_id = FND_API.G_MISS_NUM)
7630: )
7631: THEN
7632:
7633: l_relationship_query_rec.relationship_id := x_rel_history_tbl(i).relationship_id;

Line 7639: p_commit => fnd_api.g_false,

7635:
7636: get_relationships
7637: (
7638: p_api_version => 1.0,
7639: p_commit => fnd_api.g_false,
7640: p_init_msg_list => fnd_api.g_false,
7641: p_validation_level => fnd_api.g_valid_level_full,
7642: p_relationship_query_rec => l_relationship_query_rec,
7643: p_depth => NULL,

Line 7640: p_init_msg_list => fnd_api.g_false,

7636: get_relationships
7637: (
7638: p_api_version => 1.0,
7639: p_commit => fnd_api.g_false,
7640: p_init_msg_list => fnd_api.g_false,
7641: p_validation_level => fnd_api.g_valid_level_full,
7642: p_relationship_query_rec => l_relationship_query_rec,
7643: p_depth => NULL,
7644: p_time_stamp => l_time_stamp,

Line 7641: p_validation_level => fnd_api.g_valid_level_full,

7637: (
7638: p_api_version => 1.0,
7639: p_commit => fnd_api.g_false,
7640: p_init_msg_list => fnd_api.g_false,
7641: p_validation_level => fnd_api.g_valid_level_full,
7642: p_relationship_query_rec => l_relationship_query_rec,
7643: p_depth => NULL,
7644: p_time_stamp => l_time_stamp,
7645: p_active_relationship_only => fnd_api.g_false,

Line 7645: p_active_relationship_only => fnd_api.g_false,

7641: p_validation_level => fnd_api.g_valid_level_full,
7642: p_relationship_query_rec => l_relationship_query_rec,
7643: p_depth => NULL,
7644: p_time_stamp => l_time_stamp,
7645: p_active_relationship_only => fnd_api.g_false,
7646: x_relationship_tbl => l_ii_relationship_tbl,
7647: x_return_status => x_return_status,
7648: x_msg_count => x_msg_count,
7649: x_msg_data => x_msg_data

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

7648: x_msg_count => x_msg_count,
7649: x_msg_data => x_msg_data
7650: );
7651:
7652: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
7653: RAISE fnd_api.g_exc_error;
7654: END IF;
7655: --
7656: IF l_ii_relationship_tbl.count > 0 THEN

Line 7653: RAISE fnd_api.g_exc_error;

7649: x_msg_data => x_msg_data
7650: );
7651:
7652: IF NOT(x_return_status = fnd_api.g_ret_sts_success) THEN
7653: RAISE fnd_api.g_exc_error;
7654: END IF;
7655: --
7656: IF l_ii_relationship_tbl.count > 0 THEN
7657: x_rel_history_tbl(i).new_subject_id := l_ii_relationship_tbl(1).subject_id;

Line 7675: IF FND_API.To_Boolean( p_commit ) THEN

7671: -- End of API body
7672:
7673: -- Standard check of p_commit.
7674: /*
7675: IF FND_API.To_Boolean( p_commit ) THEN
7676: COMMIT WORK;
7677: END IF;
7678: */
7679:

Line 7690: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7686: ****/
7687:
7688: -- Standard call to get message count and if count is get message info.
7689: FND_MSG_PUB.Count_And_Get
7690: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7691: p_count => x_msg_count ,
7692: p_data => x_msg_data );
7693:
7694: EXCEPTION

Line 7696: WHEN FND_API.G_EXC_ERROR THEN

7692: p_data => x_msg_data );
7693:
7694: EXCEPTION
7695:
7696: WHEN FND_API.G_EXC_ERROR THEN
7697: -- ROLLBACK TO get_inst_relationship_hist;
7698: x_return_status := FND_API.G_RET_STS_ERROR ;
7699: FND_MSG_PUB.Count_And_Get
7700: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 7698: x_return_status := FND_API.G_RET_STS_ERROR ;

7694: EXCEPTION
7695:
7696: WHEN FND_API.G_EXC_ERROR THEN
7697: -- ROLLBACK TO get_inst_relationship_hist;
7698: x_return_status := FND_API.G_RET_STS_ERROR ;
7699: FND_MSG_PUB.Count_And_Get
7700: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7701: p_count => x_msg_count,
7702: p_data => x_msg_data );

Line 7700: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7696: WHEN FND_API.G_EXC_ERROR THEN
7697: -- ROLLBACK TO get_inst_relationship_hist;
7698: x_return_status := FND_API.G_RET_STS_ERROR ;
7699: FND_MSG_PUB.Count_And_Get
7700: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7701: p_count => x_msg_count,
7702: p_data => x_msg_data );
7703: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7704: -- ROLLBACK TO get_inst_relationship_hist;

Line 7703: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

7699: FND_MSG_PUB.Count_And_Get
7700: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7701: p_count => x_msg_count,
7702: p_data => x_msg_data );
7703: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7704: -- ROLLBACK TO get_inst_relationship_hist;
7705: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7706: FND_MSG_PUB.Count_And_Get
7707: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

Line 7705: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

7701: p_count => x_msg_count,
7702: p_data => x_msg_data );
7703: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7704: -- ROLLBACK TO get_inst_relationship_hist;
7705: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7706: FND_MSG_PUB.Count_And_Get
7707: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7708: p_count => x_msg_count,
7709: p_data => x_msg_data );

Line 7707: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7703: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7704: -- ROLLBACK TO get_inst_relationship_hist;
7705: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7706: FND_MSG_PUB.Count_And_Get
7707: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7708: p_count => x_msg_count,
7709: p_data => x_msg_data );
7710: WHEN OTHERS THEN
7711: -- ROLLBACK TO get_inst_relationship_hist;

Line 7712: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

7708: p_count => x_msg_count,
7709: p_data => x_msg_data );
7710: WHEN OTHERS THEN
7711: -- ROLLBACK TO get_inst_relationship_hist;
7712: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
7713: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
7714: FND_MSG_PUB.Add_Exc_Msg
7715: ( g_pkg_name ,
7716: l_api_name );

Line 7719: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7715: ( g_pkg_name ,
7716: l_api_name );
7717: END IF;
7718: FND_MSG_PUB.Count_And_Get
7719: ( p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7720: p_count => x_msg_count,
7721: p_data => x_msg_data );
7722:
7723: END get_inst_relationship_hist;

Line 7765: x_return_status := fnd_api.g_ret_sts_success;

7761: l_rel_color_ctr NUMBER := 0;
7762: --
7763: COMP_ERROR EXCEPTION;
7764: BEGIN
7765: x_return_status := fnd_api.g_ret_sts_success;
7766: p_cyclic_node := NULL;
7767: l_instance_id := p_instance_id;
7768: --
7769: l_debug_level:=fnd_profile.value('CSI_DEBUG_LEVEL');

Line 7776: p_commit => fnd_api.g_false,

7772: END IF;
7773: --
7774: csi_ii_relationships_pvt.get_cyclic_relationships(
7775: p_api_version => 1.0,
7776: p_commit => fnd_api.g_false,
7777: p_init_msg_list => fnd_api.g_true,
7778: p_validation_level => fnd_api.g_valid_level_full,
7779: p_instance_id => l_instance_id,
7780: p_depth => NULL ,

Line 7777: p_init_msg_list => fnd_api.g_true,

7773: --
7774: csi_ii_relationships_pvt.get_cyclic_relationships(
7775: p_api_version => 1.0,
7776: p_commit => fnd_api.g_false,
7777: p_init_msg_list => fnd_api.g_true,
7778: p_validation_level => fnd_api.g_valid_level_full,
7779: p_instance_id => l_instance_id,
7780: p_depth => NULL ,
7781: p_time_stamp => fnd_api.g_miss_date,

Line 7778: p_validation_level => fnd_api.g_valid_level_full,

7774: csi_ii_relationships_pvt.get_cyclic_relationships(
7775: p_api_version => 1.0,
7776: p_commit => fnd_api.g_false,
7777: p_init_msg_list => fnd_api.g_true,
7778: p_validation_level => fnd_api.g_valid_level_full,
7779: p_instance_id => l_instance_id,
7780: p_depth => NULL ,
7781: p_time_stamp => fnd_api.g_miss_date,
7782: p_active_relationship_only => fnd_api.g_true,

Line 7781: p_time_stamp => fnd_api.g_miss_date,

7777: p_init_msg_list => fnd_api.g_true,
7778: p_validation_level => fnd_api.g_valid_level_full,
7779: p_instance_id => l_instance_id,
7780: p_depth => NULL ,
7781: p_time_stamp => fnd_api.g_miss_date,
7782: p_active_relationship_only => fnd_api.g_true,
7783: x_relationship_tbl => p_rel_tbl,
7784: x_return_status => x_return_status,
7785: x_msg_count => x_msg_count,

Line 7782: p_active_relationship_only => fnd_api.g_true,

7778: p_validation_level => fnd_api.g_valid_level_full,
7779: p_instance_id => l_instance_id,
7780: p_depth => NULL ,
7781: p_time_stamp => fnd_api.g_miss_date,
7782: p_active_relationship_only => fnd_api.g_true,
7783: x_relationship_tbl => p_rel_tbl,
7784: x_return_status => x_return_status,
7785: x_msg_count => x_msg_count,
7786: x_msg_data => x_msg_data

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

7785: x_msg_count => x_msg_count,
7786: x_msg_data => x_msg_data
7787: );
7788: --
7789: IF NOT(x_return_status = FND_API.G_RET_STS_SUCCESS) THEN
7790: l_msg_index := 1;
7791: l_msg_count := x_msg_count;
7792: WHILE l_msg_count > 0 LOOP
7793: x_msg_data := FND_MSG_PUB.GET

Line 7795: FND_API.G_FALSE );

7791: l_msg_count := x_msg_count;
7792: WHILE l_msg_count > 0 LOOP
7793: x_msg_data := FND_MSG_PUB.GET
7794: ( l_msg_index,
7795: FND_API.G_FALSE );
7796: csi_gen_utility_pvt.put_line( ' Error from Get_cyclic_relationships.. ');
7797: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
7798: l_msg_index := l_msg_index + 1;
7799: l_msg_count := l_msg_count - 1;

Line 7801: RAISE FND_API.G_EXC_ERROR;

7797: csi_gen_utility_pvt.put_line('MESSAGE DATA = '||x_msg_data);
7798: l_msg_index := l_msg_index + 1;
7799: l_msg_count := l_msg_count - 1;
7800: END LOOP;
7801: RAISE FND_API.G_EXC_ERROR;
7802: END IF;
7803: --
7804: csi_gen_utility_pvt.put_line('p_rel_tbl count after get_cyclic_relationships is '
7805: ||to_char(p_rel_tbl.count));

Line 7877: IF nvl(p_stop_at_cyclic,fnd_api.g_true) = fnd_api.g_true THEN

7873: FOR color_rec in l_rel_color_tbl.FIRST .. l_rel_color_tbl.LAST LOOP
7874: IF l_rel_color_tbl(color_rec).node_id = l_temp_id AND -- adjacent node
7875: l_rel_color_tbl(color_rec).color_code = 'R' THEN
7876: p_cyclic_node := l_temp_id;
7877: IF nvl(p_stop_at_cyclic,fnd_api.g_true) = fnd_api.g_true THEN
7878: csi_gen_utility_pvt.put_line('Cycle exists at '||to_char(p_cyclic_node));
7879: Raise COMP_ERROR;
7880: END IF;
7881: END IF;

Line 7924: Raise FND_API.G_EXC_UNEXPECTED_ERROR;

7920: --
7921: csi_gen_utility_pvt.put_line('Adjacent Node is '||l_temp_id);
7922: IF l_temp_id = -9999 THEN
7923: csi_gen_utility_pvt.put_line('Unable to get the Adjacent Node.. Exiting...');
7924: Raise FND_API.G_EXC_UNEXPECTED_ERROR;
7925: END IF;
7926: END IF; -- l_found = 0 check
7927: END LOOP;
7928: END IF;

Line 7933: WHEN FND_API.G_EXC_ERROR THEN

7929: csi_gen_utility_pvt.put_line('End of Get_Cyclic_Node...');
7930: EXCEPTION
7931: WHEN COMP_ERROR THEN
7932: null;
7933: WHEN FND_API.G_EXC_ERROR THEN
7934: x_return_status := fnd_api.g_ret_sts_error ;
7935: fnd_msg_pub.count_AND_get
7936: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7937: p_count => x_msg_count ,

Line 7934: x_return_status := fnd_api.g_ret_sts_error ;

7930: EXCEPTION
7931: WHEN COMP_ERROR THEN
7932: null;
7933: WHEN FND_API.G_EXC_ERROR THEN
7934: x_return_status := fnd_api.g_ret_sts_error ;
7935: fnd_msg_pub.count_AND_get
7936: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7937: p_count => x_msg_count ,
7938: p_data => x_msg_data

Line 7936: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7932: null;
7933: WHEN FND_API.G_EXC_ERROR THEN
7934: x_return_status := fnd_api.g_ret_sts_error ;
7935: fnd_msg_pub.count_AND_get
7936: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7937: p_count => x_msg_count ,
7938: p_data => x_msg_data
7939: );
7940:

Line 7941: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

7937: p_count => x_msg_count ,
7938: p_data => x_msg_data
7939: );
7940:
7941: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7942: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7943: fnd_msg_pub.count_AND_get
7944: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7945: p_count => x_msg_count ,

Line 7942: x_return_status := fnd_api.g_ret_sts_unexp_error ;

7938: p_data => x_msg_data
7939: );
7940:
7941: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7942: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7943: fnd_msg_pub.count_AND_get
7944: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7945: p_count => x_msg_count ,
7946: p_data => x_msg_data

Line 7944: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7940:
7941: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
7942: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7943: fnd_msg_pub.count_AND_get
7944: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7945: p_count => x_msg_count ,
7946: p_data => x_msg_data
7947: );
7948:

Line 7950: x_return_status := fnd_api.g_ret_sts_unexp_error ;

7946: p_data => x_msg_data
7947: );
7948:
7949: WHEN OTHERS THEN
7950: x_return_status := fnd_api.g_ret_sts_unexp_error ;
7951: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
7952: fnd_msg_pub.add_exc_msg(g_pkg_name,l_api_name);
7953: END IF;
7954: fnd_msg_pub.count_AND_get

Line 7955: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206

7951: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
7952: fnd_msg_pub.add_exc_msg(g_pkg_name,l_api_name);
7953: END IF;
7954: fnd_msg_pub.count_AND_get
7955: (p_encoded => FND_API.G_FALSE, --Added for bug 10081206
7956: p_count => x_msg_count ,
7957: p_data => x_msg_data
7958: );
7959: END Get_Cyclic_Node;