Course description
In this course you will explore two kinds of code modules that can be implemented with only .NET code. Those are Aggregates and User Defined Types. These module types are not support by T-SQL You will also see how to improve performance with ordered tabled valued functions that return data that is already sorted by defining them correctly in the database.
Prerequisites
This course assumes that you have a basic familiarity with the concept of relational databases and a basic understanding of what SQL Server is and the high-level tools in it, as well as how to create and manage objects using Management Studio. You should also have a basic understanding of how SQL Server implements security, including its authentication and authorization schemes, and how to assign permissions on securable objects to principals. You should know the fundamentals of Transact-SQL to write queries to retrieve and update data, and how to execute scripts using the query editor in Management Studio.
The course spends a lot of time deep in T-SQL code, so you should feel comfortable writing basic queries that involve joins of multiple tables, as well as using built-in T-SQL functions and other code modules.
It will be very helpful, but not absolutely necessary, to have experience with .NET development using Visual Studio 2010 or 2012 for the portions of the course that deal with SQL Server Data Tools.
Learning Paths
This course will help you prepare for the following certifications and exams:
MCSE: Business Intelligence
MCSA: SQL Server 2012/2014
MCSE: Data Platform
70-464: Developing Microsoft SQL Server 2012/2014 Databases
70-461: Querying Microsoft SQL Server 2012/2014
This course is part of the following LearnNowOnline SuccessPaths™:
SQL Server Developer
Meet the expert
Don Kiely is a featured instructor on many of our SQL Server and Visual Studio courses. He is a nationally recognized author, instructor, and consultant specializing in Microsoft technologies. Don has many years of teaching experience, is the author or co-author of several programming books, and has spoken at many industry conferences and user groups. In addition, Don is a consultant for a variety of companies that develop distributed applications for public and private organizations.
Course outline
Aggregate, UDT, TVF and Modules
Aggregates (26:59)
- Introduction (01:09)
- Aggregates (02:09)
- Demo: Custom Code Attributes (03:26)
- Demo: Implementing the Code (04:42)
- Demo: Running the Aggregation (01:33)
- Large Aggregates (02:30)
- Demo: Large Aggregates (03:28)
- Demo: Running Large Aggregate (02:58)
- Mulitparameter Aggregates (01:36)
- Demo: Multiparameter Aggregate (03:04)
- Summary (00:19)
User Defined Types (16:48)
- Introduction (01:12)
- Demo: User-Defined Type (03:32)
- Demo: Handling Nulls (01:01)
- Demo: Setting UDT Values (02:17)
- Demo: Implementing Properties (03:38)
- Demo: Implementing Methods (02:11)
- Demo: Test User-Defined Type (02:20)
- Summary (00:32)
Table and Functions (10:22)
- Introduction (00:31)
- Demo: Table-Valued Function (02:16)
- Demo: Deploy and Test the Code (01:23)
- Demo: Ordered List Function (01:18)
- Demo: Execution Plans (01:40)
- Demo: Lying to SQL Server (02:47)
- Summary (00:24)
Managing Code Modules (08:02)
- Introduction (00:23)
- Demo: Assmeblies (03:13)
- Demo: Viewing Source Code (00:42)
- Demo: Assembly Modules (00:43)
- Demo: Procedures and Triggers (00:17)
- Demo: Types (00:32)
- Viewing Loaded Assemblies (00:37)
- Demo: View Loaded Assemblies (01:08)
- Summary (00:23)