locked
Cannot Restore SQL Server 2008 Server Backup RRS feed

  • Question

  • PLEASE HELP!!!

    Please I did an Sql database backup for my application server, has some issues with my application data and tried restoring the database but kept getting the error........

    PLEASE MY COMPANY IS HELD TO RANSOM AS WE NEED THE MOST RECENT BACKUP TO WORK!!!

    Thursday, March 27, 2014 2:12 PM

Answers

  • Thank you Shanky_621 for replying.

    The error is:

    "SQL Server :: Object Cannot Be Cast From DBNull To Other Types"

    Dont use GUI to restore database.This issue can come sometimes when your login is not administrator in SQL Server, instead use below query

    RESTORE FILELISTONLY
       FROM disk= 'AdventureWorks2008R2_Backup'--this would be your backup location
    -- Restore the files for MyAdvWorks.
    RESTORE DATABASE MyAdvWorks--your database name 
       FROM AdventureWorks2008R2_Backup
       WITH RECOVERY,
       MOVE 'AdventureWorks2008R2_Data' TO 'D:\MyData\MyAdvWorks_Data.mdf', 
       MOVE 'AdventureWorks2008R2_Log' TO 'F:\MyLog\MyAdvWorks_Log.ldf'
    GO
    --specifiy drive where you want to restore database and kjust replace mdf and ndf with name you like in above script


    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers


    • Proposed as answer by tracycai Friday, March 28, 2014 4:51 AM
    • Edited by Shanky_621MVP Friday, March 28, 2014 9:18 AM
    • Marked as answer by tracycai Monday, April 7, 2014 1:53 AM
    Thursday, March 27, 2014 3:31 PM

All replies

  • PLEASE HELP!!!

    Please I did an Sql database backup for my application server, has some issues with my application data and tried restoring the database but kept getting the error........

    PLEASE MY COMPANY IS HELD TO RANSOM AS WE NEED THE MOST RECENT BACKUP TO WORK!!!

    Hi I cannot understand this error message can you post error message which flashed during restore.

    Are you trying ot restore user database or system database.

    See example mentioned in below link for restoring new database

    http://technet.microsoft.com/en-us/library/ms190447(v=sql.105).aspx


    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers


    Thursday, March 27, 2014 2:35 PM
  • Thank you Shanky_621 for replying.

    The error is:

    "SQL Server :: Object Cannot Be Cast From DBNull To Other Types"

    Thursday, March 27, 2014 2:59 PM
  • Thank you Shanky_621 for replying.

    The error is:

    "SQL Server :: Object Cannot Be Cast From DBNull To Other Types"

    Dont use GUI to restore database.This issue can come sometimes when your login is not administrator in SQL Server, instead use below query

    RESTORE FILELISTONLY
       FROM disk= 'AdventureWorks2008R2_Backup'--this would be your backup location
    -- Restore the files for MyAdvWorks.
    RESTORE DATABASE MyAdvWorks--your database name 
       FROM AdventureWorks2008R2_Backup
       WITH RECOVERY,
       MOVE 'AdventureWorks2008R2_Data' TO 'D:\MyData\MyAdvWorks_Data.mdf', 
       MOVE 'AdventureWorks2008R2_Log' TO 'F:\MyLog\MyAdvWorks_Log.ldf'
    GO
    --specifiy drive where you want to restore database and kjust replace mdf and ndf with name you like in above script


    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers


    • Proposed as answer by tracycai Friday, March 28, 2014 4:51 AM
    • Edited by Shanky_621MVP Friday, March 28, 2014 9:18 AM
    • Marked as answer by tracycai Monday, April 7, 2014 1:53 AM
    Thursday, March 27, 2014 3:31 PM