Restore a SQL Table

Posted on 2007-10-04
Last Modified: 2012-08-13
We have some software running on a client's server that uses a SQL database.

They are getting the following error:
Spooler error - 0x8c040005 (MSP_WEB_ADMIN Table not Initialized)
To resolve this - Restore the record in the MSP_WEB_ADMIN table.

My question is, how do you restore a single SQL table?
Question by:bax2000
    LVL 18

    Expert Comment

    You cant't ... at least not with the default restore command.
    You can restore the complete database to another database and then write a simple script to copy the table from the restored database to the original one, after you cleaned it. If it is not a huge table something like this will do:

    insert into Original.dbo.Table (col1, col2, col3, ...)
    select  col1, col2, col3, ...
    from Restored.dbo.Table R

    Hope this helps ...
    LVL 6

    Accepted Solution

    I am pretty sure you restore the whole DB to a new DB, call it "Restore_Sandbox_DB" or something different from your normal one.  Then you can import/export the table.

    There is a strategy called online piecemeal restore, that involves making your filegroups and backups super granular so that restores of parts of the DB are quick and easy:
    LVL 23

    Expert Comment

    by:Racim BOUDJAKDJI
    <<My question is, how do you restore a single SQL table?>>
    Unless the table is placed in a specific filegroup that you can restore separately, you can't...

    Hope this helps..

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Join & Write a Comment

    CCModeler offers a way to enter basic information like entities, attributes and relationships and export them as yEd or erviz diagram. It also can import existing Access or SQL Server tables with relationships.
    Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
    Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
    Via a live example, show how to shrink a transaction log file down to a reasonable size.

    730 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now