Xem mẫu

Instructor Inputs Session Overview This session includes Chapter 9 and Chapter 10 of the Student Guide. Slide 1 Querying and Managing Data Using SQL Server 2005 Objectives In this session, you will learn to: Understand managed code Create managed database objects Define the Hypertext Transfer Protocol endpoints Implement the Hypertext Transfer Protocol endpoints for Web services Ver. 1.0 Session 14 Slide 1 of 31 Start the session by sharing the objectives with the students. In this session, the students will learn the importance of managed objects and how to create them. In addition, they will also learn how to implement Web services in SQL Server 2005 using HTTP endpoints. ¤NIIT Instructor Inputs 14.3 Slide 2 Querying and Managing Data Using SQL Server 2005 Introduction to SQL Server CLR Integration CLR integration: Allows the database developer to write the code in any of the .NET supported languages Allows to run managed code within a database Provides the following functions and services required for program execution Ver. 1.0 Session 14 Slide 2 of 31 In this topic, you need to explain the students about CLR. As they have already read about CLR in the chapter 1, you need not to go into the details of CLR. Explain how CLR has been incorporated in the SQL Server itself. Also explain the benefits of integrating CLR inside SQL Server itself. You can use the examples provided in the Student Guide to clarify the concept to the students. T-SQL has been the conventional language to write database objects, such as stored procedure, triggers and functions. SQL Server 2005 provides the new possibilities to the database developer by integrating .NET Framework in it. SQL Server 2005 allows the database developers to write stored procedures, triggers, user-defined types, user-defined aggregates, and user-defined functions in any of the .NET supported language, build a .dll, register and use it inside a SQL Server. It is very important that the students understand that you are not removing the business or data layer by hosting the C# code in the SQL Server. SQL Server is still a database and is not intended to be used as an application server in your architecture. 14.4 Instructor Inputs ¤NIIT Slide 3 Querying and Managing Data Using SQL Server 2005 Identifying the Need for Managed Code Managed database objects can be created in the following situations: To implement complicated programming logics To access external resources To implement a CPU-intensive functionality that can run more efficiently as compared to the managed code. T-SQL statements can be used in the following situations: To perform data access and manipulation operations that can be done using the T-SQL statements. To implement programming logic tat can be easily implemented using T-SQL programming constructs. Ver. 1.0 Session 14 Slide 3 of 31 In this topic, you need to explain the need for managed code to the students. You need to explain the limitations of T-SQL to the students, and how those limitations can be overcome by introducing managed code in SQL Server. T-SQL is a language that is used to manipulate and query data from a database server. It provides a number of database features, such as query plans and caching of query plans and their results. Because of all these features, T-SQL is the best choice for the operations in the SQL Server. But the procedural aspect of T-SQL makes it complicate to use in situations that involve functions such as, complex mathematical computations, recursive operations, and heavily procedural. In addition, T-SQL can not take the advantage of code reuse. If you try to implement all this using T-SQL, the network traffic of your company goes into a loop and results in slow query processing. With the ability to write and host .NET code inside SQL Server 2005, you now can prevent the network roundtrips and host the necessary .NET code right inside SQL Server. ¤NIIT Instructor Inputs 14.5 ... - tailieumienphi.vn
nguon tai.lieu . vn