How to trace T-SQL function calls

后端 未结 9 1313
被撕碎了的回忆
被撕碎了的回忆 2020-12-15 04:43

I\'m trying to debug a rather complicated formula evaluator written in T-SQL UDFs (don\'t ask) that recursively (but indirectly through an intermediate func

9条回答
  •  时光说笑
    2020-12-15 05:44

    Why not use SQL Profiler with statement level events added?

    Edit: Add events for Stored Procedures : SP:Stmt Starting or SP:Stmt Completed Use variables to debug if needed, i.e. set @debug='i am here'; UDF's, while not technically stored procedures, will get traced with the statement level events.

提交回复
热议问题