Original: Oralce Export script command, timed execution
@echo off @echo ================================================
Automated backup scripts for Oracle databases @echo Windows environment
@echo 1, the current date is automatically named when you back up the exported file.
@echo 2, URLs are temporary directories, URLs, is the final save directory, after saving will delete the temporary directory
@echo 3, this is the Oracle 11g Export command, the following is the export of 5 users EXPDP ppp/[email protected] dumpfile=zcjc_ppp_%mydate%_exp.dmp content= All
@echo 4, name the file Xxxxx.bat, my name here is Expdportoracle.bat
@echo 5, script execution time, execute at 02:0/every:m,t,w,th,f,s,su "E:\expbportOracle.bat" in DOS command
@echo 6, delete the task, execute at 1/delete in DOS command
@echo 7. Don't know where to find me ask qq:1216331654
@echo ================================================
Set mydate=%date:~0,4%%date:~5,2%%date:~8,2%
Set years=%date:~0,4%
Set month=%date:~5,2%
Set day=%date:~8,2%
Set Urls=e:\app\administrator\admin\zcjc\dpdump set Url=e:\expbportoracle
MD%url%\%years% MD%url%\%years%\%month% MD%url%\%years%\%month%\%day%
EXPDP ppp/[email protected] dumpfile=zcjc_ppp_%mydate%_exp.dmp Content=all
EXPDP aus/[email protected] dumpfile=zcjc_aus_%mydate%_exp.dmp Content=all
EXPDP cif/[email protected] dumpfile=zcjc_cif_%mydate%_exp.dmp Content=all
EXPDP spm/[email protected] dumpfile=zcjc_spm_%mydate%_exp.dmp Content=all
EXPDP ua/[email protected] dumpfile=zcjc_ua_%mydate%_exp.dmp Content=all
Copy "%urls%\zcjc_ppp_%mydate%_exp.dmp" "%url%\%years%\%month%\%day%"
Copy "%urls%\zcjc_aus_%mydate%_exp.dmp" "%url%\%years%\%month%\%day%"
Copy "%urls%\zcjc_cif_%mydate%_exp.dmp" "%url%\%years%\%month%\%day%"
Copy "%urls%\zcjc_spm_%mydate%_exp.dmp" "%url%\%years%\%month%\%day%"
Copy "%urls%\zcjc_ua_%mydate%_exp.dmp" "%url%\%years%\%month%\%day%"
Del%urls%\zcjc_ppp_%mydate%_exp.dmp
Del%urls%\zcjc_aus_%mydate%_exp.dmp
Del%urls%\zcjc_cif_%mydate%_exp.dmp
Del%urls%\zcjc_spm_%mydate%_exp.dmp
Del%urls%\zcjc_ua_%mydate%_exp.dmp
Exit
Oralce Export script command, timed execution