Section 4.8. Custom Attributes for CLR Routines


4.8. Custom Attributes for CLR Routines

The .NET CLR is extended using attributesdescriptive keywords saved in the assembly metadata that provide additional information for programming constructs. The custom attributes used with SQL Server 2005 CLR routines are defined in the Microsoft.SqlServer.Server namespace. Table 4-15 describes custom attributes used with SQL Server CLR routines.

Table 4-15. Custom attributes for CLR routines

Attribute

CLR routine

Description

SqlFacet

UDT

Specifies details about the return type of a UDT.

SqlFunction

UDF

Indicates that the method should be registered as a UDF.

SqlMethod

UDT

Specifies the determinism and data access properties of methods in a UDT.

SqlProcedure

Stored procedure

Indicates that the method should be registered as a stored procedure.

SqlTrigger

Trigger

Indicates that the method should be registered as a trigger.

SqlUserDefinedAggregate

UDA

Indicates that the method should be registered as a UDA.

SqlUserDefinedType

UDT

Indicates that the class or structure should be registered as a UDT.


These attributes are discussed in detail in Chapter 5 in the specific sections about the .NET Framework routines that use them.



Programming SQL Server 2005
Programming SQL Server 2005
ISBN: 0596004796
EAN: 2147483647
Year: 2007
Pages: 147
Authors: Bill Hamilton

Similar book on Amazon

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