|
Posted by Erland Sommarskog on 05/27/06 01:33
(billmiami2@netscape.net) writes:
> The scalar CLR UDF function was significantly faster than the classic
> scalar UDF, even for this very simple function. Perhaps a more complex
> function would have shown even a greater difference. Based on this, I
> must conclude that Erland was right. Of course, it's still faster to
> stick with basic built-in functions like CASE.
Yes, in this simple case.
During the beta of SQL 2005 I ran a test where I tested a CLR UDF, T-SQL UDf
and an expression with T-SQL builtins only. Of these the CLR UDF was the
fastest. The operation in this case was more complex, and included
convert(float, ), power(), substring and a CASE in T-SQL.
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Navigation:
[Reply to this message]
|