DBA Data[Home] [Help]

APPS.PQH_PSF_BUS dependencies on PQH_PSF_BUS

Line 1: package body PQH_PSF_BUS as

1: package body PQH_PSF_BUS as
2: /* $Header: pqpsfbus.pkb 120.25.12020000.4 2012/07/05 12:56:19 amnaraya ship $ */
3: --
4: function POSITION_CONTROL_ENABLED(P_ORGANIZATION_ID NUMBER default null,
5: p_effective_date in date default sysdate,

Line 24: l_proc varchar2(100):= 'PQH_PSF_BUS.POS_ASSIGNMENTS_EXIST';

20: function pos_assignments_exist(p_position_id number,
21: p_validation_start_date date, p_validation_end_date date)
22: return boolean is
23: l_dummy varchar2(10);
24: l_proc varchar2(100):= 'PQH_PSF_BUS.POS_ASSIGNMENTS_EXIST';
25:
26: cursor c1 is
27: select 'x'
28: from dual

Line 121: select max(pqh_psf_bus.sum_assignment_fte(p_position_id,ed))

117: --
118: cursor c_asg_max_count(p_position_id number
119: , p_validation_start_date date
120: , p_validation_end_date date) is
121: select max(pqh_psf_bus.sum_assignment_fte(p_position_id,ed))
122: from
123: (select a.effective_start_date ed
124: from per_all_assignments_f a
125: where a.position_id = p_position_id

Line 165: if (pqh_psf_bus.pos_assignments_exist(p_rec.position_id,

161: 'UPDATE_OVERRIDE')) AND
162: ('ELIMINATED'=hr_psf_shd.get_availability_status(
163: p_rec.availability_status_id,p_rec.business_group_id))) then
164: hr_utility.set_location('AVAILABILITY STATUS : ELIMINATED', 621);
165: if (pqh_psf_bus.pos_assignments_exist(p_rec.position_id,
166: p_validation_start_date, p_validation_end_date)) then
167: hr_utility.set_location('ASSIGNMENTS EXIST FOR ELIMINATED POSITION', 623);
168: pqh_utility.set_message(800,'PER_POS_ELIMINATED',p_rec.organization_id);
169: pqh_utility.raise_error;

Line 203: l_chk_earliest_hire_date := pqh_psf_bus.chk_earliest_hire_date(

199: --
200: -- Check Earliest hire date validation rule
201: --
202: --
203: l_chk_earliest_hire_date := pqh_psf_bus.chk_earliest_hire_date(
204: p_position_id => p_rec.position_id, p_earliest_hire_date => p_rec.earliest_hire_date );
205: if (not l_chk_earliest_hire_date ) then
206: pqh_utility.set_message(8302,'PQH_ASG_HIRED_BEFORE_EARLIEST',p_rec.organization_id);
207: pqh_utility.raise_error;

Line 214: l_chk_prop_date_for_layoff := pqh_psf_bus.chk_prop_date_for_layoff(

210: --
211: -- Check proposed date for layoff validation rule
212: --
213: --
214: l_chk_prop_date_for_layoff := pqh_psf_bus.chk_prop_date_for_layoff(
215: p_position_id => p_rec.position_id, p_proposed_date_for_layoff => p_rec.proposed_date_for_layoff );
216: if (not l_chk_prop_date_for_layoff ) then
217: --pqh_utility.set_message(8302,'PQH_LAYOFF_DT_GT_ASG_DT',p_rec.organization_id);
218: pqh_utility.set_message(8302,'PQH_ASG_DT_GT_LAYOFF_DT',p_rec.organization_id);

Line 272: if not pqh_psf_bus.chk_seasonal_dates(

268: -- Check for Assignment attached to a Seasonal Position is with in seasonal dates
269: --
270: hr_utility.set_location('Insert Validate: Before Seasonal Validation', 130);
271: if l_rec.seasonal_flag = 'Y' then
272: if not pqh_psf_bus.chk_seasonal_dates(
273: p_position_id => p_rec.position_id,
274: p_seasonal_flag => l_rec.seasonal_flag,
275: p_assignment_start_date => p_effective_date) then
276: pqh_utility.set_message(8302,'PQH_NON_SEASONAL_ASG_DATE',l_rec.organization_id);

Line 310: l_default_asg_fte := pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);

306: --
307: hr_utility.set_location('Insert Validate: SHARED position has FTE greater than', 130);
308: if (l_rec.position_type = 'SHARED') then
309: --
310: l_default_asg_fte := pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);
311: --
312: pqh_psf_bus.CHK_ABV_FTE_GT_POS_BGT_FTE(
313: p_assignment_id => p_rec.assignment_id,
314: p_position_id => p_rec.position_id,

Line 312: pqh_psf_bus.CHK_ABV_FTE_GT_POS_BGT_FTE(

308: if (l_rec.position_type = 'SHARED') then
309: --
310: l_default_asg_fte := pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);
311: --
312: pqh_psf_bus.CHK_ABV_FTE_GT_POS_BGT_FTE(
313: p_assignment_id => p_rec.assignment_id,
314: p_position_id => p_rec.position_id,
315: p_effective_date => p_rec.effective_start_date,
316: p_default_asg_fte => l_default_asg_fte,

Line 327: pqh_psf_bus.chk_future_pos_asg_fte(

323: end if;
324: --
325: if (not l_bgt_lt_abv_fte) and p_rec.assignment_type <> 'A' then -- fix for 10434560
326: hr_utility.set_location('l_default_asg_fte :'||l_default_asg_fte, 135);
327: pqh_psf_bus.chk_future_pos_asg_fte(
328: p_assignment_id => p_rec.assignment_id,
329: p_position_id => p_rec.position_id,
330: p_validation_start_date => p_rec.effective_start_date,
331: p_validation_end_date => hr_general.end_of_time,

Line 340: if pqh_psf_bus.open_status(p_rec.position_id, p_rec.effective_start_date) = 'OPEN' then

336: --
337: hr_utility.set_location('Insert Validate:Check Insert allowed', 130);
338: if l_rec.position_type = 'POOLED' then
339: hr_utility.set_location('Insert Validate:POOLED', 130);
340: if pqh_psf_bus.open_status(p_rec.position_id, p_rec.effective_start_date) = 'OPEN' then
341: null;
342: else
343: pqh_utility.set_message(8302,'PQH_POOLED_POS_NOT_OPEN',l_rec.organization_id);
344: pqh_utility.raise_error;

Line 349: if pqh_psf_bus.open_status(p_rec.position_id, p_rec.effective_start_date) = 'OPEN' then

345: end if;
346: hr_utility.set_location('Insert Validate:END POOLED', 130);
347: elsif l_rec.position_type = 'SINGLE' or l_rec.position_type = 'SHARED' then
348: hr_utility.set_location('Insert Validate:SINGLE-SHARED', 130);
349: if pqh_psf_bus.open_status(p_rec.position_id, p_rec.effective_start_date) = 'OPEN' then
350: hr_utility.set_location('Insert Validate:OPEN', 130);
351: if not l_bgt_lt_abv_fte then
352: hr_utility.set_location('p_rec.business_group_id : '||p_rec.business_group_id, 131);
353: if l_rec.position_type = 'SINGLE' then

Line 356: l_default_asg_fte := pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);

352: hr_utility.set_location('p_rec.business_group_id : '||p_rec.business_group_id, 131);
353: if l_rec.position_type = 'SINGLE' then
354: l_default_asg_fte := 1;
355: else
356: l_default_asg_fte := pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);
357: end if;
358: hr_utility.set_location('l_default_asg_fte : '||l_default_asg_fte, 13);
359: --
360: if chk_reserved_fte(p_rec.assignment_id, p_rec.person_id,

Line 365: pqh_psf_bus.reserved_error(p_rec.assignment_id,

361: p_rec.position_id, l_rec.position_type,
362: p_rec.effective_start_date,
363: p_rec.effective_end_date, -- Added for bug 10220040
364: l_default_asg_fte) then
365: pqh_psf_bus.reserved_error(p_rec.assignment_id,
366: p_rec.person_id,
367: p_rec.position_id,
368: p_rec.effective_start_date,
369: l_rec.organization_id,

Line 455: hr_utility.set_location('Entering Procedure PQH_PSF_BUS ', 100);

451: where position_id = p_position_id
452: and effective_start_date > p_effective_date;
453: --
454: BEGIN
455: hr_utility.set_location('Entering Procedure PQH_PSF_BUS ', 100);
456: hr_utility.set_location('p_validation_start_date '||p_validation_start_date, 101);
457: hr_utility.set_location('p_validation_end_date '||p_validation_end_date, 101);
458: hr_utility.set_location('p_effective_date '||p_effective_date, 101);
459: hr_utility.set_location('p_datetrack_mode '||p_datetrack_mode, 101);

Line 474: if not pqh_psf_bus.chk_seasonal_dates(

470: -- Check for Assignment attached to a Seasonal Position is with in seasonal dates
471: --
472: if p_rec.position_id <> nvl(l_asg.position_id, -999) then
473: if l_rec.seasonal_flag = 'Y' then
474: if not pqh_psf_bus.chk_seasonal_dates(
475: p_position_id => p_rec.position_id,
476: p_seasonal_flag => l_rec.seasonal_flag,
477: p_assignment_start_date => p_validation_start_date) then
478:

Line 522: --pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);

518: if (l_rec.position_type = 'SHARED') then
519: --
520: hr_utility.set_location('before l_overlap_dates_present ', 100);
521: l_default_asg_fte := null;
522: --pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);
523: --
524: pqh_psf_bus.CHK_ABV_FTE_GT_POS_BGT_FTE(
525: p_assignment_id => p_rec.assignment_id,
526: p_position_id => p_rec.position_id,

Line 524: pqh_psf_bus.CHK_ABV_FTE_GT_POS_BGT_FTE(

520: hr_utility.set_location('before l_overlap_dates_present ', 100);
521: l_default_asg_fte := null;
522: --pqh_psf_bus.default_assignment_fte(p_rec.business_group_id);
523: --
524: pqh_psf_bus.CHK_ABV_FTE_GT_POS_BGT_FTE(
525: p_assignment_id => p_rec.assignment_id,
526: p_position_id => p_rec.position_id,
527: p_effective_date => p_validation_start_date,
528: p_default_asg_fte => l_default_asg_fte,

Line 539: pqh_psf_bus.chk_future_pos_asg_fte(

535: end if;
536: --
537: if (not l_bgt_lt_abv_fte) and p_rec.assignment_type <> 'A' then -- fix for 10434560
538: hr_utility.set_location('l_default_asg_fte :'||l_default_asg_fte, 135);
539: pqh_psf_bus.chk_future_pos_asg_fte(
540: p_assignment_id => p_rec.assignment_id,
541: p_position_id => p_rec.position_id,
542: p_validation_start_date => p_validation_start_date,
543: -- Start changes for bug 10220040

Line 556: l_assignment_fte := pqh_psf_bus.assignment_fte(p_rec.assignment_id, p_validation_start_date);

552: if (l_rec.position_type = 'SHARED') then
553: --
554: hr_utility.set_location('before PQH_FTE_NE_SHARED_POS_FTE_CAP ', 100);
555: --
556: l_assignment_fte := pqh_psf_bus.assignment_fte(p_rec.assignment_id, p_validation_start_date);
557: if (l_rec.fte/l_rec.max_persons <> l_assignment_fte) then
558: pqh_utility.set_message(8302,'PQH_FTE_NE_SHARED_POS_FTE_CAP',l_rec.organization_id);
559: pqh_utility.raise_error;
560: end if;

Line 570: if pqh_psf_bus.open_status(l_rec.position_id, l_rec.effective_start_date) = 'OPEN' then

566: --
567: --Check Insert allowed..
568: --
569: if l_rec.position_type = 'POOLED' then
570: if pqh_psf_bus.open_status(l_rec.position_id, l_rec.effective_start_date) = 'OPEN' then
571: null;
572: else
573: pqh_utility.set_message(8302,'PQH_POOLED_POS_NOT_OPEN',l_rec.organization_id);
574: pqh_utility.raise_error;

Line 578: -- if pqh_psf_bus.open_status(l_rec.position_id, l_rec.effective_start_date) = 'OPEN' then -- Commented for Bug#13860076

574: pqh_utility.raise_error;
575: end if;
576: elsif l_rec.position_type = 'SINGLE' or l_rec.position_type = 'SHARED' then
577: hr_utility.set_location('SINGLE OR SHARED', 111);
578: -- if pqh_psf_bus.open_status(l_rec.position_id, l_rec.effective_start_date) = 'OPEN' then -- Commented for Bug#13860076
579: if pqh_psf_bus.open_status(l_rec.position_id, p_effective_date) = 'OPEN' then -- Added for Bug#13860076
580: hr_utility.set_location('OPEN', 112);
581: if not l_bgt_lt_abv_fte then
582: hr_utility.set_location('NOT l_bgt_lt_abv_fte ', 113);

Line 579: if pqh_psf_bus.open_status(l_rec.position_id, p_effective_date) = 'OPEN' then -- Added for Bug#13860076

575: end if;
576: elsif l_rec.position_type = 'SINGLE' or l_rec.position_type = 'SHARED' then
577: hr_utility.set_location('SINGLE OR SHARED', 111);
578: -- if pqh_psf_bus.open_status(l_rec.position_id, l_rec.effective_start_date) = 'OPEN' then -- Commented for Bug#13860076
579: if pqh_psf_bus.open_status(l_rec.position_id, p_effective_date) = 'OPEN' then -- Added for Bug#13860076
580: hr_utility.set_location('OPEN', 112);
581: if not l_bgt_lt_abv_fte then
582: hr_utility.set_location('NOT l_bgt_lt_abv_fte ', 113);
583: if chk_reserved_fte(p_rec.assignment_id, p_rec.person_id,

Line 588: pqh_psf_bus.reserved_error(p_rec.assignment_id,

584: p_rec.position_id, l_rec.position_type,
585: p_validation_start_date,
586: p_validation_end_date -- Added for bug 10220040
587: ) then
588: pqh_psf_bus.reserved_error(p_rec.assignment_id,
589: p_rec.person_id,
590: p_rec.position_id,
591: p_validation_start_date,
592: l_rec.organization_id);

Line 617: hr_utility.set_location('Exiting PQH_PSF_BUS', 130);

613: end if;
614: else
615: close c_position;
616: end if;
617: hr_utility.set_location('Exiting PQH_PSF_BUS', 130);
618: --
619: END;
620: --
621: -- ---------------------------------------------------------------------------

Line 712: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(

708: fetch c_position_fte into l_overlap_period,l_fte, l_organization_id;
709: close c_position_fte;
710: hr_utility.set_location('l_overlap_period : ' || l_overlap_period,51);
711: --
712: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(
713: p_position_id => l_position_id,
714: p_overlap_period => l_overlap_period,
715: p_assignment_start_date => p_validation_start_date,
716: p_assignment_end_date => p_validation_end_date,

Line 733: l_sum1 := pqh_psf_bus.sum_assignment_fte(l_position_id, r1.effective_start_date, p_rec.assignment_id);

729: ,p_business_group_id => r1.business_group_id
730: );
731: --
732: --
733: l_sum1 := pqh_psf_bus.sum_assignment_fte(l_position_id, r1.effective_start_date, p_rec.assignment_id);
734: l_sum2 := pqh_psf_bus.assignment_fte(p_rec.assignment_id, r1.effective_start_date);
735: l_sum := l_sum1 + l_sum2;
736: --
737: hr_utility.set_location('l_bdgt '||l_bdgt, 101);

Line 734: l_sum2 := pqh_psf_bus.assignment_fte(p_rec.assignment_id, r1.effective_start_date);

730: );
731: --
732: --
733: l_sum1 := pqh_psf_bus.sum_assignment_fte(l_position_id, r1.effective_start_date, p_rec.assignment_id);
734: l_sum2 := pqh_psf_bus.assignment_fte(p_rec.assignment_id, r1.effective_start_date);
735: l_sum := l_sum1 + l_sum2;
736: --
737: hr_utility.set_location('l_bdgt '||l_bdgt, 101);
738: hr_utility.set_location('l_fte '||l_fte, 101);

Line 845: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(

841: l_fte||' - '||l_max_persons ||' - '||l_position_type, 120);
842: --
843: --
844: if l_position_type in ('SINGLE', 'SHARED') then
845: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(
846: p_position_id => l_position_id,
847: p_overlap_period => l_overlap_period,
848: p_assignment_start_date => p_effective_date);
849: if not l_overlap_dates_present then

Line 853: l_sum_abv := pqh_psf_bus.sum_assignment_fte(l_position_id, p_effective_date);

849: if not l_overlap_dates_present then
850: --
851: --Validate Position Budget values with sum of Assignment Budget Values
852: --
853: l_sum_abv := pqh_psf_bus.sum_assignment_fte(l_position_id, p_effective_date);
854: --
855: l_pos_budget_fte := budgeted_fte(l_position_id, p_effective_date);
856: --
857: l_realloc := pqh_reallocation_pkg.get_reallocation(

Line 896: if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then

892: --
893: -- Check Reserved
894: --
895: hr_utility.set_location('Insert Validate:SINGLE-SHARED', 130);
896: if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then
897: hr_utility.set_location('Insert Validate:OPEN', 130);
898: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);
899: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);
900: if (nvl(p_value,0) > l_available_fte) then

Line 898: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);

894: --
895: hr_utility.set_location('Insert Validate:SINGLE-SHARED', 130);
896: if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then
897: hr_utility.set_location('Insert Validate:OPEN', 130);
898: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);
899: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);
900: if (nvl(p_value,0) > l_available_fte) then
901: pqh_psf_bus.reserved_error(p_assignment_id, l_person_id,
902: l_position_id,

Line 901: pqh_psf_bus.reserved_error(p_assignment_id, l_person_id,

897: hr_utility.set_location('Insert Validate:OPEN', 130);
898: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);
899: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);
900: if (nvl(p_value,0) > l_available_fte) then
901: pqh_psf_bus.reserved_error(p_assignment_id, l_person_id,
902: l_position_id,
903: p_effective_date,
904: l_organization_id);
905: end if;

Line 1010: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(

1006: hr_utility.set_location('c_positions found', 121);
1007: --
1008: if l_position_type in ('SINGLE', 'SHARED') then
1009: hr_utility.set_location('pos type SINGLE OR SHARED', 122);
1010: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(
1011: p_position_id => l_position_id,
1012: p_overlap_period => l_overlap_period,
1013: p_assignment_start_date => p_effective_date,
1014: p_assignment_end_date => p_validation_end_date,

Line 1072: --if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then

1068: -- Check Reserved
1069: --
1070: if (not l_abv_gt_fte) and (l_position_type = 'SHARED') then
1071: hr_utility.set_location('Insert Validate:SINGLE-SHARED', 130);
1072: --if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then
1073: hr_utility.set_location('Insert Validate:OPEN', 130);
1074: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);
1075: l_assignment_fte := nvl(pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date),0);
1076: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);

Line 1074: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);

1070: if (not l_abv_gt_fte) and (l_position_type = 'SHARED') then
1071: hr_utility.set_location('Insert Validate:SINGLE-SHARED', 130);
1072: --if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then
1073: hr_utility.set_location('Insert Validate:OPEN', 130);
1074: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);
1075: l_assignment_fte := nvl(pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date),0);
1076: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);
1077: hr_utility.set_location('l_assignment_fte : '||l_assignment_fte, 133);
1078: l_temp := l_available_fte + l_assignment_fte ;

Line 1075: l_assignment_fte := nvl(pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date),0);

1071: hr_utility.set_location('Insert Validate:SINGLE-SHARED', 130);
1072: --if pqh_psf_bus.open_status(l_position_id, p_effective_date) = 'OPEN' then
1073: hr_utility.set_location('Insert Validate:OPEN', 130);
1074: l_available_fte := pqh_psf_bus.available_fte(l_person_id, l_position_id, p_effective_date);
1075: l_assignment_fte := nvl(pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date),0);
1076: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);
1077: hr_utility.set_location('l_assignment_fte : '||l_assignment_fte, 133);
1078: l_temp := l_available_fte + l_assignment_fte ;
1079: if (nvl(p_value,0) > l_temp ) then

