Summary

 

  • You can write stored procedures, user-defined functions, aggregates, triggers, and UDTs using managed code hosted by the SQLCLR.

  • The SQLCLR does not replace Transact-SQL. Set-based operations are best accomplished using T-SQL, whereas computation-intensive operations are best done using the SQLCLR.

  • You must enable the SQLCLR to use it on the SQL Server instance.

  • The SqlContext object provides access to the SQLCLR environment. This object has the Pipe property, which sends messages and data to the client.

  • The SqlContext object's Pipe property also contains the SendResultsStart, SendResultsRow, and SendResultsEnd methods that are used for sending rowset data back to the client.

  • You can write your SQLCLR source code with a text editor, compile it using the command-line compiler, and load and register the SQLCLR code using SQL scripts. Visual Studio .NET provides a developer-friendly interface that simplifies coding, deployment, and debugging.

  • You should use the context connection to access data within the current database because the context connection runs in-process and does not use any of the protocol stacks to communicate with the database server.

  • You should use a UDT only to define an atomic value that will be viewed in a column, not to represent business objects such as customers and employees.

 


Programming Microsoft ADO. NET 2.0 Applications. Advanced Topics
Linux Application Development (2nd Edition)
ISBN: 735621411
EAN: 2147483647
Year: 2004
Pages: 85

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net