Oracle EBS Employee Table and HRMS Tables: Date-Tracked SQL Generator
The Oracle EBS employee table is PER_ALL_PEOPLE_F, but a plain select returns every historic version of every person. This generator builds the join to assignments, organization, job and supervisor with the date-track filter applied to each table.
Fill in
Use TRUNC(SYSDATE) for today, or TO_DATE('2026-03-31','YYYY-MM-DD') for a past date.
BUSINESS_GROUP_ID from HR_ALL_ORGANIZATION_UNITS. 202 is the Vision demo value.
Use % for everyone or SMITH% for a prefix.
Current employees with assignment, organization, job and supervisor
SELECT p.person_id,
p.employee_number,
p.full_name,
p.email_address,
a.assignment_id,
a.assignment_number,
o.name AS organization,
j.name AS job,
s.full_name AS supervisor,
p.effective_start_date AS person_from,
a.effective_start_date AS assignment_from
FROM per_all_people_f p
JOIN per_all_assignments_f a
ON a.person_id = p.person_id
AND a.assignment_type = 'E'
AND a.primary_flag = 'Y'
AND TRUNC(SYSDATE) BETWEEN a.effective_start_date AND a.effective_end_date
LEFT JOIN hr_all_organization_units o
ON o.organization_id = a.organization_id
LEFT JOIN per_jobs_vl j
ON j.job_id = a.job_id
LEFT JOIN per_all_people_f s
ON s.person_id = a.supervisor_id
AND TRUNC(SYSDATE) BETWEEN s.effective_start_date AND s.effective_end_date
WHERE p.business_group_id = 202
AND p.current_employee_flag = 'Y'
AND p.last_name LIKE UPPER('%')
AND TRUNC(SYSDATE) BETWEEN p.effective_start_date AND p.effective_end_date
ORDER BY p.full_name
FETCH FIRST 200 ROWS ONLY;Full history of one person (all date-tracked rows)
SELECT person_id, employee_number, last_name, first_name,
effective_start_date, effective_end_date
FROM per_all_people_f
WHERE person_id = :person_id
ORDER BY effective_start_date;Link an application user to the employee record
SELECT u.user_name, u.employee_id AS person_id, p.full_name
FROM fnd_user u
JOIN per_all_people_f p
ON p.person_id = u.employee_id
AND TRUNC(SYSDATE) BETWEEN p.effective_start_date AND p.effective_end_date
WHERE u.end_date IS NULL OR u.end_date > TRUNC(SYSDATE);Verify names against your release in the eTRM. FETCH FIRST needs Oracle Database 12c or later; on 11g use ROWNUM. Last name values are stored in upper or mixed case depending on setup. Run against a non-production copy first and respect HR data access rules.
Ask HR and approval-chain questions in plain English
Optional: a private AI layer that turns questions into reviewed read-only EBS queries.
Optional. The tool and every export work without this. No spam.
How to use the generator
Set the as-of date, business group and an optional last name filter, then copy the query into SQL Developer or TOAD. The as-of expression is reused in every date-tracked join, which is the part people most often forget. Leave it as TRUNC(SYSDATE) for current data, or enter a past date to see who worked where at that time. The second and third blocks show the full history of a person and the link between FND_USER and the employee.
The core HRMS tables
People live in PER_ALL_PEOPLE_F (one row per person per date range, key PERSON_ID plus EFFECTIVE_START_DATE). Jobs and positions of work are in PER_ALL_ASSIGNMENTS_F, which holds ORGANIZATION_ID, JOB_ID, POSITION_ID, LOCATION_ID, GRADE_ID and SUPERVISOR_ID. Employment spans are in PER_PERIODS_OF_SERVICE. Reference tables include HR_ALL_ORGANIZATION_UNITS, PER_JOBS, HR_ALL_POSITIONS_F, HR_LOCATIONS_ALL, PER_ADDRESSES and PER_PHONES.
- PER_ALL_PEOPLE_F: person, name, employee number, email
- PER_ALL_ASSIGNMENTS_F: organization, job, position, supervisor
- PER_PERIODS_OF_SERVICE: hire and termination dates
- FND_USER.EMPLOYEE_ID: links a login to PERSON_ID
Date-track patterns that avoid duplicates
A date-tracked table keeps one row for each period a version of the data was true. Any join to it needs a filter such as the as-of date between EFFECTIVE_START_DATE and EFFECTIVE_END_DATE. Without it, a person with five name or assignment changes appears five times. Also filter ASSIGNMENT_TYPE = 'E' and PRIMARY_FLAG = 'Y' to avoid contingent worker and secondary assignment rows, and use CURRENT_EMPLOYEE_FLAG for active employees.
Common mistakes
Using the unsuffixed PER_PEOPLE_F or PER_ASSIGNMENTS_F views without knowing they depend on session date and business group. Joining supervisor with no date filter. Treating EMPLOYEE_NUMBER as unique across business groups. Reading personal data without the access controls your HR team requires. Counting rows from PER_ALL_PEOPLE_F as headcount, which includes ex-employees, applicants and contingent workers.
Frequently Asked Questions
What is the employee table in Oracle EBS?
PER_ALL_PEOPLE_F holds people, including employees, ex-employees, applicants and contingent workers. Employment details such as organization, job and supervisor are in PER_ALL_ASSIGNMENTS_F. Both are date-tracked, so every query needs an effective date filter.
Why do I get duplicate employees in my query?
Because date-tracked tables keep a row for every historic version. Add AS-OF BETWEEN EFFECTIVE_START_DATE AND EFFECTIVE_END_DATE to each date-tracked table in the join, and restrict assignments to the primary employee assignment.
How do I link an EBS user to an employee?
FND_USER.EMPLOYEE_ID stores the PERSON_ID of the linked person. Join it to PER_ALL_PEOPLE_F with the date filter. Some users, such as service accounts, have no employee link, so use a left join if you need all users.
Does this work for contingent workers?
Not directly. Contingent workers use assignment type C and the current npw flag instead of current employee flag. Change the assignment type and flag in the where clause to report on them, subject to your HR data rules.
If HR and operations teams keep asking IT for the same employee and approval-chain reports, a private AI layer over EBS can answer them on your own servers while honoring existing access roles.
Related Tools
Oracle EBS ER Diagram: Key Table Relationships
Parent and child table pairs with the exact join columns for the Oracle EBS purchasing, WIP, BOM, routing and inventory data models.
OracleOracle EBS User Access Review Template
A periodic access review record for EBS users and responsibilities, with scope, evidence, exceptions and reviewer sign-off.
OracleOracle EBS User and Responsibility Audit SQL Generator
Fill in a user and responsibility pattern and get ready-to-run queries for active user access, administrator access and duplicate access reviews.
OracleOracle EBS Customer and Supplier Tables Reference
Searchable list of the Trading Community Architecture customer tables and the supplier tables in Oracle EBS, with keys, join columns and where to confirm in the eTRM.
More Oracle tools
See all- Oracle EBS Inventory Tables Reference
- Oracle EBS WIP Tables Reference
- Oracle EBS Cycle Count Workload Calculator
- Oracle EBS Discrete Manufacturing Go-Live Checklist
- Oracle EBS Inventory Accuracy Readiness Assessment
- Oracle EBS Concurrent Request Phase and Status Reference
- Oracle EBS Responsibility Design Worksheet
- Oracle EBS GL Period Close Checklist
- Oracle EBS AP Invoice Interface Template
Keep exploring
Free tools
- Oracle EBS HR API List (HRMS Public APIs)A searchable reference of common Oracle EBS HRMS public API packages with their purpose, key parameters and notes, plus a PL/SQL call example.
- Oracle EBS Employee, HR and Projects Tables ReferenceLookup of the EBS base tables for employees, assignments, organizations and Oracle Projects, with the key columns and joins you need for reports.
- Oracle EBS SQL Query Generator for Items and WIP JobsBuild ready-to-run SELECT statements over MTL_SYSTEM_ITEMS_B, WIP_DISCRETE_JOBS and on-hand quantity tables.
ERP fixes and how-tos
- Oracle EBS Query for a Vendor Extract ReportSQL for an Oracle EBS R12 supplier extract: AP_SUPPLIERS, AP_SUPPLIER_SITES_ALL, contacts and bank accounts via IBY tables, with joins and security notes.
- Oracle Work Order Tables: WIP_ENTITIES, WIP_DISCRETE_JOBS and the REST RouteOracle work order tables explained: WIP_ENTITIES, WIP_DISCRETE_JOBS, operations and requirements, with a join query for EBS and the Fusion REST route.
- How to Create an Item in Oracle EBSCreate an inventory item in Oracle EBS: Master Items form, master organization, templates, attributes, organization assignment, categories and common errors.
Runs with your ERP
- Esker Order Management and Oracle E-Business SuiteHow Esker captures customer POs from email, fax and PDF and creates sales orders in Oracle EBS: integration, data flows, setup, pitfalls and a private AI layer.
- Cloud Inventory (DSI) with Oracle E-Business Suite: Mobile Barcode InventoryCloud Inventory, formerly DSI, adds offline mobile barcode inventory to Oracle E-Business Suite and JD Edwards. Data flows, setup steps, pitfalls and AI notes.
- BarTender and Oracle E-Business Suite: Label Printing from OracleHow BarTender prints labels from Oracle EBS using Oracle XML print requests and Integration Builder: methods, data flows, setup steps, pitfalls and AI help.
AI on your ERP
- AI for Oracle E-Business Suite, Without Leaving On-PremHosting Oracle EBS 12.2 on-prem or in a private cloud? Add a private LLM over concurrent programs, interface tables and AP/PO data without moving to Fusion.
- AI for Oracle E-Business Suite Procure to Pay, From Requisition to PaymentAdd grounded AI to Oracle E-Business Suite procure to pay: requisitions, POs, receiving and Payables invoices, with on-prem models and read-only access.
Integrations
- How to use ChatGPT with Oracle E-Business SuiteUsing ChatGPT with Oracle E-Business Suite: export vs live access, custom GPT actions over ISG REST, enterprise data controls and when to keep data on-prem.
- How to connect Power BI to Oracle E-Business SuiteConnect Power BI to Oracle E-Business Suite: Oracle connector, reporting replica, on-premises data gateway, manufacturing dashboards and natural-language Q&A.