Category: Problems Solved

Level 16 Errors Can’t always be handled by User Code

Although books-OnLine says that user code can handle errors with Level 16 and below, they sometimes end the connection.
Continue reading

Retrieving a Random Record in SQL Server using udf_Num_RanInt

This UDFs week solves a problem posed to me last week by a friend Gary.  Gary wants to select a random row from one of his tables and was hoping that SQL Server would have some support for this task. The idea of selecting a random row… Continue reading

The Problem with User-Defined Functions (UDF) and a Solution

Download the sample script: Problem-Scalar-UDF-and-solution-andy-novick   and a PDF of the slides: The Problem with scalar UDFs and a solution – Andy Novick Or watch the video on Youtube:   User-Defined functions (UDF) have been around SQL Server since the 2000 version. They are a great way to… Continue reading