Wednesday, March 21, 2012

Dumping Sql after an exception

Does anyone have a code snippet for dumping the actual sql a command would be running?

What do you mean by "dumping" ? You can kill the session..

|||

No I mean like getting the actual SQL it was trying to execute.

|||

If you know the spid you can do DBCC INPUTBUFFER(spid) to see what the spid is executing.

No comments:

Post a Comment