1. Trang chủ
  2. » Công Nghệ Thông Tin

Brad’s Sure Guide to SQL Server Maintenance Plans- P38 docx

5 227 0

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 5
Dung lượng 746,34 KB

Nội dung

Chapter 16: Introduction to the Maintenance Plan Designer 186 • Access to New Tasks – the Designer includes two new tasks • Execute T-SQL Statement task – allows you to run any custom T-SQL code as part of your Maintenance Plan. • Notify Operator task – makes it easy for you to create a Maintenance Plan that will notify you if any problem occurs when a Maintenance Plan executes. We will see examples of all of these features over the coming chapters. However, let's learn to walk before we run, and take a look at how to start up the Designer, then get a high-level feel for its GUI and the features that it provides. Starting the Maintenance Plan Designer Starting the Maintenance Plan Designer is as simple as starting the Maintenance Plan Wizard if not simpler, since it's the option I always find myself drawn towards, even when I intend to start the Wizard. From within SSMS Object Explorer, simply open up the Management folder, right-click on Maintenance Plans and then select New Maintenance Plan…, as shown in Figure 16.1. Chapter 16: Introduction to the Maintenance Plan Designer 187 Figure 16.1: The New Maintenance Plan… option opens the Maintenance Plan Designer. Having started the designer, the first job is to assign a name to your new Maintenance Plan, using the dialog box shown in Figure 16.2. Figure 16.2: You must assign your new Maintenance Plan a name. Pick a descriptive name that will help you and others to remember and understand the purpose of this plan. Once you've clicked OK, the Maintenance Plan Designer starts up within SSMS and you are ready to go. Chapter 16: Introduction to the Maintenance Plan Designer 188 Exploring the Maintenance Plan Designer Having initiated the Designer, you are confronted with the Design surface, features and menu options shown in Figure 16.3. Figure 16.3: The Maintenance Plan screen is the GUI-based interface you use to create custom Database Maintenance Plans. Before we drill into the specifics of using this tool, let's take a broad look at each major section of this screen. Chapter 16: Introduction to the Maintenance Plan Designer 189 Object Explorer At the top left-hand side of the screen is the SSMS Object Explorer which, of course, is familiar to all users of SSMS. Other than being the point from which you can start the Designer, it plays no direct part in the creation of a new Maintenance Plan. The only other reason you might use the SSMS Object Explorer is to open an existing Maintenance Plan while creating a new one. To refer back to an existing plan, you can simply double-click on that plan's icon in Object Explorer and it will open up in Designer. The Maintenance Plan that you are working on will not close, but will be hidden beneath the one that just opened, and is accessible from a tab at the top of the window. In this way, you can have several Maintenance Plans open at the same time. To return to the original plan, simply select the appropriate tab. While you will probably not be doing this often, it does allow you to check what you have done in a previous Maintenance Plan without having to close the Maintenance Plan that you are currently working on. Maintenance Task Toolbox At the bottom left-hand side of the screen, below the SSMS Object Explorer, is the Toolbox, shown in Figure 16.4, which is where all the available Maintenance Plan Tasks are displayed. As we will discuss later, you'll use the toolbox heavily when creating plans within the Designer, by dragging and dropping these tasks onto the design surface. Most of the tasks in this Toolbox will be familiar to you, with the two previously-noted exceptions (the Execute T-SQL Statement and Notify Operator tasks, which we'll discuss in Chapter 17). The Toolbox is divided into two sections, Maintenance Plan Tasks and General. All the tasks you need to use are available from the Maintenance Plan Tasks section. If the General section opens, I suggest you close it to prevent any potential confusion. Chapter 16: Introduction to the Maintenance Plan Designer 190 Figure 16.4: Focusing on the Maintenance Plan Tasks section of the Toolbox. What's with the Pointer? The very first item listed under Maintenance Plan Tasks is called the Pointer. This is not a Maintenance Plan task, nor is it a useful feature when creating Maintenance Plans in the Designer. In theory, clicking the Pointer will put the "focus" back on the cursor within the design surface. If you place the cursor anywhere within the design surface and click, you will notice that the "focus" remains on the cursor, so the Pointer option is not needed. Why is it there? It's the same old story: the Designer was developed to be multipurpose within SSMS (for example, it is also used to create SSIS packages), and the Pointer is an artifact of this design. In other words, ignore it. Subplans and the Design Surface The right-hand side of the Designer, shown in Figure 16.5, is dominated by the design surface (I've highlighted it with a border in the figure). It is on this surface that you design each of your Maintenance Plans, using the tasks provided in the Toolbox. . Introduction to the Maintenance Plan Designer 186 • Access to New Tasks – the Designer includes two new tasks • Execute T -SQL Statement task – allows you to run any custom T -SQL code as part of your Maintenance. 16.3. Figure 16.3: The Maintenance Plan screen is the GUI-based interface you use to create custom Database Maintenance Plans. Before we drill into the specifics of using this tool, let's take. you have done in a previous Maintenance Plan without having to close the Maintenance Plan that you are currently working on. Maintenance Task Toolbox At the bottom left-hand side of the screen,

Ngày đăng: 04/07/2014, 23:20

TỪ KHÓA LIÊN QUAN