rem A list of all the Apex application numbers
SET APPLIST=200,201,202
rem The version-specific location of the exported SQL scripts
SET SCRIPTPATH=c:\incoming\scripts\%1\
rem Name for the temporary import SQL script
SET PACKAGESCRIPT=apex_import.sql
rem Or provide the password as a parameter to the batch file if there are
rem security issues about hard-coding it
SET SQLPLUS_LOGON=myoracleusername/myoraclepassword
SET MYSUFFIX=_stage
IF *%1==* goto :END
ECHO @%SCRIPTPATH%ALL_PACKAGES_%1.sql > %SCRIPTPATH%%PACKAGESCRIPT%
FOR %%f in (%APPLIST%) do call :APPIMPORT %%f
ECHO QUIT >> %SCRIPTPATH%%PACKAGESCRIPT%
sqlplus %SQLPLUS_LOGON% @%SCRIPTPATH%%PACKAGESCRIPT%
goto :END
:APPIMPORT
ECHO @%SCRIPTPATH%f%1_out%MYSUFFIX%.sql >> %SCRIPTPATH%%PACKAGESCRIPT%
goto :EOF
:END
Back to Apex deployment script