GPFR_RSLT_EO_VW

(SQL View)
Index Back

Result view: Ern/Ded Old

Result Table for earnings and deductions and deltas. View for the old calculation

SELECT 'RETRO' , G.EMPLID , G.EMPL_RCD , G.CAL_RUN_ID , G.GP_PAYGROUP , G.CAL_ID , G.ORIG_CAL_RUN_ID , G.RSLT_SEG_NUM , G.PYMT_KEY1 , G.PYMT_KEY2 , G.PYMT_KEY3 , G.PYMT_KEY4 , G.CALC_ACTION , G.PRD_TYPE , G.CURRENCY_CD , C.CURRENCY_CD , B.CAL_RUN_ID , B.CAL_ID , B.RSLT_SEG_NUM , A.RSLT_VER_NUM , A.RSLT_REV_NUM , DL.PIN_RTO_ADJ_NUM , B.INSTANCE , B.USER_FLD1 , B.USER_FLD2 , B.USER_FLD3 , B.USER_FLD4 , B.USER_FLD5 , B.USER_FLD6 , B.SLICE_BGN_DT , B.SLICE_END_DT , %DecMult(B.CALC_RSLT_VAL,-1) , %DecMult(B.BASE_RSLT_VAL,-1) , B.RATE_RSLT_VAL , %DecMult(B.UNIT_RSLT_VAL,-1) , B.PCT_RSLT_VAL FROM PS_GP_PYE_SEG_STAT A , PS_GP_PYE_PRC_STAT C , PS_GP_PYE_PRC_STAT C2 , PS_GP_RSLT_ERN_DED B , PS_GP_RSLT_DELTA DL , PS_GPFR_GUIDE_VW G WHERE A.EMPLID = B.EMPLID AND A.EMPL_RCD = B.EMPL_RCD AND A.CAL_RUN_ID = B.CAL_RUN_ID AND A.GP_PAYGROUP = B.GP_PAYGROUP AND A.CAL_ID = B.CAL_ID AND A.ORIG_CAL_RUN_ID = B.ORIG_CAL_RUN_ID AND A.RSLT_SEG_NUM= B.RSLT_SEG_NUM AND A.EMPLID = C2.EMPLID AND A.EMPL_RCD = C2.EMPL_RCD AND A.CAL_RUN_ID = C2.CAL_RUN_ID AND A.GP_PAYGROUP = C2.GP_PAYGROUP AND A.CAL_ID = C2.CAL_ID AND A.ORIG_CAL_RUN_ID = C2.ORIG_CAL_RUN_ID AND A.EMPLID = C.EMPLID AND A.EMPL_RCD = C.EMPL_RCD AND A.GP_PAYGROUP = C.GP_PAYGROUP AND A.CAL_ID = C.CAL_ID AND A.CALC_ACTION <> 'V' AND C.PRD_TYPE = 'R' AND C.CALC_TYPE = 'P' AND C.ORIG_CAL_RUN_ID = C2.ORIG_CAL_RUN_ID AND C.PRIOR_VER_NUM = C2.RSLT_VER_NUM AND C.PRIOR_REV_NUM = C2.RSLT_REV_NUM AND C.EMPLID = G.EMPLID AND C.CAL_RUN_ID = G.CAL_RUN_ID AND C.EMPL_RCD = G.EMPL_RCD AND C.GP_PAYGROUP = G.GP_PAYGROUP AND G.PYMT_KEY1 = A.PYMT_KEY1 AND G.PYMT_KEY2 = A.PYMT_KEY2 AND G.PYMT_KEY3 = A.PYMT_KEY3 AND G.PYMT_KEY4 = A.PYMT_KEY4 AND G.RSLT_SEG_NUM= ( SELECT MIN(G2.RSLT_SEG_NUM) FROM PS_GPFR_GUIDE_VW G2 WHERE G2.EMPLID = G.EMPLID AND G2.CAL_RUN_ID = G.CAL_RUN_ID AND G2.EMPL_RCD = G.EMPL_RCD AND G2.GP_PAYGROUP = G.GP_PAYGROUP AND G2.PYMT_KEY1 = G.PYMT_KEY1 AND G2.PYMT_KEY2 = G.PYMT_KEY2 AND G2.PYMT_KEY3 = G.PYMT_KEY3 AND G2.PYMT_KEY4 = G.PYMT_KEY4 ) AND DL.EMPLID = A.EMPLID AND DL.EMPL_RCD = A.EMPL_RCD AND DL.PYMT_KEY1 = A.PYMT_KEY1 AND DL.PYMT_KEY2 = A.PYMT_KEY2 AND DL.PYMT_KEY3 = A.PYMT_KEY3 AND DL.PYMT_KEY4 = A.PYMT_KEY4 AND DL.PIN_NUM = B.PIN_NUM AND DL.RSLT_SEG_NUM = A.RSLT_SEG_NUM AND ((DL.REPLACE_IND = 'Y' AND DL.CAL_RUN_ID = C.CAL_RUN_ID AND DL.GP_PAYGROUP = C.GP_PAYGROUP AND DL.CAL_ID = C.CAL_ID) OR (DL.FORWARD_IND = 'Y' AND DL.FWD2_CAL_RUN_ID = G.CAL_RUN_ID AND DL.FWD2_PAYGROUP = G.GP_PAYGROUP AND DL.FWD2_CAL_ID = G.CAL_ID AND DL.CAL_ID = A.CAL_ID))

# PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
1 DESCR15 Character(15) VARCHAR2(15) NOT NULL Short Description
2 EMPLID Character(11) VARCHAR2(11) NOT NULL Employee ID
3 EMPL_RCD Number(3,0) SMALLINT NOT NULL Empl Record
4 CAL_RUN_ID Character(18) VARCHAR2(18) NOT NULL Calendar Run Id
5 GP_PAYGROUP Character(10) VARCHAR2(10) NOT NULL Global Payroll pay group
6 CAL_ID Character(18) VARCHAR2(18) NOT NULL calendar id
7 ORIG_CAL_RUN_ID Character(18) VARCHAR2(18) NOT NULL Original Calendar Group ID
8 RSLT_SEG_NUM Number(4,0) SMALLINT NOT NULL Result Segment Number
9 PYMT_KEY1 Character(25) VARCHAR2(25) NOT NULL Payment key field. Used for optional tracking of a payment per Department, Company, Establishment or Contract Number
10 PYMT_KEY2 Character(25) VARCHAR2(25) NOT NULL Payment key field. Used for optional tracking of a payment per Department, Company, Establishment or Contract Number
11 PYMT_KEY3 Character(25) VARCHAR2(25) NOT NULL Payment key field. Used for optional tracking of a payment per Department, Company, Establishment or Contract Number
12 PYMT_KEY4 Character(25) VARCHAR2(25) NOT NULL Payment key field. Used for optional tracking of a payment per Department, Company, Establishment or Contract Number
13 CALC_ACTION Character(1) VARCHAR2(1) NOT NULL Calculate Action
C=Calculate
R=Calculate and Replace
V=Reverse
W=Reverse and Replace
14 PRD_TYPE Character(1) VARCHAR2(1) NOT NULL Period Type
C=Current
R=Retro
15 CURRENCY_CD Character(3) VARCHAR2(3) NOT NULL Currency Code
16 CURRENCY_CD2 Character(3) VARCHAR2(3) NOT NULL Currency Code
17 SRC_CAL_RUN_ID Character(18) VARCHAR2(18) NOT NULL Source Calendar Run ID
18 SRC_CAL_ID Character(18) VARCHAR2(18) NOT NULL Source Calendar ID
19 RSLT_SEG_NUM2 Number(4,0) SMALLINT NOT NULL Copy of field RSLT_SEG_NUM used when multiple segment (payment) numbers are needed joined into a single view
20 RSLT_VER_NUM Number(4,0) SMALLINT NOT NULL Result Version Number
21 RSLT_REV_NUM Number(4,0) SMALLINT NOT NULL Result Revision Number
22 PIN_NUM Number(8,0) INTEGER NOT NULL PIN Number
23 INSTANCE Number(3,0) SMALLINT NOT NULL Instance Number
24 USER_FLD1 Character(25) VARCHAR2(25) NOT NULL User Field 1
25 USER_FLD2 Character(25) VARCHAR2(25) NOT NULL User Field 2
26 USER_FLD3 Character(25) VARCHAR2(25) NOT NULL User Field 3
27 USER_FLD4 Character(25) VARCHAR2(25) NOT NULL User Field 4
28 USER_FLD5 Character(25) VARCHAR2(25) NOT NULL User FIeld 5
29 USER_FLD6 Character(25) VARCHAR2(25) NOT NULL User Field 6
30 SLICE_BGN_DT Date(10) DATE Element Slice Begin Date
31 SLICE_END_DT Date(10) DATE Element Slice End Date
32 CALC_RSLT_VAL Signed Number(20,6) DECIMAL(18,6) NOT NULL Calculation Numeric Result
33 BASE_RSLT_VAL Signed Number(20,6) DECIMAL(18,6) NOT NULL Calculated Base Value
34 RATE_RSLT_VAL Signed Number(20,6) DECIMAL(18,6) NOT NULL Rate Result Value
35 UNIT_RSLT_VAL Signed Number(20,6) DECIMAL(18,6) NOT NULL Number of units used in result calculation
36 PCT_RSLT_VAL Signed Number(20,6) DECIMAL(18,6) NOT NULL Percent Result Value