PRIM_PAYGRP1_VW

(SQL View)
Index Back

View with primary paygroups

This view is used as a Primary Paygroup lookup on Payroll Data page

SELECT A.EMPLID , A.COMPANY , A.EMPL_RCD , A.EFFDT , A.PAYGROUP FROM PS_PRIM_PAYGRP0_VW A WHERE A.EFFDT = ( SELECT MIN(A1.EFFDT) FROM PS_PRIM_PAYGRP0_VW A1 WHERE A1.EMPLID = A.EMPLID AND A1.EMPL_RCD = A.EMPL_RCD AND A1.COMPANY = A.COMPANY) UNION SELECT B.EMPLID , B.COMPANY , B.EMPL_RCD , B.EFFDT , B.PAYGROUP FROM PS_JOB B WHERE B.EFFDT = ( SELECT MAX(B1.EFFDT) FROM PS_JOB B1 WHERE B1.EMPLID = B.EMPLID AND B1.EMPL_RCD = B.EMPL_RCD AND B1.COMPANY = B.COMPANY AND B1.EFFDT <= %CurrentDateIn) AND B.EFFSEQ = ( SELECT MAX(B2.EFFSEQ) FROM PS_JOB B2 WHERE B2.EMPLID = B.EMPLID AND B2.EMPL_RCD = B.EMPL_RCD AND B2.EFFDT = B.EFFDT AND B2.COMPANY = B.COMPANY)

# PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
1 EMPLID Character(11) VARCHAR2(11) NOT NULL Employee ID
2 COMPANY Character(3) VARCHAR2(3) NOT NULL Company
3 EMPL_RCD Number(3,0) SMALLINT NOT NULL Empl Record
4 PY_DISPLAY_DATE Date(10) DATE Field to display effective date
5 PAYGROUP Character(3) VARCHAR2(3) NOT NULL Pay Group