O'Reilly logo

Professional Microsoft SQL Server 2012 Administration by Ross LoForte, Steven Wort, Adam Jorgensen, Brian Knight

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 7

SQL Server CLR Integration

WHAT’S IN THIS CHAPTER

  • How the CLR is Implemented in SQL Server
  • SQLCLR Assembly Creation and Deployment
  • Securing SQLCLR Assemblies
  • Performance

SQL Server developers first saw the integration of the .NET Common Language Runtime (CLR) with the release of SQL Server 2005. Not a whole lot has changed with the release of SQL Server 2008 and 2012. Yet, SQLCLR provides great benefits to developers as well as database administrators, and is worth reviewing.

This chapter does not focus entirely on how to write SQLCLR .NET assemblies, (visit http://technet.microsoft.com/en-us/library/ms131102(SQL.110).aspx for a more in-depth discussion of that) but does provide a few examples on how to create and deploy an assembly. These serve as a nice foundation on which to focus the majority of the chapter, which covers SQLCLR Administration. This chapter focuses on the CLR as a hosted environment in SQL Server and discusses why you would use T-SQL over a SQLCLR solution. This chapter also discusses SQLCLR performance and security because these are critical concepts to consider when deciding to use SQLCLR.

INTRODUCTION TO THE CLR

With the integration of the .NET Framework CLR components in SQL Server, developers have the flexibility to write stored procedures, triggers, user-defined types and functions, and streaming table-valued functions using a variety of .NET Framework languages, the most common being C# and Visual Basic .NET. It’s no secret that this addition ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required