Advantages of CLR procedure over T-SQL procedure- The use of the CLR procedure makes it possible to do the complex database operations without having an in-depth knowledge of T-SQL. - It also enables focusing the business layer towards the database in orderto increase the server performance by avoiding unnecessary server trips. - Also, with the help of the .NET Base Class Libraries, the complex logical operations can be effectively performed. - It deals with automatic garbage collection, memory management, exception handling, etc. due to which it is known as Managed Procedure. - The concepts of the OOP can also be applied. - It provides the ability to leverage the features of .NET Code Access Security (CAS) to prevent assemblies from performing certain operations.
CLR (common language runtime): is the core of the .NET Framework and it provides the environment for all managed code. The CLR provides all the services that are needed for the code to execute, JIT compilation, exception handling etc.
- .NET Framework allows solving complex logic operations for e.g. string manipulations, threading operations, encoding/decoding using cryptography. - CLR supports garbage collection, memory management, exception handling. This makes it more effective over T-SQL. - CLR allows the code to be more secure through code access security (CAS) to prevent assemblies from performing few processes.
|