202: CLOSE csr_sec_grp;
203: --
204: -- The primary key is invalid therefore we must error
205: --
206: fnd_message.set_name('PAY','HR_7220_INVALID_PRIMARY_KEY');
207: hr_multi_message.add
208: (p_associated_column1 => NVL(p_associated_column1, 'EVENT_ID'));
209: --
210: ELSE
307: P_OPTIONAL_MESSAGE in varchar2
308: ) is
309: begin
310: --
311: FND_MESSAGE.SET_NAME (810, 'OTA_13205_GEN_PARAMETERS');
312: FND_MESSAGE.SET_TOKEN ('PROCEDURE', P_PROCEDURE_NAME);
313: FND_MESSAGE.SET_TOKEN ('SPECIFIC_MESSAGE', P_OPTIONAL_MESSAGE);
314: FND_MESSAGE.RAISE_ERROR;
315: --
308: ) is
309: begin
310: --
311: FND_MESSAGE.SET_NAME (810, 'OTA_13205_GEN_PARAMETERS');
312: FND_MESSAGE.SET_TOKEN ('PROCEDURE', P_PROCEDURE_NAME);
313: FND_MESSAGE.SET_TOKEN ('SPECIFIC_MESSAGE', P_OPTIONAL_MESSAGE);
314: FND_MESSAGE.RAISE_ERROR;
315: --
316: end INVALID_PARAMETER;
309: begin
310: --
311: FND_MESSAGE.SET_NAME (810, 'OTA_13205_GEN_PARAMETERS');
312: FND_MESSAGE.SET_TOKEN ('PROCEDURE', P_PROCEDURE_NAME);
313: FND_MESSAGE.SET_TOKEN ('SPECIFIC_MESSAGE', P_OPTIONAL_MESSAGE);
314: FND_MESSAGE.RAISE_ERROR;
315: --
316: end INVALID_PARAMETER;
317: --
310: --
311: FND_MESSAGE.SET_NAME (810, 'OTA_13205_GEN_PARAMETERS');
312: FND_MESSAGE.SET_TOKEN ('PROCEDURE', P_PROCEDURE_NAME);
313: FND_MESSAGE.SET_TOKEN ('SPECIFIC_MESSAGE', P_OPTIONAL_MESSAGE);
314: FND_MESSAGE.RAISE_ERROR;
315: --
316: end INVALID_PARAMETER;
317: --
318: -- ----------------------------------------------------------------------------
429: OPEN evt_associations_cr('Y','N');
430: FETCH evt_associations_cr INTO l_dummy;
431: IF evt_associations_cr%found then
432: CLOSE evt_associations_cr;
433: fnd_message.set_name('OTA','OTA_443486_NO_CHARGE_CUST_EVT');
434: fnd_message.raise_error;
435: END IF;
436: CLOSE evt_associations_cr;
437:
430: FETCH evt_associations_cr INTO l_dummy;
431: IF evt_associations_cr%found then
432: CLOSE evt_associations_cr;
433: fnd_message.set_name('OTA','OTA_443486_NO_CHARGE_CUST_EVT');
434: fnd_message.raise_error;
435: END IF;
436: CLOSE evt_associations_cr;
437:
438: end if;
445: OPEN dm_cr;
446: FETCH dm_cr INTO l_dummy;
447: IF dm_cr%notfound then
448: CLOSE dm_cr;
449: fnd_message.set_name('OTA','OTA_443489_PRICE_BASIS_DM');
450: fnd_message.raise_error;
451: END IF;
452: CLOSE dm_cr;
453:
446: FETCH dm_cr INTO l_dummy;
447: IF dm_cr%notfound then
448: CLOSE dm_cr;
449: fnd_message.set_name('OTA','OTA_443489_PRICE_BASIS_DM');
450: fnd_message.raise_error;
451: END IF;
452: CLOSE dm_cr;
453:
454: IF (p_max_internal_attendees IS NULL OR
453:
454: IF (p_max_internal_attendees IS NULL OR
455: p_max_internal_attendees > 0 )
456: THEN
457: fnd_message.set_name('OTA','OTA_443487_PRICE_BASIS_C_O');
458: fnd_message.raise_error;
459: END IF;
460:
461: OPEN evt_associations_cr('N','Y');
454: IF (p_max_internal_attendees IS NULL OR
455: p_max_internal_attendees > 0 )
456: THEN
457: fnd_message.set_name('OTA','OTA_443487_PRICE_BASIS_C_O');
458: fnd_message.raise_error;
459: END IF;
460:
461: OPEN evt_associations_cr('N','Y');
462: FETCH evt_associations_cr INTO l_dummy;
461: OPEN evt_associations_cr('N','Y');
462: FETCH evt_associations_cr INTO l_dummy;
463: IF evt_associations_cr%found then
464: CLOSE evt_associations_cr;
465: fnd_message.set_name('OTA','OTA_443488_PRICE_BASIS_INT');
466: fnd_message.raise_error;
467: END IF;
468: CLOSE evt_associations_cr;
469:
462: FETCH evt_associations_cr INTO l_dummy;
463: IF evt_associations_cr%found then
464: CLOSE evt_associations_cr;
465: fnd_message.set_name('OTA','OTA_443488_PRICE_BASIS_INT');
466: fnd_message.raise_error;
467: END IF;
468: CLOSE evt_associations_cr;
469:
470: END IF;
501: --
502: hr_utility.set_location('Entering '||l_proc,10);
503: --
504: if ( p_pricing_type is not null and p_pricing_type ='S' and (p_amount is null or p_currency_code is null)) then
505: fnd_message.set_name('OTA','OTA_13440_EVT_CURR_PB');
506: fnd_message.raise_error;
507: end if;
508:
509: if ( p_pricing_type is not null and p_pricing_type ='C' and (p_amount is not null or p_currency_code is null)) then
502: hr_utility.set_location('Entering '||l_proc,10);
503: --
504: if ( p_pricing_type is not null and p_pricing_type ='S' and (p_amount is null or p_currency_code is null)) then
505: fnd_message.set_name('OTA','OTA_13440_EVT_CURR_PB');
506: fnd_message.raise_error;
507: end if;
508:
509: if ( p_pricing_type is not null and p_pricing_type ='C' and (p_amount is not null or p_currency_code is null)) then
510: fnd_message.set_name('OTA','OTA_13440_EVT_CURR_PB');
506: fnd_message.raise_error;
507: end if;
508:
509: if ( p_pricing_type is not null and p_pricing_type ='C' and (p_amount is not null or p_currency_code is null)) then
510: fnd_message.set_name('OTA','OTA_13440_EVT_CURR_PB');
511: fnd_message.raise_error;
512: end if;
513:
514: --
507: end if;
508:
509: if ( p_pricing_type is not null and p_pricing_type ='C' and (p_amount is not null or p_currency_code is null)) then
510: fnd_message.set_name('OTA','OTA_13440_EVT_CURR_PB');
511: fnd_message.raise_error;
512: end if;
513:
514: --
515: hr_utility.set_location('Leaving '||l_proc,10);
609: If nvl(l_course_start_date, hr_api.g_sot) < p_enrollment_start_date Then
610: --
611: --
612: -- ** TEMP ** Add error message with the following text.
613: fnd_message.set_name('OTA', 'OTA_13481_ENROL_START_AFTER');
614: fnd_message.raise_error;
615: --
616: End if;
617: End if;
610: --
611: --
612: -- ** TEMP ** Add error message with the following text.
613: fnd_message.set_name('OTA', 'OTA_13481_ENROL_START_AFTER');
614: fnd_message.raise_error;
615: --
616: End if;
617: End if;
618: --
624: --
625: If nvl(p_enrollment_start_date, hr_api.g_sot) > l_course_end_date Then
626: --
627: -- ** TEMP ** Add error message with the following text.
628: fnd_message.set_name('OTA','OTA_13474_ENROLL_START_AFTER');
629: fnd_message.raise_error;
630: --
631: End if;
632: --
625: If nvl(p_enrollment_start_date, hr_api.g_sot) > l_course_end_date Then
626: --
627: -- ** TEMP ** Add error message with the following text.
628: fnd_message.set_name('OTA','OTA_13474_ENROLL_START_AFTER');
629: fnd_message.raise_error;
630: --
631: End if;
632: --
633: -- Enrollment enddate is later than course enddate
634: --
635: /*If nvl(p_enrollment_end_date, l_course_end_date) > l_course_end_date Then
636: --
637: -- ** TEMP ** Add error message with the following text.
638: fnd_message.set_name('OTA','OTA_13475_ENROLL_END_AFTER');
639: fnd_message.raise_error;
640: --
641: End if;*/
642: --
635: /*If nvl(p_enrollment_end_date, l_course_end_date) > l_course_end_date Then
636: --
637: -- ** TEMP ** Add error message with the following text.
638: fnd_message.set_name('OTA','OTA_13475_ENROLL_END_AFTER');
639: fnd_message.raise_error;
640: --
641: End if;*/
642: --
643: End if;
705: --
706: hr_utility.set_location(' Entering:'||l_proc,10);
707: if (p_event_status <> 'P' AND p_event_status <> 'A') OR p_event_type <> 'SELFPACED' then
708: if p_course_end_date is null then
709: fnd_message.set_name('OTA','OTA_13480_END_DATE_NULL');
710: fnd_message.raise_error;
711: end if;
712: end if;
713: hr_utility.set_location(' Leaving:'||l_proc,10);
706: hr_utility.set_location(' Entering:'||l_proc,10);
707: if (p_event_status <> 'P' AND p_event_status <> 'A') OR p_event_type <> 'SELFPACED' then
708: if p_course_end_date is null then
709: fnd_message.set_name('OTA','OTA_13480_END_DATE_NULL');
710: fnd_message.raise_error;
711: end if;
712: end if;
713: hr_utility.set_location(' Leaving:'||l_proc,10);
714: EXCEPTION
808: open get_enrollments;
809: fetch get_enrollments into l_exists;
810: if get_enrollments%found then
811: close get_enrollments;
812: fnd_message.set_name('OTA','OTA_13526_RESTRICTED_FLAG');
813: fnd_message.set_token('STEP','1');
814: fnd_message.raise_error;
815: end if;
816: close get_enrollments;
809: fetch get_enrollments into l_exists;
810: if get_enrollments%found then
811: close get_enrollments;
812: fnd_message.set_name('OTA','OTA_13526_RESTRICTED_FLAG');
813: fnd_message.set_token('STEP','1');
814: fnd_message.raise_error;
815: end if;
816: close get_enrollments;
817: --
810: if get_enrollments%found then
811: close get_enrollments;
812: fnd_message.set_name('OTA','OTA_13526_RESTRICTED_FLAG');
813: fnd_message.set_token('STEP','1');
814: fnd_message.raise_error;
815: end if;
816: close get_enrollments;
817: --
818: elsif p_public_event_flag = 'Y' then
819: open get_tea;
820: fetch get_tea into l_exists;
821: if get_tea%found then
822: close get_tea;
823: fnd_message.set_name('OTA','OTA_13526_RESTRICTED_FLAG');
824: fnd_message.set_token('STEP','2');
825: fnd_message.raise_error;
826: end if;
827: close get_tea;
820: fetch get_tea into l_exists;
821: if get_tea%found then
822: close get_tea;
823: fnd_message.set_name('OTA','OTA_13526_RESTRICTED_FLAG');
824: fnd_message.set_token('STEP','2');
825: fnd_message.raise_error;
826: end if;
827: close get_tea;
828: end if;
821: if get_tea%found then
822: close get_tea;
823: fnd_message.set_name('OTA','OTA_13526_RESTRICTED_FLAG');
824: fnd_message.set_token('STEP','2');
825: fnd_message.raise_error;
826: end if;
827: close get_tea;
828: end if;
829: --
970: --
971: If nvl( p_child_start, hr_api.g_sot) > p_par_end Then
972: --
973: -- ** TEMP ** Add error message with the following text.
974: fnd_message.set_name('OTA','OTA_13474_ENROLL_START_AFTER');
975: fnd_message.raise_error;
976: --
977: End if;
978: --
971: If nvl( p_child_start, hr_api.g_sot) > p_par_end Then
972: --
973: -- ** TEMP ** Add error message with the following text.
974: fnd_message.set_name('OTA','OTA_13474_ENROLL_START_AFTER');
975: fnd_message.raise_error;
976: --
977: End if;
978: --
979: -- Child enddate is later than parent enddate
1004: hr_utility.set_location('Entering:'||l_proc,10);
1005:
1006: if p_course_start_time is not null and p_course_start_date is null
1007: then
1008: fnd_message.set_name('OTA','OTA_13065_CLASS_START_DATE');
1009: fnd_message.raise_error;
1010: end if;
1011: hr_utility.set_location('Leaving:'||l_proc,20);
1012:
1005:
1006: if p_course_start_time is not null and p_course_start_date is null
1007: then
1008: fnd_message.set_name('OTA','OTA_13065_CLASS_START_DATE');
1009: fnd_message.raise_error;
1010: end if;
1011: hr_utility.set_location('Leaving:'||l_proc,20);
1012:
1013: EXCEPTION
1036: begin
1037: hr_utility.set_location('Entering:'||l_proc,10);
1038: if p_course_end_time is not null and p_course_end_date is null
1039: then
1040: fnd_message.set_name('OTA','OTA_443613_CLASS_END_DATE');
1041: fnd_message.raise_error;
1042: end if;
1043: hr_utility.set_location('Leaving:'||l_proc,20);
1044:
1037: hr_utility.set_location('Entering:'||l_proc,10);
1038: if p_course_end_time is not null and p_course_end_date is null
1039: then
1040: fnd_message.set_name('OTA','OTA_443613_CLASS_END_DATE');
1041: fnd_message.raise_error;
1042: end if;
1043: hr_utility.set_location('Leaving:'||l_proc,20);
1044:
1045: EXCEPTION
1099: /*
1100: if p_event_status <> 'P' then
1101: if p_course_start_date is null or
1102: p_course_end_date is null then
1103: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1104: fnd_message.raise_error;
1105: end if;
1106: end if;
1107: */
1100: if p_event_status <> 'P' then
1101: if p_course_start_date is null or
1102: p_course_end_date is null then
1103: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1104: fnd_message.raise_error;
1105: end if;
1106: end if;
1107: */
1108: --
1108: --
1109: if (p_event_status <> 'P' AND p_event_status <> 'A') then
1110: if p_event_type <> 'SELFPACED' then
1111: if p_course_end_date is null then
1112: fnd_message.set_name('OTA','OTA_13480_END_DATE_NULL');
1113: fnd_message.raise_error;
1114: end if;
1115: end if;
1116: if p_course_start_date is null then
1109: if (p_event_status <> 'P' AND p_event_status <> 'A') then
1110: if p_event_type <> 'SELFPACED' then
1111: if p_course_end_date is null then
1112: fnd_message.set_name('OTA','OTA_13480_END_DATE_NULL');
1113: fnd_message.raise_error;
1114: end if;
1115: end if;
1116: if p_course_start_date is null then
1117: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1113: fnd_message.raise_error;
1114: end if;
1115: end if;
1116: if p_course_start_date is null then
1117: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1118: fnd_message.raise_error;
1119: end if;
1120:
1121: end if;
1114: end if;
1115: end if;
1116: if p_course_start_date is null then
1117: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1118: fnd_message.raise_error;
1119: end if;
1120:
1121: end if;
1122:
1160: if l_evt_start_date < l_start_date or
1161: l_evt_start_date > l_end_date or
1162: l_evt_end_date > l_end_date or
1163: l_evt_end_date < l_start_date then
1164: fnd_message.set_name('OTA','OTA_13534_EVT_INVALID_DATES');
1165: fnd_message.raise_error;
1166: end if;
1167:
1168: -- added for bug 3619563
1161: l_evt_start_date > l_end_date or
1162: l_evt_end_date > l_end_date or
1163: l_evt_end_date < l_start_date then
1164: fnd_message.set_name('OTA','OTA_13534_EVT_INVALID_DATES');
1165: fnd_message.raise_error;
1166: end if;
1167:
1168: -- added for bug 3619563
1169: open check_act_dates;
1207: if l_evt_start_date < l_act_start_date or
1208: l_evt_start_date > l_act_end_date or
1209: l_evt_end_date > l_act_end_date or
1210: l_evt_end_date < l_act_start_date then
1211: fnd_message.set_name('OTA','OTA_13168_EVT_ACT_DATE_OVERLAP');
1212: fnd_message.raise_error;
1213: end if;
1214: --
1215: -- added for bug 3619563
1208: l_evt_start_date > l_act_end_date or
1209: l_evt_end_date > l_act_end_date or
1210: l_evt_end_date < l_act_start_date then
1211: fnd_message.set_name('OTA','OTA_13168_EVT_ACT_DATE_OVERLAP');
1212: fnd_message.raise_error;
1213: end if;
1214: --
1215: -- added for bug 3619563
1216: --
1241: hr_utility.trace('p_event_status'||p_event_status);
1242: if p_event_status <> 'P' then
1243: if p_course_start_date is null or
1244: p_course_end_date is null then
1245: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1246: fnd_message.raise_error;
1247: end if;
1248: end if;
1249: --
1242: if p_event_status <> 'P' then
1243: if p_course_start_date is null or
1244: p_course_end_date is null then
1245: fnd_message.set_name('OTA','OTA_13533_EVT_DATES_NULL');
1246: fnd_message.raise_error;
1247: end if;
1248: end if;
1249: --
1250: open check_dates;
1275: if l_evt_start_date < l_start_date or
1276: l_evt_start_date > l_end_date or
1277: l_evt_end_date > l_end_date or
1278: l_evt_end_date < l_start_date then
1279: fnd_message.set_name('OTA','OTA_13534_EVT_INVALID_DATES');
1280: fnd_message.raise_error;
1281: end if;
1282: --
1283: hr_utility.set_location(' Exiting:'||l_proc,10);
1276: l_evt_start_date > l_end_date or
1277: l_evt_end_date > l_end_date or
1278: l_evt_end_date < l_start_date then
1279: fnd_message.set_name('OTA','OTA_13534_EVT_INVALID_DATES');
1280: fnd_message.raise_error;
1281: end if;
1282: --
1283: hr_utility.set_location(' Exiting:'||l_proc,10);
1284: end COURSE_DATES_ARE_VALID;
1323: open check_dates;
1324: fetch check_dates into l_dummy;
1325: if check_dates%found then
1326: close check_dates;
1327: fnd_message.set_name('OTA','OTA_13599_EVT_VALID_BOOKINGS');
1328: fnd_message.raise_error;
1329: end if;
1330: close check_dates;
1331: --
1324: fetch check_dates into l_dummy;
1325: if check_dates%found then
1326: close check_dates;
1327: fnd_message.set_name('OTA','OTA_13599_EVT_VALID_BOOKINGS');
1328: fnd_message.raise_error;
1329: end if;
1330: close check_dates;
1331: --
1332: end if;
1389: end if;
1390: --
1391: if l_start_date < l_evt_start_date or
1392: l_end_date > l_evt_end_date then
1393: fnd_message.set_name('OTA','OTA_13600_EVT_VALID_BD');
1394: fnd_message.raise_error;
1395: end if;
1396: --
1397: end loop;
1390: --
1391: if l_start_date < l_evt_start_date or
1392: l_end_date > l_evt_end_date then
1393: fnd_message.set_name('OTA','OTA_13600_EVT_VALID_BD');
1394: fnd_message.raise_error;
1395: end if;
1396: --
1397: end loop;
1398: --
1442: if check_course_null_dates%found and
1443: (p_course_start_date is null or p_course_end_date is null) then
1444: --
1445: --
1446: fnd_message.set_name('OTA', 'OTA_13579_EVT_SESSION_DATES');
1447: fnd_message.raise_error;
1448: end if;
1449: close check_course_null_dates;
1450: --
1443: (p_course_start_date is null or p_course_end_date is null) then
1444: --
1445: --
1446: fnd_message.set_name('OTA', 'OTA_13579_EVT_SESSION_DATES');
1447: fnd_message.raise_error;
1448: end if;
1449: close check_course_null_dates;
1450: --
1451: */
1454: if check_dates%found then
1455: --
1456: -- Warn of session date
1457: --
1458: fnd_message.set_name('OTA', 'OTA_13482_SESSION_CONFLICT');
1459: fnd_message.raise_error;
1460: end if;
1461: close check_dates;
1462: hr_utility.set_location(' Leaving:'||l_proc,10);
1455: --
1456: -- Warn of session date
1457: --
1458: fnd_message.set_name('OTA', 'OTA_13482_SESSION_CONFLICT');
1459: fnd_message.raise_error;
1460: end if;
1461: close check_dates;
1462: hr_utility.set_location(' Leaving:'||l_proc,10);
1463: end session_valid;
1623: p_session_start_time IS NOT NULL AND
1624: p_session_end_time IS NOT NULL) THEN
1625:
1626: IF ( substr(p_session_start_time,1,2) > substr(p_session_end_time,1,2) ) then
1627: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1628: fnd_message.raise_error;
1629: ELSIF (( substr(p_session_start_time,1,2) = substr(p_session_end_time,1,2) ) AND
1630: ( substr(p_session_start_time,4,2) > substr(p_session_end_time,4,2) )) then
1631: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1624: p_session_end_time IS NOT NULL) THEN
1625:
1626: IF ( substr(p_session_start_time,1,2) > substr(p_session_end_time,1,2) ) then
1627: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1628: fnd_message.raise_error;
1629: ELSIF (( substr(p_session_start_time,1,2) = substr(p_session_end_time,1,2) ) AND
1630: ( substr(p_session_start_time,4,2) > substr(p_session_end_time,4,2) )) then
1631: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1632: fnd_message.raise_error;
1627: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1628: fnd_message.raise_error;
1629: ELSIF (( substr(p_session_start_time,1,2) = substr(p_session_end_time,1,2) ) AND
1630: ( substr(p_session_start_time,4,2) > substr(p_session_end_time,4,2) )) then
1631: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1632: fnd_message.raise_error;
1633: END IF;
1634:
1635: END IF;
1628: fnd_message.raise_error;
1629: ELSIF (( substr(p_session_start_time,1,2) = substr(p_session_end_time,1,2) ) AND
1630: ( substr(p_session_start_time,4,2) > substr(p_session_end_time,4,2) )) then
1631: fnd_message.set_name('OTA', 'OTA_13064_EVT_SSN_TIME');
1632: fnd_message.raise_error;
1633: END IF;
1634:
1635: END IF;
1636: --Bug 3451221
1653: IF substr(l_course_start_time ,1,2) =
1654: substr(p_session_start_time ,1,2) THEN
1655: IF substr(l_course_start_time ,4,2) >
1656: substr(p_session_start_time ,4,2) THEN
1657: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1658: fnd_message.raise_error;
1659: END IF;
1660: ELSIF substr(l_course_start_time ,1,2) >
1661: substr(p_session_start_time ,1,2) THEN
1654: substr(p_session_start_time ,1,2) THEN
1655: IF substr(l_course_start_time ,4,2) >
1656: substr(p_session_start_time ,4,2) THEN
1657: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1658: fnd_message.raise_error;
1659: END IF;
1660: ELSIF substr(l_course_start_time ,1,2) >
1661: substr(p_session_start_time ,1,2) THEN
1662: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1658: fnd_message.raise_error;
1659: END IF;
1660: ELSIF substr(l_course_start_time ,1,2) >
1661: substr(p_session_start_time ,1,2) THEN
1662: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1663: fnd_message.raise_error;
1664: END IF;
1665: END IF;
1666: IF (l_course_start_time IS NOT NULL) AND (p_session_start_time IS NULL) THEN
1659: END IF;
1660: ELSIF substr(l_course_start_time ,1,2) >
1661: substr(p_session_start_time ,1,2) THEN
1662: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1663: fnd_message.raise_error;
1664: END IF;
1665: END IF;
1666: IF (l_course_start_time IS NOT NULL) AND (p_session_start_time IS NULL) THEN
1667: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1663: fnd_message.raise_error;
1664: END IF;
1665: END IF;
1666: IF (l_course_start_time IS NOT NULL) AND (p_session_start_time IS NULL) THEN
1667: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1668: fnd_message.raise_error;
1669: END IF;
1670: END IF;
1671:
1664: END IF;
1665: END IF;
1666: IF (l_course_start_time IS NOT NULL) AND (p_session_start_time IS NULL) THEN
1667: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1668: fnd_message.raise_error;
1669: END IF;
1670: END IF;
1671:
1672: IF l_course_end_date = p_session_start_date THEN
1675: IF substr(l_course_end_time ,1,2) =
1676: substr(p_session_end_time ,1,2) THEN
1677: IF substr(l_course_end_time ,4,2) <
1678: substr(p_session_end_time ,4,2) THEN
1679: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1680: fnd_message.raise_error;
1681: END IF;
1682: ELSIF substr(l_course_end_time ,1,2) <
1683: substr(p_session_end_time ,1,2) THEN
1676: substr(p_session_end_time ,1,2) THEN
1677: IF substr(l_course_end_time ,4,2) <
1678: substr(p_session_end_time ,4,2) THEN
1679: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1680: fnd_message.raise_error;
1681: END IF;
1682: ELSIF substr(l_course_end_time ,1,2) <
1683: substr(p_session_end_time ,1,2) THEN
1684: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1680: fnd_message.raise_error;
1681: END IF;
1682: ELSIF substr(l_course_end_time ,1,2) <
1683: substr(p_session_end_time ,1,2) THEN
1684: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1685: fnd_message.raise_error;
1686: END IF;
1687: END IF;
1688: IF (l_course_end_time IS NOT NULL) AND (p_session_start_time IS NOT NULL) THEN
1681: END IF;
1682: ELSIF substr(l_course_end_time ,1,2) <
1683: substr(p_session_end_time ,1,2) THEN
1684: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1685: fnd_message.raise_error;
1686: END IF;
1687: END IF;
1688: IF (l_course_end_time IS NOT NULL) AND (p_session_start_time IS NOT NULL) THEN
1689: IF substr(l_course_end_time ,1,2) = substr(p_session_start_time ,1,2) THEN
1687: END IF;
1688: IF (l_course_end_time IS NOT NULL) AND (p_session_start_time IS NOT NULL) THEN
1689: IF substr(l_course_end_time ,1,2) = substr(p_session_start_time ,1,2) THEN
1690: IF substr(l_course_end_time ,4,2) < substr(p_session_start_time ,4,2) THEN
1691: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1692: fnd_message.raise_error;
1693: END IF;
1694: ELSIF substr(l_course_end_time ,1,2) < substr(p_session_start_time ,1,2) THEN
1695: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1688: IF (l_course_end_time IS NOT NULL) AND (p_session_start_time IS NOT NULL) THEN
1689: IF substr(l_course_end_time ,1,2) = substr(p_session_start_time ,1,2) THEN
1690: IF substr(l_course_end_time ,4,2) < substr(p_session_start_time ,4,2) THEN
1691: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1692: fnd_message.raise_error;
1693: END IF;
1694: ELSIF substr(l_course_end_time ,1,2) < substr(p_session_start_time ,1,2) THEN
1695: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1696: fnd_message.raise_error;
1691: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1692: fnd_message.raise_error;
1693: END IF;
1694: ELSIF substr(l_course_end_time ,1,2) < substr(p_session_start_time ,1,2) THEN
1695: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1696: fnd_message.raise_error;
1697: END IF;
1698: END IF;
1699: IF (l_course_end_time IS NOT NULL) AND (p_session_end_time IS NULL) THEN
1692: fnd_message.raise_error;
1693: END IF;
1694: ELSIF substr(l_course_end_time ,1,2) < substr(p_session_start_time ,1,2) THEN
1695: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1696: fnd_message.raise_error;
1697: END IF;
1698: END IF;
1699: IF (l_course_end_time IS NOT NULL) AND (p_session_end_time IS NULL) THEN
1700: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1696: fnd_message.raise_error;
1697: END IF;
1698: END IF;
1699: IF (l_course_end_time IS NOT NULL) AND (p_session_end_time IS NULL) THEN
1700: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1701: fnd_message.raise_error;
1702: END IF;
1703: END IF;
1704: HR_UTILITY.SET_LOCATION ('Entering:' || W_PROC, 10);
1697: END IF;
1698: END IF;
1699: IF (l_course_end_time IS NOT NULL) AND (p_session_end_time IS NULL) THEN
1700: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1701: fnd_message.raise_error;
1702: END IF;
1703: END IF;
1704: HR_UTILITY.SET_LOCATION ('Entering:' || W_PROC, 10);
1705:
1760: -- check if course start and end date are null
1761: -- if null then set them to start and end of time
1762: --
1763: if l_course_start_date is null or l_course_end_date is null then
1764: fnd_message.set_name('OTA','OTA_13579_EVT_SESSION_DATES');
1765: fnd_message.raise_error;
1766: end if;
1767: /* if l_course_start_date is null then
1768: l_course_start_date := hr_api.g_sot;
1761: -- if null then set them to start and end of time
1762: --
1763: if l_course_start_date is null or l_course_end_date is null then
1764: fnd_message.set_name('OTA','OTA_13579_EVT_SESSION_DATES');
1765: fnd_message.raise_error;
1766: end if;
1767: /* if l_course_start_date is null then
1768: l_course_start_date := hr_api.g_sot;
1769: end if;
1885: IF substr(p_course_start_time ,1,2) =
1886: substr(l_ssn_start_time ,1,2) THEN
1887: IF substr(p_course_start_time ,4,2) >
1888: substr(l_ssn_start_time ,4,2) THEN
1889: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1890: fnd_message.raise_error;
1891: END IF;
1892: ELSIF substr(p_course_start_time ,1,2) >
1893: substr(l_ssn_start_time ,1,2) THEN
1886: substr(l_ssn_start_time ,1,2) THEN
1887: IF substr(p_course_start_time ,4,2) >
1888: substr(l_ssn_start_time ,4,2) THEN
1889: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1890: fnd_message.raise_error;
1891: END IF;
1892: ELSIF substr(p_course_start_time ,1,2) >
1893: substr(l_ssn_start_time ,1,2) THEN
1894: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1890: fnd_message.raise_error;
1891: END IF;
1892: ELSIF substr(p_course_start_time ,1,2) >
1893: substr(l_ssn_start_time ,1,2) THEN
1894: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1895: fnd_message.raise_error;
1896: END IF;
1897: END IF;
1898: END IF;
1891: END IF;
1892: ELSIF substr(p_course_start_time ,1,2) >
1893: substr(l_ssn_start_time ,1,2) THEN
1894: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1895: fnd_message.raise_error;
1896: END IF;
1897: END IF;
1898: END IF;
1899:
1903: IF substr(p_course_end_time ,1,2) =
1904: substr(l_ssn_end_time ,1,2) THEN
1905: IF substr(p_course_end_time ,4,2) <
1906: substr(l_ssn_end_time ,4,2) THEN
1907: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1908: fnd_message.raise_error;
1909: END IF;
1910: ELSIF substr(p_course_end_time ,1,2) <
1911: substr(l_ssn_end_time ,1,2) THEN
1904: substr(l_ssn_end_time ,1,2) THEN
1905: IF substr(p_course_end_time ,4,2) <
1906: substr(l_ssn_end_time ,4,2) THEN
1907: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1908: fnd_message.raise_error;
1909: END IF;
1910: ELSIF substr(p_course_end_time ,1,2) <
1911: substr(l_ssn_end_time ,1,2) THEN
1912: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1908: fnd_message.raise_error;
1909: END IF;
1910: ELSIF substr(p_course_end_time ,1,2) <
1911: substr(l_ssn_end_time ,1,2) THEN
1912: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1913: fnd_message.raise_error;
1914: END IF;
1915: END IF;
1916: END IF;
1909: END IF;
1910: ELSIF substr(p_course_end_time ,1,2) <
1911: substr(l_ssn_end_time ,1,2) THEN
1912: fnd_message.set_name('OTA','OTA_13563_EVT_SESSION_TIME');
1913: fnd_message.raise_error;
1914: END IF;
1915: END IF;
1916: END IF;
1917:
2023: --
2024: if (p_budget_cost is not null or p_actual_cost is not null) and
2025: p_budget_currency_code is null then
2026: --
2027: fnd_message.set_name('OTA','OTA_13394_TAV_COST_ATTR');
2028: fnd_message.raise_error;
2029: --
2030: end if;
2031: --
2024: if (p_budget_cost is not null or p_actual_cost is not null) and
2025: p_budget_currency_code is null then
2026: --
2027: fnd_message.set_name('OTA','OTA_13394_TAV_COST_ATTR');
2028: fnd_message.raise_error;
2029: --
2030: end if;
2031: --
2032: hr_utility.set_location(' Leaving:'|| v_proc, 10);
2365: open get_enrollments;
2366: fetch get_enrollments into l_exists;
2367: if get_enrollments%found then
2368: close get_enrollments;
2369: fnd_message.set_name('OTA','OTA_13527_PRICE_BASIS_CHANGE');
2370: fnd_message.raise_error;
2371: end if;
2372: close get_enrollments;
2373: --
2366: fetch get_enrollments into l_exists;
2367: if get_enrollments%found then
2368: close get_enrollments;
2369: fnd_message.set_name('OTA','OTA_13527_PRICE_BASIS_CHANGE');
2370: fnd_message.raise_error;
2371: end if;
2372: close get_enrollments;
2373: --
2374: open get_event_associations;
2374: open get_event_associations;
2375: fetch get_event_associations into l_exists;
2376: if get_event_associations%found then
2377: close get_event_associations;
2378: fnd_message.set_name('OTA','OTA_13527_PRICE_BASIS_CHANGE');
2379: fnd_message.raise_error;
2380: end if;
2381: close get_event_associations;
2382: --
2375: fetch get_event_associations into l_exists;
2376: if get_event_associations%found then
2377: close get_event_associations;
2378: fnd_message.set_name('OTA','OTA_13527_PRICE_BASIS_CHANGE');
2379: fnd_message.raise_error;
2380: end if;
2381: close get_event_associations;
2382: --
2383: end if;
2403: IS
2404: l_timezone_id NUMBER := ota_timezone_util.get_timezone_id(p_timezone);
2405: BEGIN
2406: IF l_timezone_id IS NULL THEN
2407: fnd_message.set_name('OTA','OTA_443982_TIMEZONE_ERROR');
2408: fnd_message.set_token('OBJECT_TYPE',ota_utility.get_lookup_meaning('OTA_OBJECT_TYPE','CL',810));
2409: fnd_message.raise_error;
2410: END IF;
2411: END check_timezone;
2404: l_timezone_id NUMBER := ota_timezone_util.get_timezone_id(p_timezone);
2405: BEGIN
2406: IF l_timezone_id IS NULL THEN
2407: fnd_message.set_name('OTA','OTA_443982_TIMEZONE_ERROR');
2408: fnd_message.set_token('OBJECT_TYPE',ota_utility.get_lookup_meaning('OTA_OBJECT_TYPE','CL',810));
2409: fnd_message.raise_error;
2410: END IF;
2411: END check_timezone;
2412: --
2405: BEGIN
2406: IF l_timezone_id IS NULL THEN
2407: fnd_message.set_name('OTA','OTA_443982_TIMEZONE_ERROR');
2408: fnd_message.set_token('OBJECT_TYPE',ota_utility.get_lookup_meaning('OTA_OBJECT_TYPE','CL',810));
2409: fnd_message.raise_error;
2410: END IF;
2411: END check_timezone;
2412: --
2413: -- ----------------------------------------------------------------------------
2428: and (substr(p_time,4,1) >= '0' and substr(p_time,4,1)<= '5')
2429: and (substr(p_time,5,1) >= '0' and substr(p_time,5,1)<= '9')
2430: and (to_number (substr (p_time, 1,2)) between 0 and 23
2431: and to_number (substr (p_time,4)) between 0 and 59))) then
2432: fnd_message.set_name('OTA','OTA_13444_EVT_TIME_FORMAT');
2433: fnd_message.raise_error;
2434: END IF;
2435: END IF;
2436: END;
2429: and (substr(p_time,5,1) >= '0' and substr(p_time,5,1)<= '9')
2430: and (to_number (substr (p_time, 1,2)) between 0 and 23
2431: and to_number (substr (p_time,4)) between 0 and 59))) then
2432: fnd_message.set_name('OTA','OTA_13444_EVT_TIME_FORMAT');
2433: fnd_message.raise_error;
2434: END IF;
2435: END IF;
2436: END;
2437:
2759: l_commitment_start_date,
2760: l_commitment_end_date);
2761: IF l_commitment_end_date IS NOT NULL
2762: AND p_rec.course_end_date > l_commitment_end_date THEN
2763: FND_MESSAGE.SET_NAME ('OTA', 'OTA_OM_COMMITMENT');
2764: FND_MESSAGE.SET_TOKEN ('COMMITMENT_NUMBER', l_commitment_number);
2765: --FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate(l_commitment_end_date));
2766: FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate((l_commitment_end_date),2));
2767: FND_MESSAGE.RAISE_ERROR;
2760: l_commitment_end_date);
2761: IF l_commitment_end_date IS NOT NULL
2762: AND p_rec.course_end_date > l_commitment_end_date THEN
2763: FND_MESSAGE.SET_NAME ('OTA', 'OTA_OM_COMMITMENT');
2764: FND_MESSAGE.SET_TOKEN ('COMMITMENT_NUMBER', l_commitment_number);
2765: --FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate(l_commitment_end_date));
2766: FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate((l_commitment_end_date),2));
2767: FND_MESSAGE.RAISE_ERROR;
2768: END IF;
2761: IF l_commitment_end_date IS NOT NULL
2762: AND p_rec.course_end_date > l_commitment_end_date THEN
2763: FND_MESSAGE.SET_NAME ('OTA', 'OTA_OM_COMMITMENT');
2764: FND_MESSAGE.SET_TOKEN ('COMMITMENT_NUMBER', l_commitment_number);
2765: --FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate(l_commitment_end_date));
2766: FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate((l_commitment_end_date),2));
2767: FND_MESSAGE.RAISE_ERROR;
2768: END IF;
2769: END IF;
2762: AND p_rec.course_end_date > l_commitment_end_date THEN
2763: FND_MESSAGE.SET_NAME ('OTA', 'OTA_OM_COMMITMENT');
2764: FND_MESSAGE.SET_TOKEN ('COMMITMENT_NUMBER', l_commitment_number);
2765: --FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate(l_commitment_end_date));
2766: FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate((l_commitment_end_date),2));
2767: FND_MESSAGE.RAISE_ERROR;
2768: END IF;
2769: END IF;
2770: END IF;
2763: FND_MESSAGE.SET_NAME ('OTA', 'OTA_OM_COMMITMENT');
2764: FND_MESSAGE.SET_TOKEN ('COMMITMENT_NUMBER', l_commitment_number);
2765: --FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate(l_commitment_end_date));
2766: FND_MESSAGE.SET_TOKEN ('COMMITMENT_END_DATE', fnd_date.date_to_chardate((l_commitment_end_date),2));
2767: FND_MESSAGE.RAISE_ERROR;
2768: END IF;
2769: END IF;
2770: END IF;
2771:
2894: open c_get_tpc_rows;
2895: fetch c_get_tpc_rows into l_dummy;
2896: if c_get_tpc_rows%found then
2897: close c_get_tpc_rows;
2898: fnd_message.set_name ('OTA', 'OTA_13823_EVT_NO_DEL_TPC_EXIST');
2899: fnd_message.raise_error;
2900: else
2901: close c_get_tpc_rows;
2902: -- Determine if the event has per_budget_element records
2895: fetch c_get_tpc_rows into l_dummy;
2896: if c_get_tpc_rows%found then
2897: close c_get_tpc_rows;
2898: fnd_message.set_name ('OTA', 'OTA_13823_EVT_NO_DEL_TPC_EXIST');
2899: fnd_message.raise_error;
2900: else
2901: close c_get_tpc_rows;
2902: -- Determine if the event has per_budget_element records
2903: open c_get_pbe_rows;
2903: open c_get_pbe_rows;
2904: fetch c_get_pbe_rows into l_dummy;
2905: if c_get_pbe_rows%found then
2906: close c_get_pbe_rows;
2907: fnd_message.set_name ('OTA', 'OTA_13824_EVT_NO_DEL_BGE_EXIST');
2908: fnd_message.raise_error;
2909: else
2910: close c_get_pbe_rows;
2911: end if;
2904: fetch c_get_pbe_rows into l_dummy;
2905: if c_get_pbe_rows%found then
2906: close c_get_pbe_rows;
2907: fnd_message.set_name ('OTA', 'OTA_13824_EVT_NO_DEL_BGE_EXIST');
2908: fnd_message.raise_error;
2909: else
2910: close c_get_pbe_rows;
2911: end if;
2912: end if;
2918: if c_session_details%found then
2919: --
2920: close c_session_details;
2921: --
2922: fnd_message.set_name ('OTA', 'OTA_13677_EVT_SESSION_EXISTS');
2923: fnd_message.raise_error;
2924: --
2925: end if;
2926: --
2919: --
2920: close c_session_details;
2921: --
2922: fnd_message.set_name ('OTA', 'OTA_13677_EVT_SESSION_EXISTS');
2923: fnd_message.raise_error;
2924: --
2925: end if;
2926: --
2927: close c_session_details;
2933: if c_resource_details%found then
2934: --
2935: close c_resource_details;
2936: --
2937: fnd_message.set_name ('OTA', 'OTA_13678_EVT_RES_EXISTS');
2938: fnd_message.raise_error;
2939: --
2940: end if;
2941: --
2934: --
2935: close c_resource_details;
2936: --
2937: fnd_message.set_name ('OTA', 'OTA_13678_EVT_RES_EXISTS');
2938: fnd_message.raise_error;
2939: --
2940: end if;
2941: --
2942: close c_resource_details;
2948: if c_program_membership_details%found then
2949: --
2950: close c_program_membership_details;
2951: --
2952: fnd_message.set_name ('OTA', 'OTA_13681_EVT_PMM_EXISTS');
2953: fnd_message.raise_error;
2954: --
2955: end if;
2956: --
2949: --
2950: close c_program_membership_details;
2951: --
2952: fnd_message.set_name ('OTA', 'OTA_13681_EVT_PMM_EXISTS');
2953: fnd_message.raise_error;
2954: --
2955: end if;
2956: --
2957: close c_program_membership_details;
2963: if c_event_associations_details%found then
2964: --
2965: close c_event_associations_details;
2966: --
2967: fnd_message.set_name ('OTA', 'OTA_13683_EVT_TEA_EXISTS');
2968: fnd_message.raise_error;
2969: --
2970: end if;
2971: --
2964: --
2965: close c_event_associations_details;
2966: --
2967: fnd_message.set_name ('OTA', 'OTA_13683_EVT_TEA_EXISTS');
2968: fnd_message.raise_error;
2969: --
2970: end if;
2971: --
2972: close c_event_associations_details;
2978: if c_delegate_bookings_details%found then
2979: --
2980: close c_delegate_bookings_details;
2981: --
2982: fnd_message.set_name ('OTA', 'OTA_13679_EVT_TDB_EXISTS');
2983: fnd_message.raise_error;
2984: --
2985: end if;
2986: --
2979: --
2980: close c_delegate_bookings_details;
2981: --
2982: fnd_message.set_name ('OTA', 'OTA_13679_EVT_TDB_EXISTS');
2983: fnd_message.raise_error;
2984: --
2985: end if;
2986: --
2987: close c_delegate_bookings_details;
2993: if c_evaluation_details%found then
2994: --
2995: close c_evaluation_details;
2996: --
2997: fnd_message.set_name ('OTA', 'OTA_467095_EVT_EVAL_EXISTS');
2998: fnd_message.raise_error;
2999: --
3000: end if;
3001: --
2994: --
2995: close c_evaluation_details;
2996: --
2997: fnd_message.set_name ('OTA', 'OTA_467095_EVT_EVAL_EXISTS');
2998: fnd_message.raise_error;
2999: --
3000: end if;
3001: --
3002: close c_evaluation_details;
3008: if c_booking_deals_details%found then
3009: --
3010: close c_booking_deals_details;
3011: --
3012: fnd_message.set_name ('OTA', 'OTA_13680_EVT_TBD_EXISTS');
3013: fnd_message.raise_error;
3014: --
3015: end if;
3016: --
3009: --
3010: close c_booking_deals_details;
3011: --
3012: fnd_message.set_name ('OTA', 'OTA_13680_EVT_TBD_EXISTS');
3013: fnd_message.raise_error;
3014: --
3015: end if;
3016: --
3017: close c_booking_deals_details;
3023: if c_act_cat_inclusions_details%found then
3024: --
3025: close c_act_cat_inclusions_details;
3026: --
3027: fnd_message.set_name ('OTA', 'OTA_13682_EVT_CAT_EXISTS');
3028: fnd_message.raise_error;
3029: --
3030: end if;
3031: --
3024: --
3025: close c_act_cat_inclusions_details;
3026: --
3027: fnd_message.set_name ('OTA', 'OTA_13682_EVT_CAT_EXISTS');
3028: fnd_message.raise_error;
3029: --
3030: end if;
3031: --
3032: close c_act_cat_inclusions_details;
3038: if c_attempts_details%found then
3039: --
3040: close c_attempts_details;
3041: --
3042: fnd_message.set_name ('OTA', 'OTA_443538_EVT_ATT_EXISTS');
3043: fnd_message.raise_error;
3044: --
3045: end if;
3046: --
3039: --
3040: close c_attempts_details;
3041: --
3042: fnd_message.set_name ('OTA', 'OTA_443538_EVT_ATT_EXISTS');
3043: fnd_message.raise_error;
3044: --
3045: end if;
3046: --
3047: close c_attempts_details;
3050: open c_conference_details;
3051: fetch c_conference_details into l_dummy;
3052: if c_conference_details%found then
3053: close c_conference_details;
3054: fnd_message.set_name('OTA', 'OTA_443916_EVT_CFR_EXISTS');
3055: fnd_message.raise_error;
3056: end if;
3057: close c_conference_details;
3058:
3051: fetch c_conference_details into l_dummy;
3052: if c_conference_details%found then
3053: close c_conference_details;
3054: fnd_message.set_name('OTA', 'OTA_443916_EVT_CFR_EXISTS');
3055: fnd_message.raise_error;
3056: end if;
3057: close c_conference_details;
3058:
3059:
3162: OPEN c_people_cross;
3163: FETCH c_people_cross into l_exist;
3164: if c_people_cross%notfound then
3165: close c_people_cross;
3166: fnd_message.set_name('OTA','OTA_13887_EVT_OWNER_INVALID');
3167: fnd_message.raise_error;
3168: end if;
3169: close c_people_cross;
3170: else
3163: FETCH c_people_cross into l_exist;
3164: if c_people_cross%notfound then
3165: close c_people_cross;
3166: fnd_message.set_name('OTA','OTA_13887_EVT_OWNER_INVALID');
3167: fnd_message.raise_error;
3168: end if;
3169: close c_people_cross;
3170: else
3171: hr_utility.set_location('Entering:'||l_proc, 20);
3172: OPEN c_people;
3173: FETCH c_people into l_exist;
3174: if c_people%notfound then
3175: close c_people;
3176: fnd_message.set_name('OTA','OTA_13887_EVT_OWNER_INVALID');
3177: fnd_message.raise_error;
3178: end if;
3179: close c_people;
3180: end if;
3173: FETCH c_people into l_exist;
3174: if c_people%notfound then
3175: close c_people;
3176: fnd_message.set_name('OTA','OTA_13887_EVT_OWNER_INVALID');
3177: fnd_message.raise_error;
3178: end if;
3179: close c_people;
3180: end if;
3181: hr_utility.set_location('Leaving:'||l_proc, 40);
3224: open csr_order_line;
3225: fetch csr_order_line into l_exists;
3226: if csr_order_line%notfound then
3227: close csr_order_line;
3228: fnd_message.set_name('OTA','OTA_13888_TDB_LINE_INVALID');
3229: fnd_message.raise_error;
3230: end if;
3231: close csr_order_line;
3232: hr_utility.set_location('Entering:'||l_proc, 20);
3225: fetch csr_order_line into l_exists;
3226: if csr_order_line%notfound then
3227: close csr_order_line;
3228: fnd_message.set_name('OTA','OTA_13888_TDB_LINE_INVALID');
3229: fnd_message.raise_error;
3230: end if;
3231: close csr_order_line;
3232: hr_utility.set_location('Entering:'||l_proc, 20);
3233: end if;
3374: Begin
3375: hr_utility.set_location('Entering:'||l_proc, 5);
3376:
3377: if p_line_id is not null then
3378: fnd_message.set_name('OTA','OTA_13896_EVT_ORDER_LINE_EXIST');
3379: fnd_message.raise_error;
3380: hr_utility.set_location('Entering:'||l_proc, 20);
3381:
3382: end if;
3375: hr_utility.set_location('Entering:'||l_proc, 5);
3376:
3377: if p_line_id is not null then
3378: fnd_message.set_name('OTA','OTA_13896_EVT_ORDER_LINE_EXIST');
3379: fnd_message.raise_error;
3380: hr_utility.set_location('Entering:'||l_proc, 20);
3381:
3382: end if;
3383: hr_utility.set_location('Leaving:'||l_proc, 30);
3428: open c_training_center;
3429: fetch c_training_center into l_exists;
3430: if c_training_center%notfound then
3431: close c_training_center;
3432: fnd_message.set_name('OTA','OTA_13907_TSR_TRNCTR_NOT_EXIST');
3433: fnd_message.raise_error;
3434: end if;
3435: close c_training_center;
3436: hr_utility.set_location('Entering:'||l_proc, 20);
3429: fetch c_training_center into l_exists;
3430: if c_training_center%notfound then
3431: close c_training_center;
3432: fnd_message.set_name('OTA','OTA_13907_TSR_TRNCTR_NOT_EXIST');
3433: fnd_message.raise_error;
3434: end if;
3435: close c_training_center;
3436: hr_utility.set_location('Entering:'||l_proc, 20);
3437: end if;
3486: open c_location;
3487: fetch c_location into l_exists;
3488: if c_location%notfound then
3489: close c_location;
3490: fnd_message.set_name('OTA','OTA_13908_TSR_LOC_NOT_EXIST');
3491: fnd_message.raise_error;
3492: end if;
3493: close c_location;
3494: hr_utility.set_location('Entering:'||l_proc, 20);
3487: fetch c_location into l_exists;
3488: if c_location%notfound then
3489: close c_location;
3490: fnd_message.set_name('OTA','OTA_13908_TSR_LOC_NOT_EXIST');
3491: fnd_message.raise_error;
3492: end if;
3493: close c_location;
3494: hr_utility.set_location('Entering:'||l_proc, 20);
3495: end if;
3597: open csr_offering;
3598: fetch csr_offering into l_exists;
3599: if csr_offering%notfound then
3600: close csr_offering;
3601: fnd_message.set_name('OTA','OTA_443321_EVT_OFF_INVALID_ACT');
3602: fnd_message.raise_error;
3603: end if;
3604: close csr_offering;
3605: hr_utility.set_location('Leaving:'||l_proc, 20);
3598: fetch csr_offering into l_exists;
3599: if csr_offering%notfound then
3600: close csr_offering;
3601: fnd_message.set_name('OTA','OTA_443321_EVT_OFF_INVALID_ACT');
3602: fnd_message.raise_error;
3603: end if;
3604: close csr_offering;
3605: hr_utility.set_location('Leaving:'||l_proc, 20);
3606: EXCEPTION
3646:
3647: OPEN csr_org;
3648: FETCH csr_org INTO l_username;
3649: if csr_org%notfound then
3650: fnd_message.set_name('OTA', 'OTA_EVT_SECURE');
3651: fnd_message.raise_error;
3652: end if;
3653: close csr_org;
3654:
3647: OPEN csr_org;
3648: FETCH csr_org INTO l_username;
3649: if csr_org%notfound then
3650: fnd_message.set_name('OTA', 'OTA_EVT_SECURE');
3651: fnd_message.raise_error;
3652: end if;
3653: close csr_org;
3654:
3655:
3658: FETCH csr_org INTO l_username;
3659: l_user := fnd_profile.value('USERNAME');
3660: l_condition := nvl(l_user, 'UNSET1') = nvl(l_username, 'UNSET2');
3661: IF NOT l_condition THEN
3662: fnd_message.set_name('OTA', 'OTA_EVT_SECURE');
3663: fnd_message.raise_error;
3664: END IF;
3665: CLOSE csr_org;*/
3666: hr_utility.set_location('Leaving:'||l_proc, 20);
3659: l_user := fnd_profile.value('USERNAME');
3660: l_condition := nvl(l_user, 'UNSET1') = nvl(l_username, 'UNSET2');
3661: IF NOT l_condition THEN
3662: fnd_message.set_name('OTA', 'OTA_EVT_SECURE');
3663: fnd_message.raise_error;
3664: END IF;
3665: CLOSE csr_org;*/
3666: hr_utility.set_location('Leaving:'||l_proc, 20);
3667: