Recently we discovered a problem with the GUI when trying to restore a database to a point in time. The time happens to fall in between the start and end time of a differential backup. To make it clear, say the differential started at 5PM and take 10 minutes to complete. Our requested restore point is 5:01 PM. The GUI generated script suggest we do Full restore, Differential that started at 5PM then the first Log after the Diff backup. However, most of the time we encounter this error
Msg 4335, Level 16, State 1, Line 2
The specified STOPAT time is too early. All or part of the database is already rolled forward beyond that point.
Msg 3013, Level 16, State 1, Line 2
RESTORE LOG is terminating abnormally.
if we restore the log file without the STOPAT, then the restore can recovery the database.
We can work around it by forcing the restore to start from the previous differential backup and then all the Logs in between until the last one that contains the restore point.
This problem happens for both SQL 2005 and 2008R2 servers we tested, however, interestingly, we find the GUI generated script differ slightly in that a "STOPAT" is used in both the Differential and Log restore commands for SQL 2008 version.
I am wondering if this is a long term standing bug with SQL Server.