select pap.
person_number
,ppn.full_name
,pj.name
,pea.email_address
from per_all_people_f pap
,per_person_names_f ppn
,per_all_assignments_m paa
,per_jobs pj
,per_email_addresses pea
where pap.person_id = ppn.person_id
and ppn.person_id = paa.person_id
and pj.job_id = paa.job_id
and pap.PRIMARY_EMAIL_ID = pea.email_address_id
and (ppn.full_name IN ('Sharma, Amit','Sharma, Vijay')
OR (pj.name = 'CON' OR pj.name ='Contractor')
)
select pcc_tl.class_code
from PJF_CLASS_CATEGORIES_B ppc_b
,PJF_CLASS_CATEGORIES_TL ppc_tl
,PJF_CLASS_CODES_B pcc_b
,PJF_CLASS_CODES_TL pcc_tl
where pcc_b.CLASS_CATEGORY_ID = ppc_b.CLASS_CATEGORY_ID
and ppc_b.CLASS_CATEGORY_ID = ppc_tl.CLASS_CATEGORY_ID
and ppc_tl.CLASS_CATEGORY = 'Approval Type'
and pcc_b.class_code_id = pcc_tl.class_code_id
and rownum=1