Skip to main content

Create a Maintainance Plan on SQL


- There are two ways to create a maintenance plan: you can create a plan using the Maintenance Plan Wizard, or you can create a plan using the design surface. The Wizard is best for creating basic maintenance plans, while creating a plan using the design surface allows you to utilize enhanced workflow.
To create or manage Maintenance Plans, you must be a member of the sysadmin fixed server role. Note that Object Explorer only displays maintenance plans if the user is a member of the sysadmin fixed server role.
The Maintenance Plan Wizard helps you set up the core maintenance tasks to make sure that your database performs well, is regularly backed up, and is free of inconsistencies. The Maintenance Plan Wizard creates one or more SQL Server Agent jobs that perform these tasks on local servers or on target servers in a multiserver environment. Execution can be at scheduled intervals or on demand.
Maintenance plans can be created to perform the following tasks:
- Reorganize the data on the data and index pages by rebuilding indexes
- Compress data files by removing empty database pages.

To create a maintenance plan using the Maintenance Plan Wizard
1.In Object Explorer, expand a server, and then expand Management.
2.Right-click Maintenance Plans and select Maintenance Plan Wizard.
3.Follow the steps of the wizard to create a maintenance plan.

Comments

Popular posts from this blog

Insufficient access rights to perform the operation. (Exception from HRESULT: 0x80072098)

While accessing the active directory (AD) and authorization manager (AZMAN) , If you get “   Insufficient access rights to perform the operation. (Exception from HRESULT: 0x80072098)  “ message check the    account that is being used to get the LDAP query from AD .  ERROR DETAILS Exception Details:  System.Runtime.InteropServices.COMException: Insufficient access rights to perform the operation. (Exception from HRESULT: 0x80072098) Source Error: Line 154:    'Session("FullName") = System.Security.Principal.WindowsIdentity.GetCurrent.Name.ToString() Line 155: Line 156:    If Not User.IsInRole("Role1") Then Line 157:          Response.Redirect("./Login.aspx") Line 158:    End If  Stack Trace : .... SOLVE IT Steps to do check the app pool rights: Click on the website name that you are having problem with in IIS  In the right panel you will se...

SQL Server 2008 - Inline Variable Assignment

Microsoft SQL Server 2008 brings in a new feature of 'Declaring and Assigning' a variable all in a single line. Earlier, while using SQL 2005 and earlier versions, we had to declare a variable before assigning it. This feature is explained in detail below. In SQL 2005 and earlier versions we had to write: Declare @age int Declare @name nvarchar(25) Declare @date date Set @age = 25 Set @name = "Garry" Set @date = GETDATE() With SQL 2008 we can combine both these statements to write Declare @age int = 25 Declare @name nvarchar(25) Declare @date @date = GETDATE() Advantage : This helps us to write less code, yet get the same functionality. Even though this feature has been available it is not being used in many projects because of backward compatibility issue. If the same code is being used on both 2005 and 2008 server we would prefer writing in a format compatible to both. Do share with us :  Would you like to use this new method? If not, why?

OOPs...

OOPs or Object Oriented Programming is an approach that puts object at the center of programming model. An object is a self contained entity that has a state and behaviour. State is described by fields and properties, while behavior is defined by methods and events. Object is an instance of a class.  A class acts like a blueprint for the object . It defines behavior of object of that type.So all objects of type Vehicle will have the same behavior. Vehicle class will have the properties - 'color' , 'weight', 'model', 'make' . Properties are characteristic shared by all objects of a particular class.  Methods are actions of an object - 'start', 'stop' Constructors are special kinds of methods, used to initialize objects. It executes automatically when a class is instantiated Access modifies helps in controlling the visibilty of a class. * Public allows the property or methods to be called outside the class * Private fields and ...