Online Documentation for SQL Manager for SQL server

UDFs


A Function is a mapping embodied as a program (the function body) that can be invoked by using zero or more input values (arguments) to a single value (the result). A User-Defined Function is stored as a database object providing reusable code.

 

The Transact-SQL programming language provides the following types of functions:

Rowset functions (can be used like table references in an SQL statement)

Aggregate functions (operate on a collection of values but return a single, summarizing value)

Ranking functions (return a ranking value for each row in a partition)

Scalar functions (operate on a single value and then return a single value; scalar functions can be used wherever an expression is valid)

 

UDF Editor allows you to define user-defined function properties. It opens automatically when you create a new user-defined function and is available on editing an existing one.

 

To open a user-defined function in UDF Editor, double-click it in the DB Explorer tree.