Line 1080: pqh_psf_bus.reserved_error(p_assignment_id, l_person_id,

1076: hr_utility.set_location('l_available_fte : '||l_available_fte, 131);
1077: hr_utility.set_location('l_assignment_fte : '||l_assignment_fte, 133);
1078: l_temp := l_available_fte + l_assignment_fte ;
1079: if (nvl(p_value,0) > l_temp ) then
1080: pqh_psf_bus.reserved_error(p_assignment_id, l_person_id,
1081: l_position_id,
1082: p_effective_date,
1083: l_organization_id);
1084:

Line 1627: l_fte := pqh_psf_bus.get_position_fte(p_position_id, p_effective_date);

1623: return(l_vacancy_status);
1624: else
1625: close C_ASSIGNMENTS;
1626: l_vacancy_status := 'FILLED';
1627: l_fte := pqh_psf_bus.get_position_fte(p_position_id, p_effective_date);
1628: l_sum_asg_fte := sum_assignment_fte(p_position_id, p_effective_date);
1629: hr_utility.set_location('l_fte' || l_fte,102);
1630: hr_utility.set_location('sum_asg_fte :' || l_sum_asg_fte,102);
1631: if l_fte is not null then

Line 1712: l_chk_overlap_dates := PQH_PSF_BUS.chk_overlap_dates(p_position_id => p_position_id

1708: function chk_overlap_dates
1709: (p_position_id in number, p_overlap_period number, p_assignment_start_date date) return boolean is
1710: l_chk_overlap_dates boolean;
1711: begin
1712: l_chk_overlap_dates := PQH_PSF_BUS.chk_overlap_dates(p_position_id => p_position_id
1713: ,p_overlap_period => p_overlap_period
1714: ,p_assignment_start_date => p_assignment_start_date
1715: ,p_assignment_end_date => to_date('31/12/4712','dd/mm/rrrr')
1716: ,p_assignment_id => null);

Line 1820: hr_utility.set_location('Entering: PQH_PSF_BUS.chk_overlap_dates', 10);

1816: hr_utility.set_location( '*** entering application assignment check',555);
1817: --
1818: -- Changes end for the bug 13571263
1819: --
1820: hr_utility.set_location('Entering: PQH_PSF_BUS.chk_overlap_dates', 10);
1821:
1822: if p_overlap_period is not null
1823: and p_position_id is not null and p_assignment_start_date is not null then
1824:

Line 1890: hr_utility.set_location('Leaving: PQH_PSF_BUS.chk_overlap_dates', 100);

1886: close c2; */
1887: -- End changes for bug 10220040
1888: end if;
1889:
1890: hr_utility.set_location('Leaving: PQH_PSF_BUS.chk_overlap_dates', 100);
1891:
1892: --
1893: -- Changes start for the bug 13571263
1894: --

Line 2929: l_pos_fte := pqh_psf_bus.get_position_fte(p_position_id, p_effective_date);

2925: hr_utility.set_location('inside unreserved_fte',10);
2926: if p_position_id is not null and p_effective_date is not null then
2927: --
2928: hr_utility.set_location('inside unreserved_fte',20);
2929: l_pos_fte := pqh_psf_bus.get_position_fte(p_position_id, p_effective_date);
2930: --
2931: hr_utility.set_location('inside unreserved_fte',30);
2932: open c1(p_position_id, p_effective_date);
2933: fetch c1 into l_fte;

Line 2953: l_person_fte := pqh_psf_bus.person_fte(p_person_id, p_position_id, p_effective_date, -1);

2949: l_uu_fte number := 0;
2950: l_person_fte number;
2951: l_reserved_fte number;
2952: begin
2953: l_person_fte := pqh_psf_bus.person_fte(p_person_id, p_position_id, p_effective_date, -1);
2954: l_reserved_fte := pqh_psf_bus.reserved_fte(p_person_id, p_position_id, p_effective_date);
2955: hr_utility.set_location('uu: l_person_fte : '||l_person_fte, 131);
2956: hr_utility.set_location('uu: l_reserved_fte : '||l_reserved_fte, 131);
2957: if l_reserved_fte>0 and l_person_fte - l_reserved_fte > 0then

Line 2954: l_reserved_fte := pqh_psf_bus.reserved_fte(p_person_id, p_position_id, p_effective_date);

2950: l_person_fte number;
2951: l_reserved_fte number;
2952: begin
2953: l_person_fte := pqh_psf_bus.person_fte(p_person_id, p_position_id, p_effective_date, -1);
2954: l_reserved_fte := pqh_psf_bus.reserved_fte(p_person_id, p_position_id, p_effective_date);
2955: hr_utility.set_location('uu: l_person_fte : '||l_person_fte, 131);
2956: hr_utility.set_location('uu: l_reserved_fte : '||l_reserved_fte, 131);
2957: if l_reserved_fte>0 and l_person_fte - l_reserved_fte > 0then
2958: l_uu_fte := l_person_fte - l_reserved_fte;

Line 3681: l_person_asg_fte := pqh_psf_bus.person_asg_fte(p_person_id, p_position_id, r1.effective_date);

3677: --
3678: l_reserved_fte := pos_reserved_fte(p_position_id, r1.effective_date, p_position_extra_info_id);
3679: l_nonreserved_asg_fte := nonreserved_asg_fte(p_position_id, r1.effective_date,
3680: p_position_extra_info_id, p_person_id);
3681: l_person_asg_fte := pqh_psf_bus.person_asg_fte(p_person_id, p_position_id, r1.effective_date);
3682: l_poei_fte := greatest(l_person_asg_fte, p_poei_fte);
3683: l_position_fte := pqh_psf_bus.position_fte(p_position_id, r1.effective_date);
3684: --
3685: l_total_fte := nvl(l_reserved_fte,0) + nvl(l_nonreserved_asg_fte,0) + l_poei_fte;

Line 3683: l_position_fte := pqh_psf_bus.position_fte(p_position_id, r1.effective_date);

3679: l_nonreserved_asg_fte := nonreserved_asg_fte(p_position_id, r1.effective_date,
3680: p_position_extra_info_id, p_person_id);
3681: l_person_asg_fte := pqh_psf_bus.person_asg_fte(p_person_id, p_position_id, r1.effective_date);
3682: l_poei_fte := greatest(l_person_asg_fte, p_poei_fte);
3683: l_position_fte := pqh_psf_bus.position_fte(p_position_id, r1.effective_date);
3684: --
3685: l_total_fte := nvl(l_reserved_fte,0) + nvl(l_nonreserved_asg_fte,0) + l_poei_fte;
3686: l_budgeted_fte := pqh_psf_bus.budgeted_fte(p_position_id, r1.effective_date);
3687: --

Line 3686: l_budgeted_fte := pqh_psf_bus.budgeted_fte(p_position_id, r1.effective_date);

3682: l_poei_fte := greatest(l_person_asg_fte, p_poei_fte);
3683: l_position_fte := pqh_psf_bus.position_fte(p_position_id, r1.effective_date);
3684: --
3685: l_total_fte := nvl(l_reserved_fte,0) + nvl(l_nonreserved_asg_fte,0) + l_poei_fte;
3686: l_budgeted_fte := pqh_psf_bus.budgeted_fte(p_position_id, r1.effective_date);
3687: --
3688: l_realloc_fte := pqh_reallocation_pkg.get_reallocation(
3689: p_position_id => p_position_id
3690: ,p_start_date => r1.effective_date

Line 3807: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(

3803: hr_utility.set_location(' l_business_group_id'||l_business_group_id , 50);
3804: --
3805: --
3806: if l_position_type in ('SHARED', 'SINGLE') then
3807: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(
3808: p_position_id => p_position_id,
3809: p_overlap_period => l_overlap_period,
3810: p_assignment_start_date => p_effective_date,
3811: p_assignment_end_date => p_effective_end_date,

Line 3826: l_available_fte := pqh_psf_bus.available_fte(p_person_id, p_position_id, p_effective_date);

3822: return false;
3823: else
3824: close c_pos_reserved;
3825: end if;
3826: l_available_fte := pqh_psf_bus.available_fte(p_person_id, p_position_id, p_effective_date);
3827: if l_position_type = 'SINGLE' then
3828: hr_utility.set_location('p_position_type is SINGLE ', 110);
3829: l_assignment_fte := 1;
3830: elsif p_assignment_id is not null then

Line 3832: l_assignment_fte := nvl(pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date),0

3828: hr_utility.set_location('p_position_type is SINGLE ', 110);
3829: l_assignment_fte := 1;
3830: elsif p_assignment_id is not null then
3831: hr_utility.set_location('p_assignment_id is not null ', 111);
3832: l_assignment_fte := nvl(pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date),0
3833: );
3834: else
3835: hr_utility.set_location('p_assignment_id is null and pos type SHARED', 112);
3836: l_assignment_fte := p_default_asg_fte;

Line 4027: PQH_PSF_BUS.chk_pos_fte_sum_asg_fte(

4023: p_position_fte out nocopy number,
4024: p_total_asg_fte out nocopy number) is
4025: begin
4026:
4027: PQH_PSF_BUS.chk_pos_fte_sum_asg_fte(
4028: p_assignment_id => p_assignment_id
4029: ,p_position_id => p_position_id
4030: ,p_effective_date => p_effective_date
4031: ,p_effective_end_date => to_date('31/12/4712','dd/mm/rrrr')

Line 4075: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(

4071: hr_utility.set_location('chk_pos_fte_sum_asg_fte p_position_type'||p_position_type , 20);
4072: --
4073: if p_position_type = 'SHARED' then
4074: --
4075: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(
4076: p_position_id => p_position_id,
4077: p_overlap_period => l_overlap_period,
4078: p_assignment_start_date => p_effective_date,
4079: p_assignment_end_date => p_effective_end_date,

Line 4098: p_total_asg_fte := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date) + p_default_asg_fte;

4094: --
4095: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_null' , 20);
4096: if p_assignment_id is null then
4097: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is null' , 20);
4098: p_total_asg_fte := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date) + p_default_asg_fte;
4099: else
4100: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is not null' , 20);
4101: l_sum := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date);
4102: l_asg := pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date);

Line 4101: l_sum := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date);

4097: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is null' , 20);
4098: p_total_asg_fte := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date) + p_default_asg_fte;
4099: else
4100: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is not null' , 20);
4101: l_sum := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date);
4102: l_asg := pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date);
4103: p_total_asg_fte := l_sum + l_asg;
4104: --
4105: hr_utility.set_location('chk_pos_fte_sum_asg_fte l_sum : '||l_sum, 20);

