SELECT person_id,
title,
first_name,
middle_names,
last_name,
Decode(sex,'M', 'Male','F','Female','NA') Gender,
date_of_birth,
Decode(marital_status,'M', 'Married','S', 'Single') Marital_Status,
nationality,
national_identifier,
resume_exists,
email_address,
town_of_birth,
business_group_id,
employee_number,
full_name,
original_date_of_hire,
party_id
FROM per_all_people_f prf
WHERE 1 = 1
AND TRUNC (SYSDATE) BETWEEN prf.effective_start_date
AND prf.effective_end_date;