Need help with a bat script to copy a folder from the C drive to another location on the C drive with the date.
Source - C:\Backup DB
Target - C:\Archive
I want to take the entire folder "C:\Backup DB" and put that into the C:\Archive with timestampe to the "Backup DB" folder.
The "Backup DB" gets updated with a new DB backup in there nightly. I want to take the entire folder and just give it a date in the folder name.
C:\Archive\Backup DB 12-09-2011
Here's what I tried:
XCOPY "C:\Backup DB" "C:\Archive\Backup DB %DATE% %TIME%" /S /I
I'm not getting the date format I need and it's not copying the files inside of the folder "Backup DB".