SELECT DISTINCT C1.LM_CI_ID , CL1.LANGUAGE_CD , CL1.LM_CS_LONG_NM , CL1.LM_CS_DESCR , DL1.LM_DM_LONG_NM FROM PS_LM_ACT A1 , PS_LM_CI_TBL C1 , PS_LM_CI_LANG CL1 , PS_LM_DMTH_TYP_TBL D1 , PS_LM_DMTH_TYP_LNG DL1 WHERE A1.LM_CI_ID = C1.LM_CI_ID AND A1.LM_DMTHD_TYPE_ID = D1.LM_DMTHD_TYPE_ID AND A1.LM_ACT_STATUS = '3' AND %CurrentDateIn BETWEEN C1.EFFDT AND C1.LM_END_EFFDT AND C1.LM_CI_ID = CL1.LM_CI_ID AND D1.LM_DMTHD_TYPE_ID = DL1.LM_DMTHD_TYPE_ID AND CL1.LANGUAGE_CD = DL1.LANGUAGE_CD UNION SELECT DISTINCT C2.LM_CI_ID , CL2.LANGUAGE_CD , CL2.LM_CS_LONG_NM , CL2.LM_CS_DESCR , D2.LM_DM_LONG_NM FROM PS_LM_ACT A2 , PS_LM_CI_TBL C2 , PS_LM_CI_LANG CL2 , PS_LM_DMTH_TYP_TBL D2 WHERE A2.LM_CI_ID = C2.LM_CI_ID AND A2.LM_DMTHD_TYPE_ID = D2.LM_DMTHD_TYPE_ID AND A2.LM_ACT_STATUS = '3' AND %CurrentDateIn BETWEEN C2.EFFDT AND C2.LM_END_EFFDT AND C2.LM_CI_ID = CL2.LM_CI_ID AND NOT EXISTS ( SELECT 1 FROM PS_LM_DMTH_TYP_LNG DL2 WHERE D2.LM_DMTHD_TYPE_ID = DL2.LM_DMTHD_TYPE_ID AND CL2.LANGUAGE_CD = DL2.LANGUAGE_CD) UNION SELECT DISTINCT C3.LM_CI_ID , DL3.LANGUAGE_CD , C3.LM_CS_LONG_NM , C3.LM_CS_DESCR , DL3.LM_DM_LONG_NM FROM PS_LM_ACT A3 , PS_LM_CI_TBL C3 , PS_LM_DMTH_TYP_TBL D3 , PS_LM_DMTH_TYP_LNG DL3 WHERE A3.LM_CI_ID = C3.LM_CI_ID AND A3.LM_DMTHD_TYPE_ID = D3.LM_DMTHD_TYPE_ID AND A3.LM_ACT_STATUS = '3' AND %CurrentDateIn BETWEEN C3.EFFDT AND C3.LM_END_EFFDT AND NOT EXISTS ( SELECT 1 FROM PS_LM_CI_LANG CL3 WHERE C3.LM_CI_ID = CL3.LM_CI_ID AND DL3.LANGUAGE_CD = CL3.LANGUAGE_CD) AND D3.LM_DMTHD_TYPE_ID = DL3.LM_DMTHD_TYPE_ID
|