Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to restore a database from a backup file on a SQL Server 2008 instance using the following SQL command:

    FROM DISK=@db_location 
    WITH STATS=5, 
    MOVE @db_OldName TO @db_NewFile, 
    MOVE @db_OldLogName TO @db_NewLogFile, 

and it fails with the following error:

Msg 3264, Level 16, State 1, Line 19 The operation did not proceed far enough to allow RESTART. Reissue the statement without the RESTART qualifier. Msg 3013, Level 16, State 1, Line 19 RESTORE DATABASE is terminating abnormally.

If I do not use the RESTART option the backup is successful. On SQL Server 2005 it works even with the RESTART parameter.

Since the SQL command is issued by a program I cannot change it. Is there a way to work around this issues on SQL Server 2008?

share|improve this question

migrated from Jan 21 '12 at 15:02

This question came from our site for professional and enthusiast programmers.

up vote 0 down vote accepted

Has this ever worked?

RESTART is only specified when you want to continue an interrupted restore. If you can't change the SQL, then you can only somehow break a first restore to generate an error condition.

Because of this, you can't be sure that it's the same on SQL 2005 unless it happens every time. Or they changed behaviour.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.