WHENEVER SQLERROR EXIT FAILURE ROLLBACK;
WHENEVER OSERROR  EXIT FAILURE ROLLBACK;

spool EXP_ORG_POSITION_VL.log

prompt
prompt Creating view EXP_ORG_POSITION_VL
prompt ============================
prompt
---create view 
CREATE OR REPLACE FORCE VIEW  EXP_ORG_POSITION_VL as
SELECT A.POSITION_ID,
			 A.UNIT_ID,
			 A.POSITION_CODE,
			 B.DESCRIPTION_TEXT AS DESCRIPTION,
			 A.COMPANY_ID,
			 A.PARENT_POSITION_ID,
                         A.EMPLOYEE_JOB_ID,
			 A.ENABLED_FLAG,
			 A.CREATION_DATE,
			 A.CREATED_BY,
			 A.LAST_UPDATE_DATE,
			 A.LAST_UPDATED_BY
	FROM EXP_ORG_POSITION A, FND_DESCRIPTIONS B
 WHERE A.DESCRIPTION_ID = B.DESCRIPTION_ID(+)
	 AND B.LANGUAGE(+) = USERENV('lang')
	 AND B.REF_TABLE(+) = 'EXP_ORG_POSITION'
	 AND B.REF_FIELD(+) = 'DESCRIPTION_ID'
/


                                   
spool off

exit
