SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 backup a single table ?
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

ihadba
Starting Member

USA
5 Posts

Posted - 04/16/2008 :  16:18:09  Show Profile  Reply with Quote
Is there a tool out there to backup only one table at time
in SQL Server 2005 ?

sodeep
Flowing Fount of Yak Knowledge

USA
7174 Posts

Posted - 04/16/2008 :  16:21:40  Show Profile  Reply with Quote
No really. There are lots of post on this issue. Use export/import wizard to transfer data to other table with different name. Apply constraint after that.
Go to Top of Page

ihadba
Starting Member

USA
5 Posts

Posted - 04/16/2008 :  16:22:11  Show Profile  Reply with Quote
quote:
Originally posted by ihadba

Is there a tool out there to backup only one table at time
in SQL Server 2005 ?




Sorry, What I need is a method to backup one table. I want to be able to place the backup in a CD or other server to be used when
the disk fails
Go to Top of Page

sodeep
Flowing Fount of Yak Knowledge

USA
7174 Posts

Posted - 04/16/2008 :  16:26:06  Show Profile  Reply with Quote
I would do transactional replication if data has to real-time sync. Otherwise export the table to other server.
Go to Top of Page

ihadba
Starting Member

USA
5 Posts

Posted - 04/16/2008 :  16:55:01  Show Profile  Reply with Quote
So how do you do the export to another server.
What menu item should I start with ?
Go to Top of Page

sodeep
Flowing Fount of Yak Knowledge

USA
7174 Posts

Posted - 04/16/2008 :  16:57:17  Show Profile  Reply with Quote
Read BOL. Database-tasks-export/import wizard. Do you know which database that table is going to in another server.?
Go to Top of Page

ihadba
Starting Member

USA
5 Posts

Posted - 04/16/2008 :  17:52:17  Show Profile  Reply with Quote
Here is what I did
1. Use Export followed the steps and created a comma delimitted
file. Worked fine!<BR>
<B>2.</B>
<FONT COLOR="RED">Select * into backup_providers from providers </FONT><BR>
<B>3.</B>Delete from backup_providers<BR>
<B>4.</B>Use the import Wizard to import the data.
<B>5.</B>Hmm.. I get the following error:
<FONT COLOR="RED">
Error 0xc0202004: Data Flow Task: The number of columns is incorrect.
(SQL Server Import and Export Wizard)
</FONT>
<b>6.</b> I made a copy of the exact table, then deleted the data
and tried to import using the flat file. Why does it fail ?

Go to Top of Page

ihadba
Starting Member

USA
5 Posts

Posted - 04/16/2008 :  17:56:03  Show Profile  Reply with Quote
Please ignore my previous reply
Here is what I did:
1. Use Export followed the steps and created a comma delimitted
file. Worked fine!
2.Select * into backup_providers from providers
3.Delete from backup_providers<BR>
4.Use the import Wizard to import the data.
5.Hmm.. I get the following error:

Error 0xc0202004: Data Flow Task: The number of columns is incorrect.
(SQL Server Import and Export Wizard)


6.I made a copy of the exact table, then deleted the data
and tried to import using the flat file. Why does it fail ?

The backup table has the same structure as the original table used for creating the backup ( export ) file.
Go to Top of Page

tkizer
Almighty SQL Goddess

USA
37296 Posts

Posted - 04/16/2008 :  17:56:27  Show Profile  Visit tkizer's Homepage  Reply with Quote
quote:
Originally posted by ihadba

quote:
Originally posted by ihadba

Is there a tool out there to backup only one table at time
in SQL Server 2005 ?




Sorry, What I need is a method to backup one table. I want to be able to place the backup in a CD or other server to be used when
the disk fails



You should be backing up the entire database then.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/
Go to Top of Page

rmiao
Flowing Fount of Yak Knowledge

USA
7266 Posts

Posted - 04/16/2008 :  22:18:37  Show Profile  Reply with Quote
>> What I need is a method to backup one table.

Put table in its own file group then backup that file group.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.08 seconds. Powered By: Snitz Forums 2000