What Statement is being executed

  • How can i know what statement is associated with what spid in Query Analyzer. I mean that if you look in the current activity in Enterprise Manager, and double click on any Process Id it gives the statement being executed. How can i find the same With Query Analyzer? I thought context_info column in sysprocesses table stores the information but it didnot work for me. Any help would be appreciated.

  • I was looking for this myself this week.

    The following does it:

    DBCC INPUTBUFFER (spid)

  • Thanks Joachim. It works great. Can you let me know if you come to know a different way also?

    Thanks once again for your help.

  • Try Profiler.

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply