Link to home
Start Free TrialLog in
Avatar of Ernesto
ErnestoFlag for Mexico

asked on

robocopy

Oh dear experts

I want robocopy this


robocopy.exe E:\Program Files\Microsoft SQL Server\MSSQL12.LIPSA\MSSQL\Backup\  f:\Bases\  /e /r:0 /w:0

do not work
please you guys!
Avatar of Joe Winograd
Joe Winograd
Flag of United States of America image

Assuming that the paths are correct on E; and F:, the problem is probably that there are spaces in the E; folder name, so you need quotes around it. In other words:
robocopy.exe "E:\Program Files\Microsoft SQL Server\MSSQL12.LIPSA\MSSQL\Backup\"  f:\Bases\  /e /r:0 /w:0

Open in new window

Regards, Joe
SOLUTION
Avatar of Ernesto
Ernesto
Flag of Mexico image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Ernesto

ASKER

Oh you guys
tsm!!
regards
The syntax of robocopy is:
ROBOCOPY source destination [file [file]...] [options]

So if it says no destination, that likely means there's no F: drive, because even if \Bases\ doesn't exist, it would create the folder on the F: drive — if there is one!

Please post a screenshot of the command prompt where you are issuing the robocopy.
> Robocopy doesn't like a backslash at the end of a quoted path

Bill,
Robocopy is perfectly fine with a backslash at the end:

User generated image
The quotes were the problem, not the backslashes! Regards, Joe

Update: Oops! Turns out that backslashes are ok at the end of non-quoted paths but are not ok at the end of quoted paths. Talk about weird! My apologies, Bill, you are correct. That said, my comment about the quotes was at least half of the problem — and half of the solution. :)

So note that this also works:
robocopy.exe "E:\Program Files\Microsoft SQL Server\MSSQL12.LIPSA\MSSQL\Backup"  f:\Bases\  /e /r:0 /w:0

Open in new window

That is, a backslash at the end of f:\Bases\ — but no quotes! Cheers, Joe