BACKUP LOG cannot be performed because there is no current database backup
I tried to restore a database but this message showed. How do I restore this database?
Restore of database 'farhangi_db' failed.
(Microsoft.SqlServer.Management.RelationalEngineTasks)
------------------------------ ADDITIONAL INFORMATION:System.Data.SqlClient.SqlError: BACKUP LOG cannot be performed because
there is no current database backup. (Microsoft.SqlServer.SmoExtended)
Solution 1:
Originally, I created a database and then restored the backup file to my new empty database:
Right click on Databases > Restore Database > General : Device: [the path of back up file] → OK
This was wrong. I shouldn't have first created the database.
Now, instead, I do this:
Right click on Databases > Restore Database > General : Device: [the path of back up file] → OK
Solution 2:
Another cause of this issue is when the Take tail-log backup before restore
"Options" setting is enabled.
On the "Options" tab, Disable/uncheck Take tail-log backup before restore
before restoring to a database that doesn't yet exist.