AV_PE_RELATE_VW

(SQL View)
Index Back

Person/Org Relationship

Relate Display view providing the first relationship between an individual and an organization.

SELECT A.EMPLID, A.EXT_ORG_ID, A.PE_RELATION, B.PE_REL_DESCR, B.EP_REL_DESCR FROM PS_AV_RELATE_PE A, PS_AV_PE_RLTN_TBL B WHERE A.PE_RELATION=B.PE_RELATION AND B.EFFDT IN (SELECT MIN(B1.EFFDT) FROM PS_AV_PE_RLTN_TBL B1 WHERE B1.PE_RELATION=B.PE_RELATION) AND B.EFF_STATUS='A' AND A.PE_RELATE_NBR IN ( SELECT MIN(A1.PE_RELATE_NBR ) FROM PS_AV_RELATE_PE A1 WHERE A1.EMPLID=A.EMPLID AND A1.EXT_ORG_ID= A.EXT_ORG_ID)

# PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
1 AV_EMPLID Character(11) VARCHAR2(11) NOT NULL EmplID
2 AV_EXT_ORG_ID Character(11) VARCHAR2(11) NOT NULL External Org ID
3 PE_RELATION Character(2) VARCHAR2(2) NOT NULL Relationship
4 PE_REL_DESCR Character(30) VARCHAR2(30) NOT NULL Person Description
5 EP_REL_DESCR Character(30) VARCHAR2(30) NOT NULL Org Description