标签:
declare @num int begin try set @num=1/0 end try begin catch select ERROR_LINE() as 错误行数, ERROR_MESSAGE() as 错误消息 end catch
运行截图:
Sql Server异常捕获 try catch
原文地址:http://www.cnblogs.com/527289276qq/p/4872775.html