SELECT B.BUSINESS_UNIT , C.PROJECT_ID , B.PC_BUDGET_ID , B.LANGUAGE_CD , C.DESCR , B.DESCR FROM PS_PC_BUD_PLAN A , PS_PC_BUD_PLAN_LNG B , PS_PROJECT_LANG C WHERE A.BUSINESS_UNIT = B.BUSINESS_UNIT AND A.PROJECT_ID = B.PROJECT_ID AND A.PC_BUDGET_ID = B.PC_BUDGET_ID AND C.BUSINESS_UNIT = A.BUSINESS_UNIT AND C.PROJECT_ID = A.PROJECT_ID AND C.LANGUAGE_CD = B.LANGUAGE_CD UNION SELECT F.BUSINESS_UNIT , E.PROJECT_ID , F.PC_BUDGET_ID , F.LANGUAGE_CD , E.DESCR , F.DESCR FROM PS_PC_BUD_PLAN D , PS_PROJECT E , PS_PC_BUD_PLAN_LNG F WHERE F.BUSINESS_UNIT = D.BUSINESS_UNIT AND F.PROJECT_ID = D.PROJECT_ID AND F.PC_BUDGET_ID = D.PC_BUDGET_ID AND E.BUSINESS_UNIT = D.BUSINESS_UNIT AND E.PROJECT_ID = D.PROJECT_ID AND NOT EXISTS ( SELECT 'X' FROM PS_PROJECT_LANG H WHERE H.BUSINESS_UNIT = E.BUSINESS_UNIT AND H.PROJECT_ID = E.PROJECT_ID AND H.LANGUAGE_CD = F.LANGUAGE_CD) UNION SELECT I.BUSINESS_UNIT , J.PROJECT_ID , I.PC_BUDGET_ID , J.LANGUAGE_CD , J.DESCR , I.DESCR FROM PS_PC_BUD_PLAN I , PS_PROJECT_LANG J WHERE I.BUSINESS_UNIT = J.BUSINESS_UNIT AND I.PROJECT_ID = J.PROJECT_ID AND NOT EXISTS ( SELECT 'X' FROM PS_PC_BUD_PLAN_LNG K WHERE K.BUSINESS_UNIT = I.BUSINESS_UNIT AND K.PROJECT_ID = I.PROJECT_ID AND K.PC_BUDGET_ID = I.PC_BUDGET_ID)
|