How do I restore a single table in SQL SERVER 2005?

Posted on 2008-11-12
Last Modified: 2012-05-05
If I have just one corrupt table in a database and I only want to restore one table is this possible either through a script or a function in SQL SERVER MGMT STUDIO?
Question by:deb1967
    LVL 60

    Accepted Solution

    No can do....Need to restore the db to another db w/ a different name and move the table over.
    LVL 142

    Expert Comment

    by:Guy Hengel [angelIII / a3]
    I agree.

    unless that table was the only one in it's dedicated filegroup ...
    but that's unlikely here, otherwise you would know how to restore that also.
    LVL 60

    Expert Comment

    >>unless that table was the only one in it's dedicated filegroup ...

    I almost wrote that, but then the reasoning from your last sentence kicked in for me.  :)
    LVL 9

    Expert Comment

    it depends. SQL Server 2005 introduced ability to restore a specific "page" from SQL Server 2005 backup, and it would be fun to write a script to restore a table by restoring piece meal pages out of backup.

    Chances are you do not need to restore the table, if all you need is to make sure that table corruption goes away. In addition there is always dbcc checktable, technet link:

    In addition if by chance you are using backup tools, such as SQL LiteSpeed from Quest it has built - in ability to restore specific table.
    LVL 7

    Expert Comment

    We use SQL LiteSpeed from Quest for that reason.  Also, because of good compression ability.

    One last option is to restore the entire database to a different server or as a different dbname on the same server and copy the table from the resored database to your production database.
    This option will work if you have disk space available.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Having an SQL database can be a big investment for a small company. Hardware, setup and of course, the price of software all add up to a big bill that some companies may not be able to absorb.  Luckily, there is a free version SQL Express, but does …
    Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
    Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
    Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.

    759 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

    9 Experts available now in Live!

    Get 1:1 Help Now