Backup batch scripting

I am trying to create a batch file that will backup my documents folder when ran. I will have many files that didnt change however so I dont see the need to back these up and due to the size of some of them this will cause it to take a long time. I want to know if theres some way to check if the file has changed before it backs it up.

Heres what I have so far that backs everything up:

xcopy /i /y /e "Location on local pc*.*" "Server location"

This works great, but takes forever due to the amount of files. Any help would be greatly appreciated.
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Andrej PirmanCommented:
This one copies only files, whose change date is newer than destination:
xcopy /d /i /y /e "Location on local pc*.*" "Server location"

And this one works with Archive attribute, copying only those files, which have Archive bit set:
xcopy /m /i /y /e "Location on local pc*.*" "Server location"

try this:

  xcopy /i /y /e /d "Location on local pc*.*" "Server location"

per xcopy /?

  /D:m-d-y     Copies files changed on or after the specified date.
               If no date is given, copies only those files whose
               source time is newer than the destination time.
I think robocopy should be the best solution fast, robust and "intelligent" (copy only file changed...)

robocopy "c:\my dir" "\\server\my share" /w:1 /r:1 /s /z
/Z : Copy files in restartable mode
/R:n : number of Retries
/W:n : Wait time between retries second
/S : Copy Subfolders

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows Batch

From novice to tech pro — start learning today.