Solved

backup a table and restore

Posted on 2006-11-01
6
1,098 Views
Last Modified: 2008-03-28
Dear experts,

Can a single table be restored in Sql Server.

What is the best way to take a backup of a single table?

can the above be done without using Enterprise Manager, say using Querry Analyzer.

many thanks
0
Comment
Question by:crishna1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 17851928
>Can a single table be restored in Sql Server.
by default: no.

however, if that table is the only table in a filegroup, you can restore the filegroup which hence restores only that table.
0
 
LVL 11

Assisted Solution

by:rw3admin
rw3admin earned 200 total points
ID: 17852008
I think you mean how to save table outside the DB for migration or archive purpose.

you can export table along with data to a txt,csv,xl files ..... (using DTS) , you can use bcp, you can maybe also use openrowset ( I am not too sure about it)

but yes as angel pointed out you cannot do a "backup" as in DB backup of a single table
0
 
LVL 35

Assisted Solution

by:David Todd
David Todd earned 50 total points
ID: 17852464
Hi Folks,

Isn't SQL 2005 supposed to be able to backup and restore a single table? Or is that only the filegroup as Angel mentioned.

Regards
  David
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 
LVL 143

Assisted Solution

by:Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3] earned 250 total points
ID: 17852542
>Isn't SQL 2005 supposed to be able to backup and restore a single table? Or is that only the filegroup as Angel mentioned.
that's exactly the method: backup restore granularity is limited to filegroups...
0
 

Author Comment

by:crishna1
ID: 17853096
Thanks for your feed back.

How do i restore a single table from the file group, command please.
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 17853761
you cannot restore a single table.
you CAN restore a single filegroup.

so IF and ONLY if your table is the ONLY one in a filegroup you can restore that filegroup and hence restore that table...
http://www.microsoft.com/technet/prodtechnol/sql/2000/maintain/sqlbackuprest.mspx#E3GAG
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction SQL Server Integration Services can read XML files, that’s known by every BI developer.  (If you didn’t, don’t worry, I’m aiming this article at newcomers as well.) But how far can you go?  When does the XML Source component become …
Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.

734 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