I find the following batch script very useful to backup files in Microsoft Windows everyday, and give each backup a unique date or time stamp.

Use date stamp as filename
xcopy D:Data"folder to backup" D:"My Backup"data_%date% /s /i

Use timestamp as filename
xcopy D:Data"folder to backup" D:"My Backup"data_%time% /s /i

Save the file as backup.bat, and schedule it using windows Task scheduler.

Here is the meaning of the syntax we have used

/s Copies directories and sub-directories except empty ones.
/i If destination does not exist and copying more than one file, assumes that destination must be a directory.

Beautiful piece of scripting

Now to make this interesting, I compressed the backup and saved it over the network. I downloaded 7zip from http://www.7-zip.org/download.html

To backup remotely, run such a command

7za a \servernamefoldername%date%.zip data_%date%

NB: The foldername must be a shared folder on \servername