Saturday, February 25, 2012
Can SQL 2005 Backup to a different file name each night?
a new backup file each night. This basic feature does not appear to be an
option in SQL 2005. Is there some workaround? Anyone know if this will be
part of SP01?
I have hundreds of systems that have 4 5GB databases where we do full
backups every night. I do NOT want to append the previous nights backup to
the existing file, and I do NOT want to overwrite last nights backup because
I don't want to be without a backup if tonight's backup fails.
All suggestions are welcome, but I need a very simple way to set this up on
hundreds of systems by non-computer literate people.
Rob Kraft
Never mind group. I cannot recreate the problem I had. Originally in
testing, all of the backups were appending to the same date/time stamped
filename. I set up a new plan and it seems to work as desired - creating a
new file each time the backup runs. I have to manually add a cleanup task
to the DB Maint Plan created by the wizard to delete old DB files, but I've
got that figured out too.
Rob Kraft
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
> In SQL 2000, I could use the DB Maint Wizard to create a backup that
> created a new backup file each night. This basic feature does not appear
> to be an option in SQL 2005. Is there some workaround? Anyone know if
> this will be part of SP01?
> I have hundreds of systems that have 4 5GB databases where we do full
> backups every night. I do NOT want to append the previous nights backup
> to the existing file, and I do NOT want to overwrite last nights backup
> because I don't want to be without a backup if tonight's backup fails.
> All suggestions are welcome, but I need a very simple way to set this up
> on hundreds of systems by non-computer literate people.
> Rob Kraft
>
|||Rob,
How do you add the delete of the oldest file? I cannot seem to manage this
so far.
Thanks
Chris Wood
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
> Never mind group. I cannot recreate the problem I had. Originally in
> testing, all of the backups were appending to the same date/time stamped
> filename. I set up a new plan and it seems to work as desired - creating
> a new file each time the backup runs. I have to manually add a cleanup
> task to the DB Maint Plan created by the wizard to delete old DB files,
> but I've got that figured out too.
> Rob Kraft
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
>
|||Chris, I could not do this using the Maintenance Plan Wizard. Instead, after
creating the plan, right-click on the plan and select Modify. Then, on the
left hand side (probably) -drag a "Maintenance Cleanup Task" from the
Toolbox window into your plan (make sure you do NOT grab the "History
Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
Edit. They you can specify to delete files in a specific folder that are
older than a n Weeks (or n Days). (and you can specify to delete files with
just a specific extension such as bak). Close that window then click on the
"Maintenance Cleanup Task" in the maintence plan and click and drag the
green arrow that appears down to the "Back Up Database Task" you just
created to cause the "Back Up Database Task" to execute after the file
delete.
Technically, I don't see a way using these tools to delete "the oldest
file"; but you can delete "all files over n days old".
Rob Kraft
"Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
> Rob,
> How do you add the delete of the oldest file? I cannot seem to manage this
> so far.
> Thanks
> Chris Wood
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
>
|||Thank you Rob.
Works like a treat. Another 2005 nuance out of the way.
Chris
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:e7ziF2XWGHA.1564@.TK2MSFTNGP03.phx.gbl...
> Chris, I could not do this using the Maintenance Plan Wizard. Instead,
> after creating the plan, right-click on the plan and select Modify. Then,
> on the left hand side (probably) -drag a "Maintenance Cleanup Task" from
> the Toolbox window into your plan (make sure you do NOT grab the "History
> Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
> Edit. They you can specify to delete files in a specific folder that are
> older than a n Weeks (or n Days). (and you can specify to delete files
> with just a specific extension such as bak). Close that window then click
> on the "Maintenance Cleanup Task" in the maintence plan and click and drag
> the green arrow that appears down to the "Back Up Database Task" you just
> created to cause the "Back Up Database Task" to execute after the file
> delete.
> Technically, I don't see a way using these tools to delete "the oldest
> file"; but you can delete "all files over n days old".
> Rob Kraft
>
> "Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
> news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
>
Can SQL 2005 Backup to a different file name each night?
a new backup file each night. This basic feature does not appear to be an
option in SQL 2005. Is there some workaround? Anyone know if this will be
part of SP01?
I have hundreds of systems that have 4 5GB databases where we do full
backups every night. I do NOT want to append the previous nights backup to
the existing file, and I do NOT want to overwrite last nights backup because
I don't want to be without a backup if tonight's backup fails.
All suggestions are welcome, but I need a very simple way to set this up on
hundreds of systems by non-computer literate people.
Rob KraftNever mind group. I cannot recreate the problem I had. Originally in
testing, all of the backups were appending to the same date/time stamped
filename. I set up a new plan and it seems to work as desired - creating a
new file each time the backup runs. I have to manually add a cleanup task
to the DB Maint Plan created by the wizard to delete old DB files, but I've
got that figured out too.
Rob Kraft
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
> In SQL 2000, I could use the DB Maint Wizard to create a backup that
> created a new backup file each night. This basic feature does not appear
> to be an option in SQL 2005. Is there some workaround? Anyone know if
> this will be part of SP01?
> I have hundreds of systems that have 4 5GB databases where we do full
> backups every night. I do NOT want to append the previous nights backup
> to the existing file, and I do NOT want to overwrite last nights backup
> because I don't want to be without a backup if tonight's backup fails.
> All suggestions are welcome, but I need a very simple way to set this up
> on hundreds of systems by non-computer literate people.
> Rob Kraft
>|||Rob,
How do you add the delete of the oldest file? I cannot seem to manage this
so far.
Thanks
Chris Wood
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
> Never mind group. I cannot recreate the problem I had. Originally in
> testing, all of the backups were appending to the same date/time stamped
> filename. I set up a new plan and it seems to work as desired - creating
> a new file each time the backup runs. I have to manually add a cleanup
> task to the DB Maint Plan created by the wizard to delete old DB files,
> but I've got that figured out too.
> Rob Kraft
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
>> In SQL 2000, I could use the DB Maint Wizard to create a backup that
>> created a new backup file each night. This basic feature does not appear
>> to be an option in SQL 2005. Is there some workaround? Anyone know if
>> this will be part of SP01?
>> I have hundreds of systems that have 4 5GB databases where we do full
>> backups every night. I do NOT want to append the previous nights backup
>> to the existing file, and I do NOT want to overwrite last nights backup
>> because I don't want to be without a backup if tonight's backup fails.
>> All suggestions are welcome, but I need a very simple way to set this up
>> on hundreds of systems by non-computer literate people.
>> Rob Kraft
>|||Look at maintenance cleanup task in Management plan.
Regards
Amish Shah|||Chris, I could not do this using the Maintenance Plan Wizard. Instead, after
creating the plan, right-click on the plan and select Modify. Then, on the
left hand side (probably) -drag a "Maintenance Cleanup Task" from the
Toolbox window into your plan (make sure you do NOT grab the "History
Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
Edit. They you can specify to delete files in a specific folder that are
older than a n Weeks (or n Days). (and you can specify to delete files with
just a specific extension such as bak). Close that window then click on the
"Maintenance Cleanup Task" in the maintence plan and click and drag the
green arrow that appears down to the "Back Up Database Task" you just
created to cause the "Back Up Database Task" to execute after the file
delete.
Technically, I don't see a way using these tools to delete "the oldest
file"; but you can delete "all files over n days old".
Rob Kraft
"Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
> Rob,
> How do you add the delete of the oldest file? I cannot seem to manage this
> so far.
> Thanks
> Chris Wood
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
>> Never mind group. I cannot recreate the problem I had. Originally in
>> testing, all of the backups were appending to the same date/time stamped
>> filename. I set up a new plan and it seems to work as desired - creating
>> a new file each time the backup runs. I have to manually add a cleanup
>> task to the DB Maint Plan created by the wizard to delete old DB files,
>> but I've got that figured out too.
>> Rob Kraft
>> "Rob Kraft" <robkraft@.msn.com> wrote in message
>> news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
>> In SQL 2000, I could use the DB Maint Wizard to create a backup that
>> created a new backup file each night. This basic feature does not
>> appear to be an option in SQL 2005. Is there some workaround? Anyone
>> know if this will be part of SP01?
>> I have hundreds of systems that have 4 5GB databases where we do full
>> backups every night. I do NOT want to append the previous nights backup
>> to the existing file, and I do NOT want to overwrite last nights backup
>> because I don't want to be without a backup if tonight's backup fails.
>> All suggestions are welcome, but I need a very simple way to set this up
>> on hundreds of systems by non-computer literate people.
>> Rob Kraft
>>
>|||Thank you Rob.
Works like a treat. Another 2005 nuance out of the way.
Chris
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:e7ziF2XWGHA.1564@.TK2MSFTNGP03.phx.gbl...
> Chris, I could not do this using the Maintenance Plan Wizard. Instead,
> after creating the plan, right-click on the plan and select Modify. Then,
> on the left hand side (probably) -drag a "Maintenance Cleanup Task" from
> the Toolbox window into your plan (make sure you do NOT grab the "History
> Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
> Edit. They you can specify to delete files in a specific folder that are
> older than a n Weeks (or n Days). (and you can specify to delete files
> with just a specific extension such as bak). Close that window then click
> on the "Maintenance Cleanup Task" in the maintence plan and click and drag
> the green arrow that appears down to the "Back Up Database Task" you just
> created to cause the "Back Up Database Task" to execute after the file
> delete.
> Technically, I don't see a way using these tools to delete "the oldest
> file"; but you can delete "all files over n days old".
> Rob Kraft
>
> "Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
> news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
>> Rob,
>> How do you add the delete of the oldest file? I cannot seem to manage
>> this so far.
>> Thanks
>> Chris Wood
>> "Rob Kraft" <robkraft@.msn.com> wrote in message
>> news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
>> Never mind group. I cannot recreate the problem I had. Originally in
>> testing, all of the backups were appending to the same date/time stamped
>> filename. I set up a new plan and it seems to work as desired -
>> creating a new file each time the backup runs. I have to manually add a
>> cleanup task to the DB Maint Plan created by the wizard to delete old DB
>> files, but I've got that figured out too.
>> Rob Kraft
>> "Rob Kraft" <robkraft@.msn.com> wrote in message
>> news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
>> In SQL 2000, I could use the DB Maint Wizard to create a backup that
>> created a new backup file each night. This basic feature does not
>> appear to be an option in SQL 2005. Is there some workaround? Anyone
>> know if this will be part of SP01?
>> I have hundreds of systems that have 4 5GB databases where we do full
>> backups every night. I do NOT want to append the previous nights
>> backup to the existing file, and I do NOT want to overwrite last nights
>> backup because I don't want to be without a backup if tonight's backup
>> fails.
>> All suggestions are welcome, but I need a very simple way to set this
>> up on hundreds of systems by non-computer literate people.
>> Rob Kraft
>>
>>
>|||See also the discussion in thread
http://forums.microsoft.com/MSDN/ShowPost.aspx?postid=111810&siteid=1
"Chris Wood" wrote:
> Thank you Rob.
> Works like a treat. Another 2005 nuance out of the way.
> Chris
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:e7ziF2XWGHA.1564@.TK2MSFTNGP03.phx.gbl...
> > Chris, I could not do this using the Maintenance Plan Wizard. Instead,
> > after creating the plan, right-click on the plan and select Modify. Then,
> > on the left hand side (probably) -drag a "Maintenance Cleanup Task" from
> > the Toolbox window into your plan (make sure you do NOT grab the "History
> > Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
> > Edit. They you can specify to delete files in a specific folder that are
> > older than a n Weeks (or n Days). (and you can specify to delete files
> > with just a specific extension such as bak). Close that window then click
> > on the "Maintenance Cleanup Task" in the maintence plan and click and drag
> > the green arrow that appears down to the "Back Up Database Task" you just
> > created to cause the "Back Up Database Task" to execute after the file
> > delete.
> >
> > Technically, I don't see a way using these tools to delete "the oldest
> > file"; but you can delete "all files over n days old".
> >
> > Rob Kraft
> >
> >
> > "Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
> > news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
> >> Rob,
> >>
> >> How do you add the delete of the oldest file? I cannot seem to manage
> >> this so far.
> >>
> >> Thanks
> >>
> >> Chris Wood
> >>
> >> "Rob Kraft" <robkraft@.msn.com> wrote in message
> >> news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
> >> Never mind group. I cannot recreate the problem I had. Originally in
> >> testing, all of the backups were appending to the same date/time stamped
> >> filename. I set up a new plan and it seems to work as desired -
> >> creating a new file each time the backup runs. I have to manually add a
> >> cleanup task to the DB Maint Plan created by the wizard to delete old DB
> >> files, but I've got that figured out too.
> >>
> >> Rob Kraft
> >>
> >> "Rob Kraft" <robkraft@.msn.com> wrote in message
> >> news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
> >> In SQL 2000, I could use the DB Maint Wizard to create a backup that
> >> created a new backup file each night. This basic feature does not
> >> appear to be an option in SQL 2005. Is there some workaround? Anyone
> >> know if this will be part of SP01?
> >> I have hundreds of systems that have 4 5GB databases where we do full
> >> backups every night. I do NOT want to append the previous nights
> >> backup to the existing file, and I do NOT want to overwrite last nights
> >> backup because I don't want to be without a backup if tonight's backup
> >> fails.
> >>
> >> All suggestions are welcome, but I need a very simple way to set this
> >> up on hundreds of systems by non-computer literate people.
> >>
> >> Rob Kraft
> >>
> >>
> >>
> >>
> >>
> >
> >
>
>
Can SQL 2005 Backup to a different file name each night?
a new backup file each night. This basic feature does not appear to be an
option in SQL 2005. Is there some workaround? Anyone know if this will be
part of SP01?
I have hundreds of systems that have 4 5GB databases where we do full
backups every night. I do NOT want to append the previous nights backup to
the existing file, and I do NOT want to overwrite last nights backup because
I don't want to be without a backup if tonight's backup fails.
All suggestions are welcome, but I need a very simple way to set this up on
hundreds of systems by non-computer literate people.
Rob KraftNever mind group. I cannot recreate the problem I had. Originally in
testing, all of the backups were appending to the same date/time stamped
filename. I set up a new plan and it seems to work as desired - creating a
new file each time the backup runs. I have to manually add a cleanup task
to the DB Maint Plan created by the wizard to delete old DB files, but I've
got that figured out too.
Rob Kraft
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
> In SQL 2000, I could use the DB Maint Wizard to create a backup that
> created a new backup file each night. This basic feature does not appear
> to be an option in SQL 2005. Is there some workaround? Anyone know if
> this will be part of SP01?
> I have hundreds of systems that have 4 5GB databases where we do full
> backups every night. I do NOT want to append the previous nights backup
> to the existing file, and I do NOT want to overwrite last nights backup
> because I don't want to be without a backup if tonight's backup fails.
> All suggestions are welcome, but I need a very simple way to set this up
> on hundreds of systems by non-computer literate people.
> Rob Kraft
>|||Rob,
How do you add the delete of the oldest file? I cannot seem to manage this
so far.
Thanks
Chris Wood
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
> Never mind group. I cannot recreate the problem I had. Originally in
> testing, all of the backups were appending to the same date/time stamped
> filename. I set up a new plan and it seems to work as desired - creating
> a new file each time the backup runs. I have to manually add a cleanup
> task to the DB Maint Plan created by the wizard to delete old DB files,
> but I've got that figured out too.
> Rob Kraft
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:%23nhHf4%23VGHA.3284@.TK2MSFTNGP09.phx.gbl...
>|||Chris, I could not do this using the Maintenance Plan Wizard. Instead, after
creating the plan, right-click on the plan and select Modify. Then, on the
left hand side (probably) -drag a "Maintenance Cleanup Task" from the
Toolbox window into your plan (make sure you do NOT grab the "History
Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
Edit. They you can specify to delete files in a specific folder that are
older than a n Weeks (or n Days). (and you can specify to delete files with
just a specific extension such as bak). Close that window then click on the
"Maintenance Cleanup Task" in the maintence plan and click and drag the
green arrow that appears down to the "Back Up Database Task" you just
created to cause the "Back Up Database Task" to execute after the file
delete.
Technically, I don't see a way using these tools to delete "the oldest
file"; but you can delete "all files over n days old".
Rob Kraft
"Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
> Rob,
> How do you add the delete of the oldest file? I cannot seem to manage this
> so far.
> Thanks
> Chris Wood
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:e4R3FI$VGHA.4328@.TK2MSFTNGP12.phx.gbl...
>|||Thank you Rob.
Works like a treat. Another 2005 nuance out of the way.
Chris
"Rob Kraft" <robkraft@.msn.com> wrote in message
news:e7ziF2XWGHA.1564@.TK2MSFTNGP03.phx.gbl...
> Chris, I could not do this using the Maintenance Plan Wizard. Instead,
> after creating the plan, right-click on the plan and select Modify. Then,
> on the left hand side (probably) -drag a "Maintenance Cleanup Task" from
> the Toolbox window into your plan (make sure you do NOT grab the "History
> Cleanup Task"). Right-click on the "Maintenance Cleanup Task" and select
> Edit. They you can specify to delete files in a specific folder that are
> older than a n Weeks (or n Days). (and you can specify to delete files
> with just a specific extension such as bak). Close that window then click
> on the "Maintenance Cleanup Task" in the maintence plan and click and drag
> the green arrow that appears down to the "Back Up Database Task" you just
> created to cause the "Back Up Database Task" to execute after the file
> delete.
> Technically, I don't see a way using these tools to delete "the oldest
> file"; but you can delete "all files over n days old".
> Rob Kraft
>
> "Chris Wood" <anonymous@.discussions.microsoft.com> wrote in message
> news:exAKTW$VGHA.5076@.TK2MSFTNGP14.phx.gbl...
>|||See also the discussion in thread
http://forums.microsoft.com/MSDN/Sh...111810&siteid=1
"Chris Wood" wrote:
> Thank you Rob.
> Works like a treat. Another 2005 nuance out of the way.
> Chris
> "Rob Kraft" <robkraft@.msn.com> wrote in message
> news:e7ziF2XWGHA.1564@.TK2MSFTNGP03.phx.gbl...
>
>
Sunday, February 12, 2012
Can not see any server in the available servers list
I successfully installed SQL Server 2005 Express edition in my pc. I ran Visual Basic 6 and used and Ado object to build a connection string to access the server but, I could not see any server in the comobox list.
I always get connection failure messages say that the server does not exitst!!!
Any help please.
Thanks
The installation process does not leave the server open to 'outside' connections. You will have to manually 'open' the server. Here are some useful resources:
Configuration -Configure SQL Server 2005 to allow remote connections
http://support.microsoft.com/default.aspx?scid=kb;EN-US;914277
http://blogs.msdn.com/sqlexpress/archive/2005/05/05/415084.aspx
Configuration -Connect to SQL Express from "downlevel clients"
http://blogs.msdn.com/sqlexpress/archive/2004/07/23/192044.aspx
Configuration -Connect to SQL Express and ‘Stay Connected’
http://betav.com/blog/billva/2006/06/getting_and_staying_connected.html
can not retrive @@identity value
but I could not retrive it from my Visual basic code, like variable=
oRS.fields.item(0).value, it always says item can not be found...Hi
At a guess it is probably because it is not the first recordset being
returned.
Instead it may be best to use an output parameter to do this.
Also if you are using SQL 2000 then use the SCOPE_IDENTITY() function.
John
"Allan" <hlang121@.yahoo.com> wrote in message
news:436e7a2d.0308271236.3bd2edd2@.posting.google.c om...
> I use select @.@.identity to return @.@.identity from my store procedure,
> but I could not retrive it from my Visual basic code, like variable=
> oRS.fields.item(0).value, it always says item can not be found...|||Allan (hlang121@.yahoo.com) writes:
> I use select @.@.identity to return @.@.identity from my store procedure,
> but I could not retrive it from my Visual basic code, like variable=
> oRS.fields.item(0).value, it always says item can not be found...
So how does the VB code look like? And how does the stored procedure
look like?
Your chances to precise assistance increases if you care to share
the code you are having problem.
--
Erland Sommarskog, SQL Server MVP, sommar@.algonet.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp|||Hi,
One of the easiest way to get the identity value from sqlserver7.0, is
rs.open"select @.@.identity as id from tab1",..,..
box1 = rs!id
With Thanks
Raghu