Re: SQL Differential Backups
- From: Don Hofer <DonHofer@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 20 May 2005 18:53:01 -0700
Dear Andrew, Thanks for all your help, I'm almost there.
I type in this command and get a 156 error near keyword WITH
My command;
DECLARE @DBNAME VARCHAR(40), @DEVICE VARCHAR(200), @NAME VARCHAR(200)
SET @DBNAME = 'GOLDMINE_SALES_AND_MARKETING'
SET @DEVICE = N'F:\SQL2000\GOLDMINE_SALES_AND_MARKETING\' + @DBNAME +'_FULL'
+ CONVERT(NVARCHAR(16),GETDATE(),112) + N'.BAK'
SET @NAME = @DBNAME + N' FULL BACKUP'
BACKUP DATABASE @DBNAME TO DISK = @DEVICE WITH INIT , NOUNLOAD , NAME=
@NAME, NOSKIP , STATS = 10, NOFORMAT WITH DIFFERENTIAL
"Andrew J. Kelly" wrote:
> You can do something like this example. Tailor it to your needs:
>
> DECLARE @DBName VARCHAR(40), @Device VARCHAR(200), @Name VARCHAR(200)
> SET @DBNAME = 'YourDBName'
>
> SET @Device = N'C:\Data\Backups\' + @DBName + '_Full_' +
> CONVERT(NVARCHAR(16),GETDATE(),112) + N'.BAK'
>
> SET @Name = @DBName + N' Full Backup'
>
> BACKUP DATABASE @DBName TO DISK = @Device WITH INIT , NOUNLOAD ,
> NAME = @Name, NOSKIP , STATS = 10, NOFORMAT
> WITH DIFFERENTIAL
>
>
> --
> Andrew J. Kelly SQL MVP
>
>
> "Don Hofer" <DonHofer@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
> news:43F8D75D-78A1-4962-A9BE-B0ED7A0BABD4@xxxxxxxxxxxxxxxx
> > Andrew, it did run. I refreshed the screen and a differential ran at 0800
> > in
> > the morning. I also see the job in the Jobs under SQL Server Agents.
> > I write all jobs our to a Raid, and they have that raid xfered to another
> > server and to tape. Both the Daily and Trans backups, run with the name
> > of
> > the database followed by the date and time ran and an extension of ".trn"
> > or
> > ".Bak"
> > Is there a way to get the Differentials to run the same way?
> >
> > "Andrew J. Kelly" wrote:
> >
> >> What exactly do you mean when you say you can't get them to run? Do you
> >> get
> >> errors?
> >>
> >> --
> >> Andrew J. Kelly SQL MVP
> >>
> >>
> >> "Don Hofer" <DonHofer@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
> >> news:AF59E550-A74B-4ED4-8661-67F7B110D00D@xxxxxxxxxxxxxxxx
> >> > In our Maintance plans, we have our full daily backup running fine, and
> >> > our
> >> > Transactions running fine, i.e every 30 minutes.
> >> > We can perfrom manual Differential backups fine. We just can not get
> >> > the
> >> > Differential backups to run out of the schuduler.
> >> > We're trying to achive, Differentials every 4 hours, with Transactions
> >> > every
> >> > 30 minutes inbetween.
> >> > Any help will be most appreciated.
> >>
> >>
> >>
>
>
>
.
- Follow-Ups:
- Re: SQL Differential Backups
- From: Andrew J. Kelly
- Re: SQL Differential Backups
- References:
- SQL Differential Backups
- From: Don Hofer
- Re: SQL Differential Backups
- From: Andrew J. Kelly
- Re: SQL Differential Backups
- From: Don Hofer
- Re: SQL Differential Backups
- From: Andrew J. Kelly
- SQL Differential Backups
- Prev by Date: Re: SQL Differential Backups
- Next by Date: SQL WMI installation after SP3a
- Previous by thread: Re: SQL Differential Backups
- Next by thread: Re: SQL Differential Backups
- Index(es):
Relevant Pages
|