Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 12»»

Database Backup Expand / Collapse
Author
Message
Posted Monday, January 17, 2011 4:41 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, September 21, 2011 11:19 AM
Points: 8, Visits: 26
Hi,
I have a huge database whose backup file goes around 20 GB, because we store all documents in image format into the table.
Since we need to backup this DB everyday, this requires a lot of space in server.
All i want to do is:
1. Back whole database without that single table every day.
2. Back up that single table separately as separate bak file.. may be every week.. if possible in separate server.

Is there any way we can do this in MN SQL?
Thanks in advance.
Post #1048990
Posted Monday, January 17, 2011 9:50 PM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Monday, July 28, 2014 11:14 AM
Points: 1,618, Visits: 20,979
Sachin,

SQL Server does not have an option to backup a table as a .bak file. You can make use of SSIS to export the tables.


Pradeep Adiga
Blog: sqldbadiaries.com
Twitter: @pradeepadiga
Post #1049044
Posted Monday, January 17, 2011 10:02 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, September 21, 2011 11:19 AM
Points: 8, Visits: 26
Hi Pradeep~,
Thanks for the reply.
My document table is about 10+ GB with Image column in it. I don't know exporting this table in a file works for me.

Also, Do you know if we can backup database with our that 1 table? If we can please do let me know..

Thanks
~Sachin
Post #1049048
Posted Monday, January 17, 2011 10:05 PM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Monday, July 28, 2014 11:14 AM
Points: 1,618, Visits: 20,979
Native backups to disk does not support excluding objects. SSIS is a good option for you to export the table to another database.

You can create a database to store the single exported table and then take the backup of that table to disk.


Pradeep Adiga
Blog: sqldbadiaries.com
Twitter: @pradeepadiga
Post #1049050
Posted Monday, January 17, 2011 10:34 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, September 21, 2011 11:19 AM
Points: 8, Visits: 26
Thank You Pradeep!!
I appreciate your comments...

Sachin
Post #1049056
Posted Monday, January 17, 2011 11:19 PM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: 2 days ago @ 12:05 AM
Points: 270, Visits: 715
It seems like a big database. You can also consider 3rd party tools like LiteSpeed which can help you backup/restore one table.
Ofcourse it is a license tool.

If licensing is problem , SSIS is the best option.
Post #1049072
Posted Tuesday, January 18, 2011 12:56 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Thursday, August 29, 2013 1:44 PM
Points: 144, Visits: 426
You could split that one large table into a separate filegroup, then use filegroup backups to backup the two filegroups separately, which should do what you're looking for.
Post #1049094
Posted Tuesday, January 18, 2011 1:20 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 2:21 PM
Points: 6,172, Visits: 7,241
^ This.

Sachin, what Keith said above is your best practice, and should usually be done anyway when dealing with LOB data (VARCHAR(MAX), text, Image, etc.) LOBs behave annoyingly when it comes to their storage, and it's best to try to keep them out of the rest of the data, at least anything that won't store in-row.

Look into filegroup backups, and also into differential backups. The two combined should help your storage issues immensely.



- Craig Farrell

Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.

For better assistance in answering your questions | Forum Netiquette
For index/tuning help, follow these directions. |Tally Tables

Twitter: @AnyWayDBA
Post #1049108
Posted Tuesday, January 18, 2011 7:38 AM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Today @ 1:01 PM
Points: 15,558, Visits: 27,932
Unless I'm reading this wrong, 20gb is very small as databases go. I agree that seperating out the storage to different filegroups would allow you to break up the backup process. You might also consider looking at SQL Server 2008 and the FileStream as a means of moving the LOB out of your database and into a file system. But if you're hitting serious space issues at 20gb, I'd strongly recommend getting some more disk space. I picked up a 2tb external drive for $90. I wouldn't recommend that for a data drive for a system, but it might be a good place for storing backups, especially on what sounds likea commodity system.

----------------------------------------------------
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood..." Theodore Roosevelt
The Scary DBA
Author of: SQL Server 2012 Query Performance Tuning
SQL Server 2008 Query Performance Tuning Distilled
and
SQL Server Execution Plans

Product Evangelist for Red Gate Software
Post #1049352
Posted Tuesday, January 18, 2011 7:45 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Friday, May 30, 2014 6:27 PM
Points: 2,808, Visits: 7,175
I have to agree 20gb is not large at all - I would concentrate on getting enough space for a standard backup before worrying about any other options outlined
Post #1049357
« Prev Topic | Next Topic »

Add to briefcase 12»»

Permissions Expand / Collapse