Line 4102: l_asg := pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date);

4098: p_total_asg_fte := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date) + p_default_asg_fte;
4099: else
4100: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is not null' , 20);
4101: l_sum := pqh_psf_bus.sum_assignment_fte(p_position_id, p_effective_date);
4102: l_asg := pqh_psf_bus.assignment_fte(p_assignment_id, p_effective_date);
4103: p_total_asg_fte := l_sum + l_asg;
4104: --
4105: hr_utility.set_location('chk_pos_fte_sum_asg_fte l_sum : '||l_sum, 20);
4106: hr_utility.set_location('chk_pos_fte_sum_asg_fte l_asg : '||l_asg, 20);

Line 4114: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(

4110: hr_utility.set_location('chk_pos_fte_sum_asg_fte end SHARED' , 20);
4111: end if;
4112: elsif p_position_type = 'SINGLE' then
4113: --
4114: l_overlap_dates_present := pqh_psf_bus.chk_overlap_dates(
4115: p_position_id => p_position_id,
4116: p_overlap_period => l_overlap_period,
4117: p_assignment_start_date => p_effective_date,
4118: p_assignment_end_date => p_effective_end_date,

Line 4126: p_total_asg_fte := pqh_psf_bus.no_assignments(p_position_id, p_effective_date) + 1;

4122: --
4123: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_null' , 20);
4124: if p_assignment_id is null then
4125: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is null' , 20);
4126: p_total_asg_fte := pqh_psf_bus.no_assignments(p_position_id, p_effective_date) + 1;
4127: else
4128: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is not null' , 20);
4129: l_sum := pqh_psf_bus.no_assignments(p_position_id, p_effective_date);
4130: l_asg := 1;

Line 4129: l_sum := pqh_psf_bus.no_assignments(p_position_id, p_effective_date);

4125: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is null' , 20);
4126: p_total_asg_fte := pqh_psf_bus.no_assignments(p_position_id, p_effective_date) + 1;
4127: else
4128: hr_utility.set_location('chk_pos_fte_sum_asg_fte before asg_is not null' , 20);
4129: l_sum := pqh_psf_bus.no_assignments(p_position_id, p_effective_date);
4130: l_asg := 1;
4131: p_total_asg_fte := l_sum + l_asg;
4132: --
4133: hr_utility.set_location('chk_pos_fte_sum_asg_fte l_sum : '||l_sum, 20);

Line 4395: pqh_psf_bus.chk_pos_fte_sum_asg_fte(

4391: l_sum number;
4392: l_bgt_realloc number;
4393: begin
4394: --
4395: pqh_psf_bus.chk_pos_fte_sum_asg_fte(
4396: p_assignment_id => p_assignment_id,
4397: p_position_id => p_position_id,
4398: p_effective_date => p_effective_date,
4399: p_default_asg_fte => p_default_asg_fte,

Line 4454: l_budgeted_fte := pqh_psf_bus.budgeted_fte(p_position_id, p_effective_date);

4450: open c2(p_position_id, p_effective_date);
4451: fetch c2 into l_pos_fte, l_business_group_id;
4452: close c2;
4453: --
4454: l_budgeted_fte := pqh_psf_bus.budgeted_fte(p_position_id, p_effective_date);
4455: --
4456: --
4457: l_realloc_fte := pqh_reallocation_pkg.get_reallocation(
4458: p_position_id => p_position_id

Line 4854: l_proc varchar2(72) := 'pqh_psf_bus.chk_position_budget';

4850: l_salary_element_type_id number;
4851: l_salary_input_value_id number;
4852: --
4853: l_message_level varchar2(10);
4854: l_proc varchar2(72) := 'pqh_psf_bus.chk_position_budget';
4855: begin
4856: --
4857: hr_utility.set_location(l_proc||'Entering',1);
4858: get_assignment_info(p_assignment_id, p_effective_date, l_asg_position_id, l_asg_organization_id);

Line 5041: end PQH_PSF_BUS;

5037: hr_utility.set_location(substr(sqlerrm,1,120),13);
5038: raise;
5039: end;
5040:
5041: end PQH_PSF_BUS;