I want to run a daily incremental backup and append the day of the week to the file name so I end up with:
backup_mon.bak
backup_tue.bak
etc.
Not really bothered about what exactly is appended - 0 - 6 is fine.
How do I go about this?
|
feedback
|
|
Take a look at Advanced date and time math in batch files. You find there a subroutine which converts a date to the Julian calendar and another one which will tell you the weekday. | |||
|
feedback
|
|
If you have no problem calling an external script, you can use VBScript to get the day of week very easily: the VBScript code:
Calling it and using it in your filename:
then later in your script you can use the variable | ||||
|
feedback
|