How do you set the auto-delete option on SQL2005 sql agent backup jobs?

Posted on 2007-10-01
Last Modified: 2013-11-30
Im having difficulty knowing where to specify the deletion period for the dump files created in a SQL2005 database backup schedule in SQL Agent. It seems now to create an SSIS sub-package for the task when using the wizard options, and doesnt seem to have the "remove after x days/weeks" option that the old SQL 2000 wizard used to have:
 -UseDefDir  -DelBkUps 1WEEKS -BkExt "BAK"'

On looking at the SQL2005 backup db subtask, it seems to call a cmd exec command;

/SQL "Maintenance Plans\MaintenancePlan - backup databases" /SERVER "$(ESCAPE_NONE(SRVR))" /MAXCONCURRENT " -1 " /CHECKPOINTING OFF /SET "\Package\Subplan_1.Disable";false

Any ideas how you do this?
Question by:Yeatsie
    LVL 16

    Expert Comment

    is the . included in the .bak, check in your maintenace plan
    LVL 16

    Expert Comment

    and SP2

    Accepted Solution

    I found the answer here, provided by Nightman.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Maximize Your Threat Intelligence Reporting

    Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

    In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
    In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
    Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
    This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

    794 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

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now