2160: bdri.resource_id as resource_id
2161: from bom_dept_res_instances bdri,
2162: bom_departments bd,
2163: bom_resource_employees bre,
2164: per_people_f ppf
2165: where bdri.instance_id = bre.instance_id
2166: and ppf.person_id = bre.person_id
2167: and bd.department_id = bdri.department_id
2168: and sysdate >= ppf.effective_start_date
2177: from bom_dept_res_instances bdri,
2178: bom_departments bd,
2179: bom_resource_employees bre,
2180: bom_department_resources bdr,
2181: per_people_f ppf
2182: where bdri.instance_id = bre.instance_id
2183: and ppf.person_id = bre.person_id
2184: and sysdate >= ppf.effective_start_date and sysdate <= ppf.effective_end_date
2185: and bd.department_id = bdr.department_id