Why is TRY-CATCH block not allowed inside UDFs?

前端 未结 3 1588
执笔经年
执笔经年 2021-02-11 21:59

Why doesn\'t SQL Server support TRY-CATCH blocks inside UDFs?

If we\'re talking about scalar UDFs, which are mostly used for calculations and conversations, this block s

3条回答
  •  野的像风
    2021-02-11 22:47

    As a work around, I would call the UDF from TRY/CATCH inside a stored procedure.

提交回复
热议问题