20: CURSOR get_period( p_id IN NUMBER)
21: IS SELECT ptp.start_date,
22: ptp.end_date,
23: tim.for_person_id
24: FROM hxt_timecards_f tim,
25: per_time_periods ptp
26: WHERE tim.id = p_id
27: AND tim.time_period_id = ptp.time_period_id ;
28:
876: CURSOR weekly_total(session_date DATE)
877: IS
878: SELECT NVL (SUM (hrw.hours), 0)
879: FROM hxt_det_hours_worked_f hrw,
880: hxt_timecards_f tim,
881: hxt_earn_groups erg,
882: hxt_earn_group_types egt,
883: hxt_earning_policies erp
884: WHERE tim.for_person_id = a_for_person_id
904:
905: -- Bug 11837942
906: -- Added this new cursor mimicking the above one, but with two
907: -- tim_ids, the current and previous one as params. The Query now
908: -- drives from hxt_timecards_f with PK index.
909:
910: CURSOR weekly_total2(session_date DATE,
911: p_tim_id IN NUMBER,
912: p_prev_id IN NUMBER)
912: p_prev_id IN NUMBER)
913: IS
914: SELECT NVL (SUM (hrw.hours), 0)
915: FROM hxt_det_hours_worked_f hrw,
916: hxt_timecards_f tim,
917: hxt_earn_groups erg,
918: hxt_earn_group_types egt,
919: hxt_earning_policies erp
920: WHERE tim.id IN (p_tim_id, p_prev_id)
1088: CURSOR weekly_total(session_date DATE)
1089: IS
1090: SELECT NVL (SUM (hrw.hours), 0)
1091: FROM hxt_det_hours_worked_f hrw, --C421
1092: hxt_timecards_f tim,
1093: hxt_earn_groups erg,
1094: hxt_earn_group_types egt,
1095: hxt_earning_policies erp
1096: WHERE tim.for_person_id = a_for_person_id
1115:
1116: -- Bug 11837942
1117: -- Added this new cursor mimicking the above one, but with two
1118: -- tim_ids, the current and previous one as params. The Query now
1119: -- drives from hxt_timecards_f with PK index.
1120:
1121: CURSOR weekly_total2(session_date DATE,
1122: p_tim_id IN NUMBER,
1123: p_prev_id IN NUMBER)
1123: p_prev_id IN NUMBER)
1124: IS
1125: SELECT NVL (SUM (hrw.hours), 0)
1126: FROM hxt_det_hours_worked_f hrw,
1127: hxt_timecards_f tim,
1128: hxt_earn_groups erg,
1129: hxt_earn_group_types egt,
1130: hxt_earning_policies erp
1131: WHERE tim.id IN (p_tim_id, p_prev_id)