SELECT RL.HRS_JOB_OPENING_ID , RL.LANGUAGE_CD , RL.HRS_PRM_PST_TITLE , XL.XLATLONGNAME , COALESCE(( SELECT NML.NAME_DISPLAY FROM PS_HRS_PERSON_NM_L NML WHERE NML.EMPLID = J.RECRUITER_ID AND NML.LANGUAGE_CD = RL.LANGUAGE_CD),( SELECT NM.NAME_DISPLAY FROM PS_HRS_PERSON_NM_I NM WHERE NM.EMPLID = J.RECRUITER_ID)) , COALESCE(( SELECT NML.NAME_DISPLAY FROM PS_HRS_PERSON_NM_L NML WHERE NML.EMPLID = J.MANAGER_ID AND NML.LANGUAGE_CD = RL.LANGUAGE_CD),( SELECT NM.NAME_DISPLAY FROM PS_HRS_PERSON_NM_I NM WHERE NM.EMPLID = J.MANAGER_ID)) FROM PS_HRS_JOB_OPENING J , PS_HRS_JO_LNG RL , PSXLATITEM X , PSXLATITEMLANG XL WHERE RL.HRS_JOB_OPENING_ID = J.HRS_JOB_OPENING_ID AND X.FIELDNAME = 'HRS_JO_TYPE' AND X.FIELDVALUE = J.HRS_JO_TYPE AND XL.FIELDNAME = X.FIELDNAME AND XL.FIELDVALUE = X.FIELDVALUE AND XL.LANGUAGE_CD = RL.LANGUAGE_CD AND X.EFFDT = ( SELECT MAX(X2.EFFDT) FROM PSXLATITEM X2 WHERE X2.FIELDNAME = X.FIELDNAME AND X2.FIELDVALUE = X.FIELDVALUE AND X2.EFFDT <= %CurrentDateIn) AND X.EFF_STATUS = 'A'
|