45: OPEN cur_old_ref_values;
46: FETCH cur_old_ref_values INTO old_references;
47: IF ((cur_old_ref_values%NOTFOUND) AND (p_action NOT IN ('INSERT', 'VALIDATE_INSERT'))) THEN
48: CLOSE cur_old_ref_values;
49: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
50: igs_ge_msg_stack.add;
51: app_exception.raise_exception;
52: RETURN;
53: END IF;
93: new_references.rsv_usec_pri_id,
94: new_references.preference_code
95: )
96: ) THEN
97: fnd_message.set_name ('IGS', 'IGS_GE_RECORD_ALREADY_EXISTS');
98: igs_ge_msg_stack.add;
99: app_exception.raise_exception;
100: END IF;
101:
132: NULL;
133: ELSIF NOT igs_ps_rsv_usec_pri_pkg.get_pk_for_validation (
134: new_references.rsv_usec_pri_id
135: ) THEN
136: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
137: igs_ge_msg_stack.add;
138: app_exception.raise_exception;
139: ELSE
140: OPEN c_priority;
144: IF NOT igs_ps_ver_pkg.get_pk_for_validation(
145: new_references.preference_code,
146: new_references.preference_version ) THEN
147: CLOSE c_priority;
148: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
149: igs_ge_msg_stack.add;
150: app_exception.raise_exception;
151: ELSE
152: CLOSE c_priority;
154: ELSIF (priority_value1 = 'PROGRAM_STAGE') THEN
155: IF NOT igs_ps_stage_type_pkg.get_pk_for_validation(
156: new_references.preference_code ) THEN
157: CLOSE c_priority;
158: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
159: igs_ge_msg_stack.add;
160: app_exception.raise_exception;
161: ELSE
162: CLOSE c_priority;
165: IF NOT igs_en_unit_set_pkg.get_pk_for_validation(
166: new_references.preference_code,
167: new_references.preference_version ) THEN
168: CLOSE c_priority;
169: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
170: igs_ge_msg_stack.add;
171: app_exception.raise_exception;
172: ELSE
173: CLOSE c_priority;
175: ELSIF (priority_value1 = 'PERSON_GRP') THEN
176: IF NOT igs_pe_persid_group_pkg.get_pk_for_validation(
177: new_references.group_id ) THEN
178: CLOSE c_priority;
179: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
180: igs_ge_msg_stack.add;
181: app_exception.raise_exception;
182: ELSE
183: CLOSE c_priority;
187: FETCH c_check_hz_exists into cur_rec_hz_exists;
188: IF c_check_hz_exists%NotFound THEN
189: CLOSE c_check_hz_exists;
190: CLOSE c_priority;
191: fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
192: igs_ge_msg_stack.add;
193: app_exception.raise_exception;
194: ELSE
195: CLOSE c_check_hz_exists;
298: OPEN cur_rowid;
299: FETCH cur_rowid INTO lv_rowid;
300: IF (cur_rowid%FOUND) THEN
301: CLOSE cur_rowid;
302: fnd_message.set_name ('IGS', 'IGS_PS_USPF_USPR_FK');
303: igs_ge_msg_stack.add;
304: app_exception.raise_exception;
305: RETURN;
306: END IF;
333: OPEN cur_rowid;
334: FETCH cur_rowid INTO lv_rowid;
335: IF (cur_rowid%FOUND) THEN
336: CLOSE cur_rowid;
337: fnd_message.set_name ('IGS', 'IGS_PS_USPF_CRV_FK');
338: igs_ge_msg_stack.add;
339: app_exception.raise_exception;
340: RETURN;
341: END IF;
367: OPEN cur_rowid;
368: FETCH cur_rowid INTO lv_rowid;
369: IF (cur_rowid%FOUND) THEN
370: CLOSE cur_rowid;
371: fnd_message.set_name ('IGS', 'IGS_PS_USPF_CSTT_FK');
372: igs_ge_msg_stack.add;
373: app_exception.raise_exception;
374: RETURN;
375: END IF;
402: OPEN cur_rowid;
403: FETCH cur_rowid INTO lv_rowid;
404: IF (cur_rowid%FOUND) THEN
405: CLOSE cur_rowid;
406: fnd_message.set_name ('IGS', 'IGS_PS_USPF_US_FK');
407: igs_ge_msg_stack.add;
408: app_exception.raise_exception;
409: RETURN;
410: END IF;
436: OPEN cur_rowid;
437: FETCH cur_rowid INTO lv_rowid;
438: IF (cur_rowid%FOUND) THEN
439: CLOSE cur_rowid;
440: fnd_message.set_name ('IGS', 'IGS_PS_USPF_HZ_PARTIES_FK');
441: igs_ge_msg_stack.add;
442: app_exception.raise_exception;
443: RETURN;
444: END IF;
450: p_message_name VARCHAR2(30);
451: BEGIN
452: IF ( p_inserting = TRUE OR (p_updating = TRUE AND new_references.group_id <> old_references.group_id ) ) THEN
453: IF NOT IGS_PE_PERSID_GROUP_PKG.val_persid_group(new_references.group_id,p_message_name) THEN
454: Fnd_Message.Set_Name('IGS', p_message_name);
455: IGS_GE_MSG_STACK.ADD;
456: App_Exception.Raise_Exception;
457: END IF;
458: END IF;
509: IF ( get_pk_for_validation(
510: new_references.rsv_usec_prf_id
511: )
512: ) THEN
513: fnd_message.set_name('IGS','IGS_GE_RECORD_ALREADY_EXISTS');
514: igs_ge_msg_stack.add;
515: app_exception.raise_exception;
516: END IF;
517: check_uniqueness;
526: IF ( get_pk_for_validation (
527: new_references.rsv_usec_prf_id
528: )
529: ) THEN
530: fnd_message.set_name('IGS','IGS_GE_RECORD_ALREADY_EXISTS');
531: igs_ge_msg_stack.add;
532: app_exception.raise_exception;
533: END IF;
534: check_uniqueness;
585: IF (x_last_update_login IS NULL) THEN
586: x_last_update_login := -1;
587: END IF;
588: ELSE
589: fnd_message.set_name ('FND', 'SYSTEM-INVALID ARGS');
590: igs_ge_msg_stack.add;
591: app_exception.raise_exception;
592: END IF;
593:
688:
689: OPEN c1;
690: FETCH c1 INTO tlinfo;
691: IF (c1%notfound) THEN
692: fnd_message.set_name('FND', 'FORM_RECORD_DELETED');
693: igs_ge_msg_stack.add;
694: CLOSE c1;
695: app_exception.raise_exception;
696: RETURN;
706: AND ((tlinfo.group_id = x_group_id) OR ((tlinfo.group_id IS NULL) AND (X_group_id IS NULL)))
707: ) THEN
708: NULL;
709: ELSE
710: fnd_message.set_name('FND', 'FORM_RECORD_CHANGED');
711: igs_ge_msg_stack.add;
712: app_exception.raise_exception;
713: END IF;
714:
756: IF (x_last_update_login IS NULL) THEN
757: x_last_update_login := -1;
758: END IF;
759: ELSE
760: fnd_message.set_name( 'FND', 'SYSTEM-INVALID ARGS');
761: igs_ge_msg_stack.add;
762: app_exception.raise_exception;
763: END IF;
764: