MAR_STAT_CHG_VW(SQL View) |
Index Back |
---|---|
Marital Status ChangesThis view selects all records out of PERS_DATA_EFFDT where a change of the marital status occurred. |
SELECT PD1.EMPLID , PD1.EFFDT , PD1.MAR_STATUS FROM PS_PERS_DATA_EFFDT PD1 WHERE NOT EXISTS ( SELECT 'X' FROM PS_PERS_DATA_EFFDT PD2 WHERE PD2.EMPLID = PD1.EMPLID AND PD2.EFFDT = ( SELECT MAX(EFFDT) FROM PS_PERS_DATA_EFFDT PD3 WHERE PD3.EMPLID = PD1.EMPLID AND PD3.EFFDT < PD1.EFFDT ) AND PD2.MAR_STATUS = PD1.MAR_STATUS ) |
# | PeopleSoft Field Name | PeopleSoft Field Type | Database Column Type | Description |
---|---|---|---|---|
1 | EMPLID | Character(11) | VARCHAR2(11) NOT NULL | Employee ID |
2 | EFFDT | Date(10) | DATE |
Effective Date
Default Value: %date |
3 | MAR_STATUS | Character(1) | VARCHAR2(1) NOT NULL |
Marital Status
C=Common-Law D=Divorced E=Separated H=Head of Household L=DissDeclLost Civil Partner M=Married P=Civil Partnership S=Single T=Surviving Civil Partner U=Unknown V=Dissolved Civil Partnership W=Widowed |